Making content editable
-
Hello,
trying to make a div's content editable (paragraph/span).Each time, editing a block and going into a source code option to add «contentEditable="true" » it is deleted.
Could you help or suggest a different solution?This is for a sake of a website presenting typefaces, and this option would be a good feature to have.
Thanks!
-
Dear @polczynski
Try this! 🌝
I have created a Text Element in the Gridder:

With an ID - "editable" (it could be anything you wish) :

Then Using the following jQuery: https://stackoverflow.com/questions/3655156/html5-contenteditable-with-jquery
jQuery('#editable *').attr('contenteditable','true');Now i can edit it:

I would suggest wrapping it in a new page event and inserting it into > Lay Options > Custom CSS & HTML > Custom <Head> Content:
<script> window.laytheme.on("newpageshown", function(layoutObj, type, obj){ jQuery('#editable *').attr('contenteditable','true'); }); </script>
Hope this helps @polczynski & best wishes 🌻
Richard
-
That works perfectly.
Thank you so much!Best!
-
No worries @polczynski Merry Christmas!!! 🎄
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login