How can you use the "contenteditable" attribute to edit your site or lists but not have the general public do the same.

Maybe just in a admin panel view?

and

Is this just easier for the developer to change content on the fly?

I just don't see how it can be used yet.

Recommended Answers

All 9 Replies

After looking through various blogs and tutorials - I don't see much of a use for it right now either except as a trick. There's no provision for saving the changes except for locally (on the user's machine - maybe.) If you're doing updates on a blog the changes still have to go through a form or other mechanism to write the changes to the page on the server.

Maybe it might help a developer to see how changes will look before implementing them.

One place I just thought of - it might be useful if you had a page where the user was encouraged to do customization and then print or save the results - like custom Christmas cards or story books.

this scrap

javascript:document.body.contentEditable='true'; document.designMode='on'; void 0

as the href of a link or saved as a favorite, makes any page play-with-able

this scrap

javascript:document.body.contentEditable='true'; document.designMode='on'; void 0

as the href of a link or saved as a favorite, makes any page play-with-able

Umm...I am at a sticky spot with JavaScript. I am not understanding it! Very frustrating! I am tackling it though at the moment.

How does this line solve the questions or issues of the admin ONLY editing the page?

It doesn't - the content is editable for users and savable by them on their computer. But it's not saved on the server - which is what I assume you're asking.

It doesn't - the content is editable for users and savable by them on their computer. But it's not saved on the server - which is what I assume you're asking.

true, making the content editable only for the admin or when admin logged-in. Any suggestions?

Okay, what I think you're asking is for something that will allow the admin to edit the webpage on the fly, making edits that will be seen by everyone?

In that case you're taking about some version of content management software (CMS)

I guess I don't see a global use of this new feature.

If a admin could login then see his site and edit at the same time, maybe text alone, the "on the fly" would be nice in this aspect. But giving everyone the ability to edit content doesn't have real value.

...wait a Wiki could use this...since all the content is editable....yay found the useful solution!

But this doesn't edit the actual website content, only the content that's on the user's machine. Single user games maybe.

hence the phrase play-with-able
there are some scripts that make certain areas editable to users with the required passwords, and save a change history, will repost a USEFUL link if I can remember the google search from the last time this was asked, many thousands of threads ago, could be somewhere in the daniweb searchbox

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.