Problems with Formatting when Content is Pasted from an Unknown Source

Still need help?

The Atlassian Community is here for you.

Ask the community

Symptoms

Users experience the following errors in the Confluence editor when they copy and paste external content into Confluence:

  • Font color might change from the default color that you are currently using
  • Cursor might disappear as soon as you paste content

Example of error:

Diagnosis

Install the Confluence Source Editor from Atlassian Marketplace. Edit the page in question and launch the source editor by clicking the  button on the editor toolbar. Look for extra <span> tags like the following example:

<span style="color: rgb(0,0,0);"> </span>

Cause

Additional span tags can disrupt page styles when Confluence renders content following the extraneous tags. Since Confluence only understands custom tags that it uses to render a page, any unknown special characters could cause Confluence to render these tags with errors.

Resolution

  1. Install the free Confluence Source Editor, which will allow you to view the underlying storage format of a page.
  2. Remove unnecessary span tags.

  3. Save the page.

Be careful when copying/pasting external content as it could contain extra HTML elements that trigger this issue.

The scope of this issue could be large, especially if your users often copy/paste external content into Confluence. Furthermore, it's possible that one block of pasted text could contain multiple <span> tags, so be sure to remove all of the offending tags.



Last modified on Apr 21, 2023

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.