Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Javascript CSS
When I print a webpage from Internet Explorer it will automatically add a header and footer including the website title, URL, date, and page number.
 
Is it possible to hide the header and footer programatically using Javascript or CSS?
Posted 13-Sep-12 0:39am
Edited 13-Sep-12 0:44am
v2
Comments
Mohibur Rashid at 13-Sep-12 5:49am
   
How about changing your method of printing? such as using pdf?
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Hi,
 
I guess you cannot handle this kind of client browser setting from your asp.net page niether from CSS or javascript. if the print should come without headers and footers, then you have to change the setting of the client browser. Goto File - PageSetup, make header and footer as empty.
 
hope it helps.
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Hi,
 
Have a look at below discussions,
 
http://forums.asp.net/t/1421429.aspx[^]
 
http://stackoverflow.com/questions/4359643/remove-the-url-date-page-no-while-taking-print[^]
 
Hope you got answer from first URL.
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 BillWoodruff 300
1 Mathew Soji 274
2 Afzaal Ahmad Zeeshan 268
3 DamithSL 225
4 Sergey Alexandrovich Kryukov 205
0 OriginalGriff 6,249
1 Sergey Alexandrovich Kryukov 5,853
2 DamithSL 5,183
3 Manas Bhardwaj 4,673
4 Maciej Los 3,865


Advertise | Privacy | Mobile
Web04 | 2.8.1411019.1 | Last Updated 13 Sep 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100