Edit in place with tinyMCE

R

RonY

Hi all,

I am trying to find out an edit in place with tinyMCE support, so that
users can click on content and change it without any refresh page.

I have found some script that use prototype and a script called
eip.js, but i would like to know how to incorporate the tinyMCE editor
when the user - here is the link [
http://www.nick-dunn.co.uk/blog/2006/08/animating-editinplacejs-with-...
]

Does any know how or where to integrate the tinyMCE editor?

Here is my code:

+++++++++++++++++++++++++++++++++

<script type="text/javascript" src="prototype.js"></script>
<script type="text/javascript" src="moo.fx.js"></script>
<script type="text/javascript" src="editinplace.animated.js"></
script>
<script language="javascript" src="../tinymce/jscripts/tiny_mce/
tiny_mce.js"></script>
<script type="text/javascript">
tinyMCE.init( {
theme:"advanced",
mode: "exact",
elements : "content(151-25)"
})

Event.observe(window, 'load', init, false);
function init() {
// Overide the default saving_text and add the animated
GIF and saving message
EditInPlace.defaults["saving_text"] = "<img
src='indicator.gif' /><span class='eip_" +
EditInPlace.defaults["saving_class"] + "'>Saving
changes, please wait.</span>";
// Set the save_url to a CF page (which simply returns the
saved content as plain text)
EditInPlace.defaults["save_url"] = "update.cfm";
// Make the editableText
EditInPlace.makeEditable( { id:'content(151-25)', type:
'textarea', cols: '100' } );
EditInPlace.makeEditable( { id:'price(151-25)' } );
}
</script>

<div id="content(151-25)" title="Click to edit"> HERE IS THE CONTENT
</
div>
<span id="price(151-25)" title="Click to edit">36</span>

+++++++++++++++++++++++++++++++++

But i want to load the tinyMCE when the user clicks to edit the field
NOT upon page load, as what is happening now.

Thanks heaps guys,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,754
Messages
2,569,522
Members
44,995
Latest member
PinupduzSap

Latest Threads

Top