Blank Description After Pasting HTML

CableIntel
Tourist
7 0 2

In order to speed up product listing creation for similar products, we sometimes copy the HTML of the description from one listing, paste it into the HTML editor for a new listing and then edit it further. 

 

In the past day or so, we are experiencing a problem where this process results in a blank description in the editor, however saving the product and then going back into it will then display the description as normal.

 

I noticed that we now see an empty comment '<!---->' in the HTML editor on new listings so has there been an update that's causing this? Or have we enabled a setting that's causing the problem?

Replies 3 (3)

Mts0001
Shopify Partner
19 2 23

Discovered this issue today too. Similar situation - all descriptions are written in HTML to allow for custom class names / layout etc.

 

You are right, if a change is made in the code editor (Show HTML) it does not update in the (Show Editor) view. It will just show whatever was last saved/loaded (so if you are starting with a new blank product it will stay empty). As you say, it does seem to save despite what the editor is displaying.

 

However this update is also injecting code if you use some attributes in your HTML. Data attibutes (data-foo="bar") are being duplicated with a "data-sanitized" prefix, and some others like itemprop="" are also being prefixed which invalidates the code...

 

These issues seem to have been introduced with the updated editor (codemirror?) which is now showing code formatted in color with line numbers on the left.

 

Hoping this will be fixed soon.

CableIntel
Tourist
7 0 2

Glad to know it's not just us! Fingers crossed for a fix soon.

Mts0001
Shopify Partner
19 2 23

It looks as though Shopify have returned the product description editor to the one we are used to. It was only the product editor from what I could see, blogs and pages never changed.

I've tried a couple of quick tests and it doesn't seem to be altering the entered text now, and you see what you've entered when you switch between modes.

 

Make sure you refresh / clear cache if you're not seeing the original editor. Hopefully it didn't affect too many people. Good luck!