Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Web Programming > JavaScript > Javascript How-To
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
Javascript How-To Ask your "How do I do this with Javascript?" questions here.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Javascript How-To section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old July 7th, 2006, 03:11 PM
Registered User
Points: 31, Level: 1
Points: 31, Level: 1 Points: 31, Level: 1 Points: 31, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: May 2006
Location: Kanata, Ontario, Canada.
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
Default Document.write

Hi,
I have an HTML page dynamically generated using XSL and XML data. There is also some dynamic javascript in that page too. Now the problem is that I can retrieve the HTML using "transformToText" method (using the zXML library provided by authors of Professional AJAX) or by transformNode method provided by I.E. Both of these methods return a string.

When I do a document.write(strHTML), it overrides everything on the page that is currently running on the browser. Is there anyway, I could append the newly generated HTML to the currently running HTML (coded in an ASP page)so that I could retain all the 'javascript includes" from it and use them with the newly generated HTML.

Your help and a quick is deeply appreciated.

Thanks,
Asim


Reply With Quote
  #2 (permalink)  
Old July 8th, 2006, 09:07 AM
Friend of Wrox
 
Join Date: Nov 2005
Location: Rotterdam, , Netherlands.
Posts: 223
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi,

Can you tell what it overrides and what are you trying to do?. If the javascript is only clientside this means that it does not see any asp code.

__________________________________________________ ________
This is my junk I'm gona eat it
Reply With Quote
  #3 (permalink)  
Old July 12th, 2006, 05:20 AM
Friend of Wrox
 
Join Date: Jan 2006
Location: San Francisco, CA, USA.
Posts: 198
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Look at the innerHTML property on the document object, or on any <div>-type element. I usually prefer to have a dedicated <div> for this type of design.

Jon Emerson
http://www.jonemerson.net/
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Write a XML Document using java. vinitpugaliya XML 0 January 8th, 2007 06:26 AM
Write Nested XML document into SQL Server tables boondocksaint20 VB.NET 0 May 2nd, 2006 12:35 PM
document.write into cell or td with Opera crmpicco Javascript How-To 0 April 11th, 2006 04:58 AM
Write a document to the server Hal Emmerich Javascript How-To 1 November 13th, 2004 07:15 AM
write() without clearing old document Snib Javascript How-To 4 January 21st, 2004 04:28 PM



All times are GMT -4. The time now is 02:52 AM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.