You are not logged in.
i have a form:
<form onsubmit='ajax('page.php', 'resdiv');return false'>...</form>
<div id='resdiv'></div>
page.php is a page contain a editor in textarea.
i use:
document.getElementById('resdiv').innerHTML = responseText;
But, not show.
help me.
Offline
i'll describe more...
i have a form:
<form method='GET' action='page.php' onsubmit="ajax(this.action, 'resdiv'); return false">
<input type='submit'>
</form>
<div id='resdiv'>result here! </div>
page.php contains a textarea with editor:
<textarea id='editor' name='editor'></textarea>
i want to when i submit form, it must response content of page.php with textarea editor.
Really, it responses a content of page.php but not editor show in textarea.
Must be a feature of Xinha? With 'load' event, it show..., reverse not show.
Who can help me ?
I like xinha editor very much, beause it has many things i need and graphic has many choices, very good.
But i has that error, so i ...
//222222222222222222222222222222222222222222222222
var div = "";
function ajax(url, resdiv){
div = resdiv;
var req = createHttpRequest();
if (req){
req.onreadystatechange = onReadyDo;
req.open("GET", url, true);
req.send(null);
}
}
function onReadyDo(){
if ((req.readyState = 4) && (req.state == 200)){
var data = req.responseText;
var d = document.getElementById(div);
d.innerHTML = data;
}
}
//2222222222222222222222222222222222222222222222222
Offline
Hi, I have exactly the same problem.
I started a topic and I'm suscribing to every topic related.
Hope we can keep in touch, I haven't found the answer yet.
My topic is called
Xinha, Ajax, httpRequest object and innerHtml property
Channis
Offline