Common issues that will cause it to break:
- nested editable elements
- duplicate IDs
- Unclosed tags
Hi again Angel,
I gave a look at your code and it seems pretty clean.
I detected that module id="col-1-module" has the Mktoaddbydefault set twice.
Also, you should use mktoText rather than mktEditable, and I am not sure that setting them on <span> tags it a good idea. Use <div< instead. For images, use the mktoImg on a <div> too. mktEditable is inherited from v1 templates and is only there for backward compatibility.
Agree with Greg's comments. Did removing the extra mktoaddbydefault solve this for you? I also would agree mktoText on <div> is the optimal way to define the editable text region for best results.
Oh, thanks for checking Grégoire!
The reason why I'm using <span> instead of a <div> is because I want to avoid defining display: inline on those elements since divs will always break into a new line.
I did not know mktoEditable was deprecated but the reason we are using them is because it's easier for our team to edit content with a full WYIWG rather than the image browser but I guess the mktoText will do the trick.
Thanks again, I'll try those changes and let you know.
mktEditable and mktoText are equivalent. Both will give users the TinyMCE rich-text editor to have full editing functionality.