Announcement

Do not use the forums to submit bug reports, feature requests or patches, submit a New Ticket instead.

#1 2008-01-05 07:51:37

joeyadms
New member
Registered: 2008-01-05
Posts: 2

Copy contents of xinha editor

Ok i've searched and searched, and im pretty binded at the moment on time, so any help would be great. I'm using  Xinha for a page editor in an application I'm making, and, on the edit page, it shows a preview of what it would look like on the site if submitted. I've tried endless alerting and reading to try to find out how I can copy the contents of the editor.

Basically, the  js function  Takes the  value of  the textarea, and populates a div with it, so I somehow just need to load the value of the xinha editor in a variable without submitting the form.

Offline

#2 2008-01-05 11:45:22

quiraang
New member
Registered: 2008-01-01
Posts: 3

Re: Copy contents of xinha editor

Try:

var myText = xinha_editors.yourEditor.outwardHtml(xinha_editors.yourEditor.getHTML())

is this what you want?

Offline

#3 2008-01-05 11:50:53

joeyadms
New member
Registered: 2008-01-05
Posts: 2

Re: Copy contents of xinha editor

Oh yes! Thank you.  My JS sucks, I think at one time I was trying  xinha_editors.outwardHTML(xinha_editors.getHTML()) egh so close.

Also I was wondering is there a way to add an event , such as onkeyup() to the editor, I was hoping to do a "preview as you type" type of deal.

Thanks again!

Offline

Board footer

Powered by FluxBB