Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Web Programming > JavaScript > Javascript How-To
| 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 software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old March 20th, 2008, 09:53 AM
Registered User
 
Join Date: Mar 2008
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to markmon
Default Remove/Hide Div in Javascript Popup

I'm a javascript newbie and I could use some help with the following issue.

Is it possible to create a popup window that, when the user clicks, will remove a div tag(s) from the page which appears in the new window. An example would be like when you click "print this page" on a page and all you get is the text of a page in a new window (with the header, footer, and nav items removed.

I don't even know if javascript is what I should be using for this so any suggestions (using alternatives) are welcome.

Thanks,
Mark
  #2 (permalink)  
Old March 24th, 2008, 08:17 AM
Friend of Wrox
 
Join Date: Mar 2007
Location: Hyderabad, A.P., India.
Posts: 373
Thanks: 0
Thanked 1 Time in 1 Post
Default

If you want this solution just for printing a page then CSS will be enough, no need for java script.

- Rakesh
  #3 (permalink)  
Old March 24th, 2008, 09:10 AM
Registered User
 
Join Date: Mar 2008
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to markmon
Default

This solution is needed so that no navigation can occur in the new page. Printing a page was just an example. I don't want the user to be prompted which printer to select (like most "print a page" examples).

Can you provide me with sample CSS code for this purpose?

Mark



Similar Threads
Thread Thread Starter Forum Replies Last Post
remove the status bar from popup window crmpicco Javascript How-To 1 December 4th, 2007 06:15 PM
remove <div>-element Kabe Classic ASP Professional 0 November 9th, 2007 05:41 AM
How to hide combo box behind the popup menu? mohini ASP.NET 1.x and 2.0 Application Design 4 March 22nd, 2006 12:22 AM
hide the <div> crmpicco Javascript How-To 1 August 22nd, 2005 09:43 PM
Hide div unless user logged in DanDan PHP How-To 4 January 21st, 2005 08:21 PM





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