Re: better innerHTML
- From: Randy Webb <HikksNotAtHome@xxxxxxx>
- Date: Wed, 01 Mar 2006 03:19:16 -0500
Praveen said the following on 3/1/2006 1:49 AM:
Im looking for some better ideas,samples,documentation for doing the folowing.
I have 5 tabs in my asp page.Each contains a <span>.
Im doing clientside transform for filling the contents of the span, by changing the innerHTML of span.
My xsl is cached in the client side (xslt template/processor) which contains templates for all the span.
So for each span Im requesting the server(xmlhttp) for xml and doing a transform using the cached xsl and changing the innerHTML of the corresponding span.
This is fine as of now.
BUT I know that my transformed output is going to be huge and I read that changing innerHTML is not a proper way for doing this.
This hangs the browser for some seconds. I want to fill the tabs Asynchronous so that it wont hangs the browser.
This article:
<URL: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dndude/html/dude100499.asp >
Covers innerHTML versus other methods. It deals with the creation of a table instead of plain HTML but the principle is the same.
spanRef.nodeValue is where you should start looking for some speed increases.
--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
.
- References:
- better innerHTML
- From: Praveen
- better innerHTML
- Prev by Date: better innerHTML
- Next by Date: JS opens about:blank
- Previous by thread: better innerHTML
- Next by thread: JS opens about:blank
- Index(es):
Relevant Pages
|