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
| 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
Thread Tools Search this Thread Display Modes
  #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.

Reply With Quote
  #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

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

- Rakesh
Reply With Quote
  #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

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?


Reply With Quote

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
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

All times are GMT -4. The time now is 09:38 PM.

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