Jump to content

How to access page setup menu of a browser


sajan

Recommended Posts

Hi I would like to know how can we access the page setup menu of a browser through javascript.It will be useful to change the header and footer when a page with no menu bar to be printed.thanks

Link to comment
Share on other sites

Hi.. If you are talking about window.open() then it has some params like menubar=no, scrollbar=no, etc.. or specially if u r talking abt the menu generated by code then for that u have to generate css likewise and enable, decable accordingly...Regards,Vijay

Link to comment
Share on other sites

If you are talking about window.open() then it has some params like menubar=no, scrollbar=no, etc..or specially if u r talking abt the menu generated by code then for that u have to generate css likewise and enable, decable accordingly...
I mean ,for printing i used window.print method and for new window uses window.open and give whatever parameters required like scrollbars=1 .This won't show the menu bar of the browser(pop up for printing).But it prints the header and footer such as url and date on the printed page.Of course i know that through page setup menu i can choose whether to print header or footer.But in this case the popup window has no menu bar and so i can't go to page setup menu through file. So i like to know whether there any javascript method to access page setup menu.By the way i got another problem while experimenting with the script.
window.open("url","","","scrollbars=1","width=685","height=600");

when i used menu bar=1

window.open("url","","menu bar=1","scrollbars=1","width=685","height=600");

the scrolling of window disappeared.what could be the reason?

Link to comment
Share on other sites

Hi thanx for giving me the link.But that's manual method,what i need is a script which can manipulate the header and footer of a browser automatically when a window open so user won't have to manually change the header and footer before printing.

Link to comment
Share on other sites

That link is for using ASP.NET to access the registry and edit settings with IE. I'm not sure if you can change the registry settings on the client, I would think that would only work on the server. In fact, I really really hope that you can NOT change the client's registry settings. If so, that is one more reason not to use IE. The code on that page is IE-only, it requires VBScript to run.Now, about the original question:

I would like to know how can we access the page setup menu of a browser through javascript
You can't.
Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...