Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Web Programming > HTML > HTML Code Clinic
Password Reminder
Register
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
HTML Code Clinic Do you have some HTML code you'd like to share and get suggestions from others for tweaking or improving it? This discussion is the place.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the HTML Code Clinic 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:21 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 multiple documentElement (html) objects in one doc

Hey,
I just want to know if we can have multiple HTMLs (documentElements) in one DOCUMENT (in the same frame/window)? if yes, then is there any way we could write some content into the second HTML document using the script in the first HTML and WITHOUT doing any DOM manipulations.

Thanks
Asim

Reply With Quote
  #2 (permalink)  
Old July 12th, 2006, 05:59 AM
Friend of Wrox
 
Join Date: Jan 2006
Location: San Francisco, CA, USA.
Posts: 198
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You cannot have multiple document elements in one document. You can, however, modify the HTML in the existing document element without using DOM manipulations by using document.write() calls or by modifying document.innerHTML.

Jon Emerson
http://www.jonemerson.net/
Reply With Quote
  #3 (permalink)  
Old July 14th, 2006, 02:40 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

Thanks Jon. But the problem is:
1) I cannot use innerHTML as it doesnot parse the generated Javascript (so no dynamic content could be achieved)
2) document.write() works but it overrides the entire HTML document.

I am generating an HTML page (with some javascript) using XSL and XML (retrieved using AJAX). Once i have the generated HTML, doing a document.write() overrides everything on that ASP page which has a couple of javascripts that I need for the generated HTML to work.

I have also tried to use document.open() and document.close() the problem holds even then.

Thanks anyways.
Asim

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
reading a html doc into outlook body message matpen Word VBA 5 June 21st, 2009 10:19 PM
how to finding the Graphic objects in word doc madhan_needs_help Word VBA 2 August 8th, 2007 10:38 AM
doc to html in linux amirshahzad Assembly Language 3 March 6th, 2007 07:11 AM
How can I view an XML doc to HTML format jolo98 XML 3 July 23rd, 2004 01:02 AM



All times are GMT -4. The time now is 11:00 AM.


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