innerHTML and potential Safari bug(?)
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Michael_Doleman
Posted On:   Thursday, February 2, 2006 02:49 PM

I'll have to admit to being a total AJAX newbie, but so far I've had good success implementing basic techniques. I am doing some very basic asynchronous page updates by making use of innerHTML on some ID-tagged DIVs. In one particular instance I am giving users a button that allows them to toggle between different views. A click fires the javascript to call a servlet component that just sends back basic markup (I am sending it as text/plain). I'm doing it this way because the performance cost of getting an XML doc back, parsing it, and adding individual nodes, is horrendous. The innerHTML method is 20 times faster. This all works fine. Except in Safari (1.3), wherein the aforementioned DIV will update with the new content exac   More>>

I'll have to admit to being a total AJAX newbie, but so far I've had good success implementing basic techniques.

I am doing some very basic asynchronous page updates by making use of innerHTML on some ID-tagged DIVs.

In one particular instance I am giving users a button that allows them to toggle between different views. A click fires the javascript to call a servlet component that just sends back basic markup (I am sending it as text/plain). I'm doing it this way because the performance cost of getting an XML doc back, parsing it, and adding individual nodes, is horrendous. The innerHTML method is 20 times faster.

This all works fine. Except in Safari (1.3), wherein the aforementioned DIV will update with the new content exactly twice, but no more. I am getting a good response with correct readystate and status codes. It's just that the DIV will not update.

Is this a bug? Is there a work-around? Or does it sound like I'm doing something entirely wrong?

   <<Less

Re: innerHTML and potential Safari bug(?)

Posted By:   Christopher_Koenigsberg  
Posted On:   Sunday, February 5, 2006 11:05 AM

Is "innerHtml" a W3C standard? I don't remember, but I don't think it is, so if not, you're on shaky ground by using it.
About | Sitemap | Contact