I'm working on a simple webpage for a company and the company wants to be able to edit the content themselves from time to time. However they have no programing knowledge and therefore I want to use an embedded HTML editor, I have chosen jQuery TE.
The problem is that I only know how to use this as a form, e.g.:
<form id = "wyForm" method="post" action="test.php">
<textarea class="editor"name = "testText">Hi</textarea>
<input type="submit" class="wymupdate" />
</form>
Then I would convert the textarea to an editor with jQuery:
<script> $('.editor').jqte() </script>
This makes it possible to send the result to a .php page that updates the database. However many times I don't want to use a textfield or a form, but just a simple object that I convert to an editor in the same way. But how do I save the change in that case?
instead as I want the user to be able to toggle the edit-mode by a button. In that case, the user sees a text (e.g. in a span) and is then able to press "edit" (which transforms the span to a jQuerty TE field) to edit that span. The user can then save by using a save button. If it is a text field, the user can already before pressing the button edit the text, but have to press the button to use the jQuerty TE. This becomes very confusing and uggly
– Christian.H Jul 31 '13 at 21:35