PC Review


Reply
Thread Tools Rate Thread

How can I put a shortcut on a web page to print the page?

 
 
=?Utf-8?B?TWF1cmVlbg==?=
Guest
Posts: n/a
 
      29th Mar 2007
I'm using FrontPage 2002 with our web site hosted on a Windows platform.
--
Maureen
 
Reply With Quote
 
 
 
 
Tom Willett
Guest
Posts: n/a
 
      29th Mar 2007
Print Button (Courtesy of MVP Murray):

Put this in the head of the document -

<script type="text/javascript">
function print_page(where){
var is_mac=(navigator.platform.indexOf("ac") != -1);
(document.all && is_mac)?
alert("Select \"Print\" from the menu") : where? where.window.print() :
window.print();
}
</script>

Put this in the body of the document -
<a href="javascriptrint_page()">Print this</a>
---
--
===
Tom Willett
Microsoft MVP - FrontPage
---
FrontPage Support:
http://www.frontpagemvps.com/
===
"Maureen" <(E-Mail Removed)> wrote in message
news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
| I'm using FrontPage 2002 with our web site hosted on a Windows platform.
| --
| Maureen


 
Reply With Quote
 
=?Utf-8?B?TWF1cmVlbg==?=
Guest
Posts: n/a
 
      30th Mar 2007
Thank you so much for your help. I have a couple more questions though.

When I cut and pasted the text into the HTML, I had to put <s and >s back
in, and it turned blue like the rest of the code before it.

The section starting with "function print" and ending with "}" is red
instead of blue. Is there something else I need to put in there, or is the
red OK?

It works, so maybe the red is OK.

<script type="text/javascript">
function print_page(where){var is_mac=(navigator.platform.indexOf("ac") !=
-1);
(document.all && is_mac)?
alert("Select \"Print\" from the menu") : where? where.window.print() :
window.print();
}
</script>

Also, is there a way to make that print page command print in landscape
format? I obviously have a lot to learn about creating web pages 'cause when
they print portrait, it causes some text to go to a second line even though
it appears the way it should on the web site.

Thank you again for your help. I'm learning - slowly, but surely!
--
Maureen


"Tom Willett" wrote:

> Print Button (Courtesy of MVP Murray):
>
> Put this in the head of the document -
>
> <script type="text/javascript">
> function print_page(where){
> var is_mac=(navigator.platform.indexOf("ac") != -1);
> (document.all && is_mac)?
> alert("Select \"Print\" from the menu") : where? where.window.print() :
> window.print();
> }
> </script>
>
> Put this in the body of the document -
> <a href="javascriptrint_page()">Print this</a>
> ---
> --
> ===
> Tom Willett
> Microsoft MVP - FrontPage
> ---
> FrontPage Support:
> http://www.frontpagemvps.com/
> ===
> "Maureen" <(E-Mail Removed)> wrote in message
> news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
> | I'm using FrontPage 2002 with our web site hosted on a Windows platform.
> | --
> | Maureen
>
>
>

 
Reply With Quote
 
Stefan B Rusynko
Guest
Posts: n/a
 
      31st Mar 2007
1) You paste it in code/html view in the head section
2) No you can not control the users print layout (to landscape)

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
_____________________________________________


"Maureen" <(E-Mail Removed)> wrote in message news:5F43AA1E-E600-4707-AA8B-(E-Mail Removed)...
| Thank you so much for your help. I have a couple more questions though.
|
| When I cut and pasted the text into the HTML, I had to put <s and >s back
| in, and it turned blue like the rest of the code before it.
|
| The section starting with "function print" and ending with "}" is red
| instead of blue. Is there something else I need to put in there, or is the
| red OK?
|
| It works, so maybe the red is OK.
|
| <script type="text/javascript">
| function print_page(where){var is_mac=(navigator.platform.indexOf("ac") !=
| -1);
| (document.all && is_mac)?
| alert("Select \"Print\" from the menu") : where? where.window.print() :
| window.print();
| }
| </script>
|
| Also, is there a way to make that print page command print in landscape
| format? I obviously have a lot to learn about creating web pages 'cause when
| they print portrait, it causes some text to go to a second line even though
| it appears the way it should on the web site.
|
| Thank you again for your help. I'm learning - slowly, but surely!
| --
| Maureen
|
|
| "Tom Willett" wrote:
|
| > Print Button (Courtesy of MVP Murray):
| >
| > Put this in the head of the document -
| >
| > <script type="text/javascript">
| > function print_page(where){
| > var is_mac=(navigator.platform.indexOf("ac") != -1);
| > (document.all && is_mac)?
| > alert("Select \"Print\" from the menu") : where? where.window.print() :
| > window.print();
| > }
| > </script>
| >
| > Put this in the body of the document -
| > <a href="javascriptrint_page()">Print this</a>
| > ---
| > --
| > ===
| > Tom Willett
| > Microsoft MVP - FrontPage
| > ---
| > FrontPage Support:
| > http://www.frontpagemvps.com/
| > ===
| > "Maureen" <(E-Mail Removed)> wrote in message
| > news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
| > | I'm using FrontPage 2002 with our web site hosted on a Windows platform.
| > | --
| > | Maureen
| >
| >
| >


 
Reply With Quote
 
=?Utf-8?B?TWFyayBFLg==?=
Guest
Posts: n/a
 
      11th Jul 2007
None of those things work. In fact, when I tried them they only moved stuff
around on my site that wasn't supposed to be moved. Is there just a simple
walkthrough for doing this? Is there a specific place to paste this code?
Why can't explanations just be in standard English for this stuff?

Mark

"Tom Willett" wrote:

> Print Button (Courtesy of MVP Murray):
>
> Put this in the head of the document -
>
> <script type="text/javascript">
> function print_page(where){
> var is_mac=(navigator.platform.indexOf("ac") != -1);
> (document.all && is_mac)?
> alert("Select \"Print\" from the menu") : where? where.window.print() :
> window.print();
> }
> </script>
>
> Put this in the body of the document -
> <a href="javascriptrint_page()">Print this</a>
> ---
> --
> ===
> Tom Willett
> Microsoft MVP - FrontPage
> ---
> FrontPage Support:
> http://www.frontpagemvps.com/
> ===
> "Maureen" <(E-Mail Removed)> wrote in message
> news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
> | I'm using FrontPage 2002 with our web site hosted on a Windows platform.
> | --
> | Maureen
>
>
>

 
Reply With Quote
 
SingaporeWebDesign
Guest
Posts: n/a
 
      12th Jul 2007
Hello,

See
http://www.dynamicdrive.com/dynamicindex9/other1.htm

--
Singapore Web Design
http://www.bootstrike.com/Webdesign/
Singapore Web Hosting
http://www.bootstrike.com/WinXP/faq.html
Windows XP FAQ

"Mark E." <(E-Mail Removed)> wrote in message
news:12633897-99D2-4C59-A5DB-(E-Mail Removed)...
> None of those things work. In fact, when I tried them they only moved
> stuff
> around on my site that wasn't supposed to be moved. Is there just a
> simple
> walkthrough for doing this? Is there a specific place to paste this code?
> Why can't explanations just be in standard English for this stuff?
>
> Mark
>
> "Tom Willett" wrote:
>
>> Print Button (Courtesy of MVP Murray):
>>
>> Put this in the head of the document -
>>
>> <script type="text/javascript">
>> function print_page(where){
>> var is_mac=(navigator.platform.indexOf("ac") != -1);
>> (document.all && is_mac)?
>> alert("Select \"Print\" from the menu") : where? where.window.print() :
>> window.print();
>> }
>> </script>
>>
>> Put this in the body of the document -
>> <a href="javascriptrint_page()">Print this</a>
>> ---
>> --
>> ===
>> Tom Willett
>> Microsoft MVP - FrontPage
>> ---
>> FrontPage Support:
>> http://www.frontpagemvps.com/
>> ===
>> "Maureen" <(E-Mail Removed)> wrote in message
>> news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
>> | I'm using FrontPage 2002 with our web site hosted on a Windows
>> platform.
>> | --
>> | Maureen
>>
>>
>>



 
Reply With Quote
 
=?Utf-8?B?TWFyayBFLg==?=
Guest
Posts: n/a
 
      14th Jul 2007
Wow, thanks. Now I just need an email one. Been going nuts for weeks trying
to figure this out.

Mark

"SingaporeWebDesign" wrote:

> Hello,
>
> See
> http://www.dynamicdrive.com/dynamicindex9/other1.htm
>
> --
> Singapore Web Design
> http://www.bootstrike.com/Webdesign/
> Singapore Web Hosting
> http://www.bootstrike.com/WinXP/faq.html
> Windows XP FAQ
>
> "Mark E." <(E-Mail Removed)> wrote in message
> news:12633897-99D2-4C59-A5DB-(E-Mail Removed)...
> > None of those things work. In fact, when I tried them they only moved
> > stuff
> > around on my site that wasn't supposed to be moved. Is there just a
> > simple
> > walkthrough for doing this? Is there a specific place to paste this code?
> > Why can't explanations just be in standard English for this stuff?
> >
> > Mark
> >
> > "Tom Willett" wrote:
> >
> >> Print Button (Courtesy of MVP Murray):
> >>
> >> Put this in the head of the document -
> >>
> >> <script type="text/javascript">
> >> function print_page(where){
> >> var is_mac=(navigator.platform.indexOf("ac") != -1);
> >> (document.all && is_mac)?
> >> alert("Select \"Print\" from the menu") : where? where.window.print() :
> >> window.print();
> >> }
> >> </script>
> >>
> >> Put this in the body of the document -
> >> <a href="javascriptrint_page()">Print this</a>
> >> ---
> >> --
> >> ===
> >> Tom Willett
> >> Microsoft MVP - FrontPage
> >> ---
> >> FrontPage Support:
> >> http://www.frontpagemvps.com/
> >> ===
> >> "Maureen" <(E-Mail Removed)> wrote in message
> >> news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
> >> | I'm using FrontPage 2002 with our web site hosted on a Windows
> >> platform.
> >> | --
> >> | Maureen
> >>
> >>
> >>

>
>
>

 
Reply With Quote
 
=?Utf-8?B?TWFyayBFLg==?=
Guest
Posts: n/a
 
      14th Jul 2007
Ok, just tried it on my site and nothing. Would this go in the body of a
post/story on a site used to blog or in the index of the main site?

Mark

"SingaporeWebDesign" wrote:

> Hello,
>
> See
> http://www.dynamicdrive.com/dynamicindex9/other1.htm
>
> --
> Singapore Web Design
> http://www.bootstrike.com/Webdesign/
> Singapore Web Hosting
> http://www.bootstrike.com/WinXP/faq.html
> Windows XP FAQ
>
> "Mark E." <(E-Mail Removed)> wrote in message
> news:12633897-99D2-4C59-A5DB-(E-Mail Removed)...
> > None of those things work. In fact, when I tried them they only moved
> > stuff
> > around on my site that wasn't supposed to be moved. Is there just a
> > simple
> > walkthrough for doing this? Is there a specific place to paste this code?
> > Why can't explanations just be in standard English for this stuff?
> >
> > Mark
> >
> > "Tom Willett" wrote:
> >
> >> Print Button (Courtesy of MVP Murray):
> >>
> >> Put this in the head of the document -
> >>
> >> <script type="text/javascript">
> >> function print_page(where){
> >> var is_mac=(navigator.platform.indexOf("ac") != -1);
> >> (document.all && is_mac)?
> >> alert("Select \"Print\" from the menu") : where? where.window.print() :
> >> window.print();
> >> }
> >> </script>
> >>
> >> Put this in the body of the document -
> >> <a href="javascriptrint_page()">Print this</a>
> >> ---
> >> --
> >> ===
> >> Tom Willett
> >> Microsoft MVP - FrontPage
> >> ---
> >> FrontPage Support:
> >> http://www.frontpagemvps.com/
> >> ===
> >> "Maureen" <(E-Mail Removed)> wrote in message
> >> news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
> >> | I'm using FrontPage 2002 with our web site hosted on a Windows
> >> platform.
> >> | --
> >> | Maureen
> >>
> >>
> >>

>
>
>

 
Reply With Quote
 
SingaporeWebDesign
Guest
Posts: n/a
 
      14th Jul 2007
Hello,

Body is preferable. Do you have the site online for us to take a look and
assist you better?

--
Singapore Web Design
http://www.bootstrike.com/Webdesign/
Singapore Web Hosting
http://www.bootstrike.com/WinXP/faq.html
Windows XP FAQ

"Mark E." <(E-Mail Removed)> wrote in message
news:2ED32544-CB35-4F34-8E47-(E-Mail Removed)...
> Ok, just tried it on my site and nothing. Would this go in the body of a
> post/story on a site used to blog or in the index of the main site?
>
> Mark
>
> "SingaporeWebDesign" wrote:
>
>> Hello,
>>
>> See
>> http://www.dynamicdrive.com/dynamicindex9/other1.htm
>>
>> --
>> Singapore Web Design
>> http://www.bootstrike.com/Webdesign/
>> Singapore Web Hosting
>> http://www.bootstrike.com/WinXP/faq.html
>> Windows XP FAQ
>>
>> "Mark E." <(E-Mail Removed)> wrote in message
>> news:12633897-99D2-4C59-A5DB-(E-Mail Removed)...
>> > None of those things work. In fact, when I tried them they only moved
>> > stuff
>> > around on my site that wasn't supposed to be moved. Is there just a
>> > simple
>> > walkthrough for doing this? Is there a specific place to paste this
>> > code?
>> > Why can't explanations just be in standard English for this stuff?
>> >
>> > Mark
>> >
>> > "Tom Willett" wrote:
>> >
>> >> Print Button (Courtesy of MVP Murray):
>> >>
>> >> Put this in the head of the document -
>> >>
>> >> <script type="text/javascript">
>> >> function print_page(where){
>> >> var is_mac=(navigator.platform.indexOf("ac") != -1);
>> >> (document.all && is_mac)?
>> >> alert("Select \"Print\" from the menu") : where? where.window.print()
>> >> :
>> >> window.print();
>> >> }
>> >> </script>
>> >>
>> >> Put this in the body of the document -
>> >> <a href="javascriptrint_page()">Print this</a>
>> >> ---
>> >> --
>> >> ===
>> >> Tom Willett
>> >> Microsoft MVP - FrontPage
>> >> ---
>> >> FrontPage Support:
>> >> http://www.frontpagemvps.com/
>> >> ===
>> >> "Maureen" <(E-Mail Removed)> wrote in message
>> >> news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
>> >> | I'm using FrontPage 2002 with our web site hosted on a Windows
>> >> platform.
>> >> | --
>> >> | Maureen
>> >>
>> >>
>> >>

>>
>>
>>



 
Reply With Quote
 
=?Utf-8?B?TWFyayBFLg==?=
Guest
Posts: n/a
 
      14th Jul 2007
Yes, thanks. The site is www.regimeofterror.com.
I am trying to use FrontPage or anything to add a "Print this" and "Email
This" function so my readers can do both. I'd like to ideally add it to the
top right of each story and am willing to do this manually each time or build
it into the code for the entire site if need be.

Your help is greatly appreciated.

Thanks,
Mark

"SingaporeWebDesign" wrote:

> Hello,
>
> Body is preferable. Do you have the site online for us to take a look and
> assist you better?
>
> --
> Singapore Web Design
> http://www.bootstrike.com/Webdesign/
> Singapore Web Hosting
> http://www.bootstrike.com/WinXP/faq.html
> Windows XP FAQ
>
> "Mark E." <(E-Mail Removed)> wrote in message
> news:2ED32544-CB35-4F34-8E47-(E-Mail Removed)...
> > Ok, just tried it on my site and nothing. Would this go in the body of a
> > post/story on a site used to blog or in the index of the main site?
> >
> > Mark
> >
> > "SingaporeWebDesign" wrote:
> >
> >> Hello,
> >>
> >> See
> >> http://www.dynamicdrive.com/dynamicindex9/other1.htm
> >>
> >> --
> >> Singapore Web Design
> >> http://www.bootstrike.com/Webdesign/
> >> Singapore Web Hosting
> >> http://www.bootstrike.com/WinXP/faq.html
> >> Windows XP FAQ
> >>
> >> "Mark E." <(E-Mail Removed)> wrote in message
> >> news:12633897-99D2-4C59-A5DB-(E-Mail Removed)...
> >> > None of those things work. In fact, when I tried them they only moved
> >> > stuff
> >> > around on my site that wasn't supposed to be moved. Is there just a
> >> > simple
> >> > walkthrough for doing this? Is there a specific place to paste this
> >> > code?
> >> > Why can't explanations just be in standard English for this stuff?
> >> >
> >> > Mark
> >> >
> >> > "Tom Willett" wrote:
> >> >
> >> >> Print Button (Courtesy of MVP Murray):
> >> >>
> >> >> Put this in the head of the document -
> >> >>
> >> >> <script type="text/javascript">
> >> >> function print_page(where){
> >> >> var is_mac=(navigator.platform.indexOf("ac") != -1);
> >> >> (document.all && is_mac)?
> >> >> alert("Select \"Print\" from the menu") : where? where.window.print()
> >> >> :
> >> >> window.print();
> >> >> }
> >> >> </script>
> >> >>
> >> >> Put this in the body of the document -
> >> >> <a href="javascriptrint_page()">Print this</a>
> >> >> ---
> >> >> --
> >> >> ===
> >> >> Tom Willett
> >> >> Microsoft MVP - FrontPage
> >> >> ---
> >> >> FrontPage Support:
> >> >> http://www.frontpagemvps.com/
> >> >> ===
> >> >> "Maureen" <(E-Mail Removed)> wrote in message
> >> >> news:BE159F50-76BE-47D0-8DB7-(E-Mail Removed)...
> >> >> | I'm using FrontPage 2002 with our web site hosted on a Windows
> >> >> platform.
> >> >> | --
> >> >> | Maureen
> >> >>
> >> >>
> >> >>
> >>
> >>
> >>

>
>
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Print Page Shortcut =?Utf-8?B?S2xhYXR1?= Microsoft Word Document Management 3 11th Jun 2007 06:36 AM
Print Range - Current Page; Shortcut Key =?Utf-8?B?RGNN?= Microsoft Word Document Management 2 14th Dec 2005 02:55 PM
How do I create a shortcut key to print the current page only? =?Utf-8?B?RWxlY3Ryb25pYy5BbmltYWw=?= Microsoft Word Document Management 2 6th Sep 2005 05:22 PM
Shortcut to print current page? Ken Microsoft Word New Users 2 28th Jun 2005 07:15 PM
Print Current Page Shortcut Magnusfarce Microsoft Word New Users 3 19th Jan 2004 05:43 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:10 PM.