Hi,
I am using @media Print in css to hide html element in print page of Confluence.It is working properly while printing page of confluence by using "Cntrl+P" .
Getting problem when I am trying to export the page content by using "Scroll Pdf Plugin" of confluence then it does not hide html element from it.
Please find the css which I am using
@media print{ .MenuBar #export { display: none !important; } }
And below is the velocity template which is referring to the above css
<div class="MenuBar"> <form id="export" action = $req.getContextPath()/plugins/servlet/myServletXYZ class="aui" method = "post"> <input type="hidden" id="dataVal" name="data"/> <!-- Trigger --> <a href="#export-id" aria-owns="export" aria-haspopup="true" class="aui-button aui-style-default aui-dropdown2-trigger talli" title="Export"> <span class="aui-icon aui-icon-small aui-iconfont-export"></span> Export </a> <!-- Dropdown --> <div id="export-id" class="aui-style-default aui-dropdown2" table-id=$table-id> <ul class="aui-list-truncate"> <li aria-disabled="true" data-value="xls"> <a href="#" title="Export to xls"> <img class="exportxls" src="$req.contextPath/download/resources/mycompany-myPlugin:spreadJSResources/images/32x32-excel-xls-windows-8-metro-style.png" style="height:30px ; width:30px ; vertical-align:middle;"/> XLS </a> </li> <li aria-disabled="true" data-value="xyz"> <a href="#" title="xyz"> <img class="xyz" src="$req.contextPath/download/resources/mycompany-myPlugin:spreadJSResources/images/excel.png" style="height:30px; width:30px ; vertical-align:middle;"/> XLSX </a> </li> <li aria-disabled="true" title="Coming Soon ..."> <a href="#" style="pointer-events: none; cursor: default;"> <img class ="pdf" src="$req.contextPath/download/resources/mycompany-myPlugin:spreadJSResources/images/pdf-icon.png" style="height:30px; width:30px ;vertical-align:middle;"/> PDF </a> </li> <li aria-disabled="true" title="Coming Soon ..."> <a href="#" style="pointer-events: none; cursor: default;"> <span class="aui-icon aui-icon-large aui-iconfont-confluence" style = "height:30px ; width:30px ;vertical-align:middle;"></span> Confluence </a> </li> </ul> </div> </form> </div>
I also referred this this confluence page which says adding an user macro and using noprint css works, but I could not get it worked.
Any pointer on this will be very helpful.
Thanks,
Kriti
Community moderators have prevented the ability to post new answers.
HI,
Scroll PDF has its own add-on for hiding content from a PDF. It's called "Scroll Ignore" and you should have it installed if you have Scroll PDF installed. You can try copying the storage format code for that macro and adding it into your velocity template with whatever you want to not appear in the pdf inside the macro.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.