"Data-mce-..." are added to HTLM to product descprition

Jerry00
Visitor
2 0 2
Hello,
 
In product descriptions, when I add images, a bunch of "mce-data-..." appears in the html lines. 
 
This causes duplicated content and extra html lines, which I assume is not good for my store.
 
Can you help me with that? Have you encountered this problem before?
 
Thank you!!
Replies 10 (10)

diego_ezfy
Shopify Partner
2958 568 890

Hello,

This is very likely coming from some app. It's called data attribute and data attributes per se are harmless, it won't slow down your website or anything, so I wouldn't worry about it.

Kind regards,
Diego 

◦ Follow my blog & youtube for coding tutorials.
◦ Replace apps with copy/paste code snippets and save money.
Jerry00
Visitor
2 0 2

Hello Diego, 

Thank you for your reply.

Is there a way we can know for sure where it is coming from?

Is it normal that the html is duplicated rather than having only the data attributes? And can you tell if the data attributes are harmless in my case according to the screenshots?

Thanks again!

Jerry00_1-1600391483512.png

Jerry00_2-1600391591690.png

 

 

 

Adrien63
Visitor
2 0 0

Hello, I have it on my store and I only have the apps Dsers and SEO King. Therefore I think it comes from SEO King

greggmoore
Visitor
2 0 2

Yes, it is a "data attribute" element. Will it slow your site down? No. However, it could cause your HTML to go awry! I believe that has more to do with how Shopify's WYSIWYG editor handles the formatting.

rslygh
Shopify Partner
10 0 10

I know this is an old topic, but I see the data-mce-fragment get added to the HTML when someone is copying/pasting text from Microsoft Office apps to Shopify. It's very possible that other apps work the same way.

 

Many times a person will write the product copy in some other document then send to someone else to be entered in Shopify. Then the person entering the text into Shopify does a quick copy/paste to load the data, and those tags end up coming across but most people don't even notice because they're hidden in the file the text was sent in, and the default Shopify editor doesn't show them either. You'd have to be looking at the HTML source to see them.

jessmacedo
Shopify Partner
7 0 7

Yes!! It happens if you are copying from Microsoft Word. We can either delete it after copying and pasting it. Or we can copy the text on the code part and manually format it (my way, since the code looks cleaner).

labrat
Shopify Partner
1 0 1

I'm not sure it's coming from Microsoft Office, I've taken tables through an HTML cleaner to remove all the data-mce-selected= and anything that isn't the most basic html from the table and then put the cleaned code for the table back on my shopify page and after I save the data-mce-selected= is back on every line of code

dangkhiem
Shopify Partner
17 0 3

In my HTML lines also appears the code data-mce-fragment="1". And it repeats on all lines. My store doesn't have any apps, and I edit content directly on shopify rather than copying from another editor (like Word). This makes me very confused, should I delete those pieces of code or not?

jessmacedo
Shopify Partner
7 0 7

Hi,

To be honest, it makes no difference, I wouldn't stress about that. I always clean that, because I like to work with the code, and it makes it harder to see the changes I am making. But other than that, doesn't change anything. 

SJBW
Tourist
6 0 10

this happened to me because i was pasting from microsoft office. I pasted it in to a gmail email, and then copied it from there. No more extra html lines.