Cannot copy code from PDF after page export

David Fitzjarrell November 13, 2022

I have documented steps to complete a task, in a page, and I would like to export this page to a PDF.  I've done this in the past at it worked great.

Something has changed and I don't know what I'm doing wrong.

Exporting the page to PDF works fine, however now readers cannot copy the code from code blocks in a useful way.

The copy includes the page numbers rendering it useless. Of course a user could go line by line and remove the numbers (hard thing to script in VI or other editors.)

Does anyone have an idea for a workaround?

1 answer

0 votes
Brant Schroeder
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 13, 2022

@David Fitzjarrell 

The numbers have always exported when I have done this in the past.  Was your code in a code block in the past?  If you are in the confluence page you can easily copy the code without the numbers, could that have been what you did in the past?

David Fitzjarrell November 13, 2022

Hi Brant, Thanks for your reply.

I've done this in the past at it worked great. I still have the older documents produced this way.

Yes, I'm sure the code was in a code block before.

Brant Schroeder
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 13, 2022

@David Fitzjarrell Do you have access to the old pages in Confluence?  Can you look at them to see what the code block settings are an if they will still export without the numbers?

David Fitzjarrell November 13, 2022

The page settings look the same to me.

The page this worked on previously no longer works. The page numbers are there as well.

The last time this worked was before the new editor.

Do you think that has something to do with it?

Brant Schroeder
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 28, 2022

@David Fitzjarrell Do you have any pages that use the old editor still that you could test this out on?  It could be the new editor as it does impact certain aspects of the page but it would be good to confirm.

David Fitzjarrell November 28, 2022

@Brant SchroederIs there a way to know which version of the editor is in use?

Brant Schroeder
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 28, 2022

@David Fitzjarrell the response on this page is probably the best.  The issue is you will have to look at the editor to see which could take a while sorting through pages.  Maybe the older the page the better https://community.atlassian.com/t5/Confluence-questions/How-do-you-know-which-editor-a-page-uses/qaq-p/1412049 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events