Problem with printer friendly support

G

George

I wish to implement a printer friendly output and
attempted two approaches:
1. Using CSS with "<link rel="stylesheet"
type="text/css" media="print" href="print.css" />" in the
head section and a print.css file in the same dir.
2. Having "<LINK REL=alternate MEDIA=print
HREF="test.htm">" in the head section and test.htm
(containing print preferable output).

However, neither approach works, the printer output is
equal to no code at all. I am using FrontPage and the
site has shared borders. My issue is that I want to
eliminate the shared border for printing. I'll appreciate
any advice/help.
 
M

Murray

The former approach would be the right one to use, but its effectiveness
would depend on the contents of the stylesheet and the HTML on the page.
Can you show me?
 
G

George

I read about everything on this subject. Regardless what
I code in "print.css" (changing font, color, etc) it has
no impact to the output at the printer; I want to drop
the "Microsoft Border" for print. I tested in IE6 and
Mozilla5. Below is the head section of the test page and a
sample css. Why is this happening?

<head>
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<link rel="stylesheet" type="text/css" media="print"
href="print.css" />
<title>July 2004</title>
<meta name="Microsoft Theme" content="gk-copy-of-capsules
011, default">
<meta name="Microsoft Border" content="tlb">
</head>
_____________________________________
body {
color : #000000;
background : #ffffff;
font-family : "Times New Roman", Times, serif;
font-size : 12pt;
}
a { text-decoration : underline;
background : #ffffff;
color : #0000ff;
}
#navigation, #menu, #top, #"Microsoft Border" {
display : none;
}
 
G

George

I read about everything on this subject. Regardless what
I code in "print.css" (changing font, color, etc) it has
no impact to the output at the printer; I want to drop
the "Microsoft Border" for print. I tested in IE6 and
Mozilla5. Below is the head section of the test page and a
sample css. Why is this happening?

<head>
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<link rel="stylesheet" type="text/css" media="print"
href="print.css" />
<title>July 2004</title>
<meta name="Microsoft Theme" content="gk-copy-of-capsules
011, default">
<meta name="Microsoft Border" content="tlb">
</head>
_____________________________________
body {
color : #000000;
background : #ffffff;
font-family : "Times New Roman", Times, serif;
font-size : 12pt;
}
a { text-decoration : underline;
background : #ffffff;
color : #0000ff;
}
#navigation, #menu, #top, #"Microsoft Border" {
display : none;
}
 
C

Chris Leeds, MVP-FrontPage

ok, well, even though you may add the stuff for print to the style sheet
doesn't necessarily mean that it'll work.

you've got to use and @ rule in your page's head section to let the browser
know which style sheet for print, and you've got to class or ID the parts of
your page you don't want to print (in the page itself).

feel free to look at my pages http://nedp.net and hit file/ print preview
you'll see them differently formatted.

you can also do view/ source on them to see how the style sheets are being
called, and find links to the sheets themselves.

It will work if configured properly.

HTH

--
Chris Leeds,
Microsoft MVP-FrontPage

Please feel free to contact me here:
http://nedp.net/contact/
--
 
M

Murray

Make sure your link to the print stylesheet is the lowest one on the page,
e.g.,

<link rel="stylesheet" src="print.css" type="text/css" media="print">
</head>
 
G

George

Chris,
The moving of the link to the bottom of "head" doesn't
work since FrontPage seems to rearrange the code
regardless what I try to do (Murray's suggestion); Meta
names "Theme and Border" are always moved to the bottom!
Regarding your suggestion: How do I "class or ID" code
that isn't in the page? Shared borders are defined in
meta names="Microsoft Border", they are dynamically loaded
and as far as I can judge not in the code of the page I
wish to print.
 
M

Murray

Chris:

This is true if you have multiple stylesheets with no media assignment or
with "all" as a media assignment. If you have

<link media="screen"

and

<link media="print"

then it doesn't matter what the sequence is.
 
M

Murray

George:

Hmmm - that sounds funny. Try giving your other stylesheet link a media of
"screen", e.g.,

<link media="screen"....
 
S

Stefan B Rusynko

Themes and shared border are always last
- so the theme cascades and is applied overruling all other styles




| Chris,
| The moving of the link to the bottom of "head" doesn't
| work since FrontPage seems to rearrange the code
| regardless what I try to do (Murray's suggestion); Meta
| names "Theme and Border" are always moved to the bottom!
| Regarding your suggestion: How do I "class or ID" code
| that isn't in the page? Shared borders are defined in
| meta names="Microsoft Border", they are dynamically loaded
| and as far as I can judge not in the code of the page I
| wish to print.
|
| >-----Original Message-----
| >ok, well, even though you may add the stuff for print to
| the style sheet
| >doesn't necessarily mean that it'll work.
| >
| >you've got to use and @ rule in your page's head section
| to let the browser
| >know which style sheet for print, and you've got to class
| or ID the parts of
| >your page you don't want to print (in the page itself).
| >
| >feel free to look at my pages http://nedp.net and hit
| file/ print preview
| >you'll see them differently formatted.
| >
| >you can also do view/ source on them to see how the style
| sheets are being
| >called, and find links to the sheets themselves.
| >
| >It will work if configured properly.
| >
| >HTH
| >
| >--
| >Chris Leeds,
| >Microsoft MVP-FrontPage
| >
| >Please feel free to contact me here:
| >http://nedp.net/contact/
| >--
| message
| >| >> I read about everything on this subject. Regardless
| what
| >> I code in "print.css" (changing font, color, etc) it has
| >> no impact to the output at the printer; I want to drop
| >> the "Microsoft Border" for print. I tested in IE6 and
| >> Mozilla5. Below is the head section of the test page
| and a
| >> sample css. Why is this happening?
| >>
| >> <head>
| >> <meta name="GENERATOR" content="Microsoft FrontPage
| 5.0">
| >> <meta name="ProgId" content="FrontPage.Editor.Document">
| >> <link rel="stylesheet" type="text/css" media="print"
| >> href="print.css" />
| >> <title>July 2004</title>
| >> <meta name="Microsoft Theme" content="gk-copy-of-
| capsules
| >> 011, default">
| >> <meta name="Microsoft Border" content="tlb">
| >> </head>
| >> _____________________________________
| >> body {
| >> color : #000000;
| >> background : #ffffff;
| >> font-family : "Times New Roman", Times, serif;
| >> font-size : 12pt;
| >> }
| >> a { text-decoration : underline;
| >> background : #ffffff;
| >> color : #0000ff;
| >> }
| >> #navigation, #menu, #top, #"Microsoft Border" {
| >> display : none;
| >> }
| >>
| >> >-----Original Message-----
| >> >I've found the @rules work best. here's an article you
| >> should read:
| >> >http://www.alistapart.com/articles/goingtoprint/
| >> >
| >> >also search that site for more print function articles.
| >> >
| >> >HTH
| >> >
| >> >--
| >> >
| >> >--
| >> >Chris Leeds,
| >> >Microsoft MVP-FrontPage
| >> >
| >> >Please feel free to contact me here:
| >> >http://nedp.net/contact/
| >> >--
| >> message
| >> >| >> >> I wish to implement a printer friendly output and
| >> >> attempted two approaches:
| >> >> 1. Using CSS with "<link rel="stylesheet"
| >> >> type="text/css" media="print" href="print.css" />" in
| >> the
| >> >> head section and a print.css file in the same dir.
| >> >> 2. Having "<LINK REL=alternate MEDIA=print
| >> >> HREF="test.htm">" in the head section and test.htm
| >> >> (containing print preferable output).
| >> >>
| >> >> However, neither approach works, the printer output
| is
| >> >> equal to no code at all. I am using FrontPage and
| the
| >> >> site has shared borders. My issue is that I want to
| >> >> eliminate the shared border for printing. I'll
| >> appreciate
| >> >> any advice/help.
| >> >>
| >> >>
| >> >>
| >> >>
| >> >
| >> >
| >> >.
| >> >
| >
| >
| >.
| >
 
C

Chris Leeds, MVP-FrontPage

Thanks for the follow up.
I'm always interested in doing stuff with style sheets.
I've developed some (I think) cool tricks, such as using an @ rule to call
the style sheet (and hide from old browsers) and simultaneously add a
..warning class to a message at the page bottom about "you're seeing this
page unformatted due to poor browser support.....", so if the style sheet
gets loaded my warning is display: none; but visible without the style sheet
loading.

I was also working yesterday on not just reformatting a page for print but
using the media=print to actually display different headers and footers than
screen media.

I really wish that I'd gotten into this stuff when I first got into web
design. I remember reading Jim Buyen's book where he eluded to the
importance and future use of a style sheet, but I didn't give it the
attention I should have, steering instead towards modifying and making
FrontPage templates and themes.

oh well, live and learn. ;-)

I'd highly recommend any new developer put .css at the top of their list of
stuff to learn. The best book I've ever read on the subject (and refer to
embarrassingly often) is HTML Utopia from www.sitepoint.com although I'm not
completely sold on table-less design, it's a very good book and the
techniques can be applied to classed and id'd tables, cells, and rows. ;-)

--
Chris Leeds,
Microsoft MVP-FrontPage

Please feel free to contact me here:
http://nedp.net/contact/
--
 
M

Murray

Chris:
I was also working yesterday on not just reformatting a page for print but
using the media=print to actually display different headers and footers
than
screen media.

This works very well.
I'd highly recommend any new developer put .css at the top of their list
of
stuff to learn.

I would agree. But a sound foundation in HTML layout methods is essential.
I usually recommend to use CSS for text styling while learning how to build
stable tables. Once that point is reached, it's time to move to CSS
advanced topics. Building good tables is still one of the most important
techniques in your toolbox, in my opinion, with or without CSS.
 
G

George

That's my experience. Whatever I tried, the save
operation of FP changed it. I have the impression that
stylesheets for print media cannot handle the suppression
of shared borders. Anyone disagreeing let me know how to
handle this!
 
M

Murray

That's a drag....

--
Murray

George said:
That's my experience. Whatever I tried, the save
operation of FP changed it. I have the impression that
stylesheets for print media cannot handle the suppression
of shared borders. Anyone disagreeing let me know how to
handle this!
 
S

Stefan B Rusynko

Instead of adding a new style sheet, customize the theme to add your other styles




| That's a drag....
|
| --
| Murray
|
| | > That's my experience. Whatever I tried, the save
| > operation of FP changed it. I have the impression that
| > stylesheets for print media cannot handle the suppression
| > of shared borders. Anyone disagreeing let me know how to
| > handle this!
| >>-----Original Message-----
| >>So you are saying that you cannot manually move the print
| > media stylesheet
| >>below this?
| >>
| >>--
| >>Murray
| >>
| > message
| >>| >>> Themes and shared border are always last
| >>> - so the theme cascades and is applied overruling all
| > other styles
| >>>
| >>> --
| >>>
| >>> _____________________________________________
| >>> SBR @ ENJOY (-: [ Microsoft MVP -
| > FrontPage ]
| >>> "Warning - Using the F1 Key will not break anything!"
| > (-;
| >>> To find the best Newsgroup for FrontPage support see:
| >>> http://www.net-sites.com/sitebuilder/newsgroups.asp
| >>> _____________________________________________
| >>>
| >>>
| > message
| >>> | >>> | Chris,
| >>> | The moving of the link to the bottom of "head" doesn't
| >>> | work since FrontPage seems to rearrange the code
| >>> | regardless what I try to do (Murray's suggestion);
| > Meta
| >>> | names "Theme and Border" are always moved to the
| > bottom!
| >>> | Regarding your suggestion: How do I "class or ID" code
| >>> | that isn't in the page? Shared borders are defined in
| >>> | meta names="Microsoft Border", they are dynamically
| > loaded
| >>> | and as far as I can judge not in the code of the page
| > I
| >>> | wish to print.
| >>> |
| >>> | >-----Original Message-----
| >>> | >ok, well, even though you may add the stuff for
| > print to
| >>> | the style sheet
| >>> | >doesn't necessarily mean that it'll work.
| >>> | >
| >>> | >you've got to use and @ rule in your page's head
| > section
| >>> | to let the browser
| >>> | >know which style sheet for print, and you've got to
| > class
| >>> | or ID the parts of
| >>> | >your page you don't want to print (in the page
| > itself).
| >>> | >
| >>> | >feel free to look at my pages http://nedp.net and hit
| >>> | file/ print preview
| >>> | >you'll see them differently formatted.
| >>> | >
| >>> | >you can also do view/ source on them to see how the
| > style
| >>> | sheets are being
| >>> | >called, and find links to the sheets themselves.
| >>> | >
| >>> | >It will work if configured properly.
| >>> | >
| >>> | >HTH
| >>> | >
| >>> | >--
| >>> | >Chris Leeds,
| >>> | >Microsoft MVP-FrontPage
| >>> | >
| >>> | >Please feel free to contact me here:
| >>> | >http://nedp.net/contact/
| >>> | >--
| > in
| >>> | message
| >>> | >| >>> | >> I read about everything on this subject.
| > Regardless
| >>> | what
| >>> | >> I code in "print.css" (changing font, color, etc)
| > it has
| >>> | >> no impact to the output at the printer; I want to
| > drop
| >>> | >> the "Microsoft Border" for print. I tested in IE6
| > and
| >>> | >> Mozilla5. Below is the head section of the test
| > page
| >>> | and a
| >>> | >> sample css. Why is this happening?
| >>> | >>
| >>> | >> <head>
| >>> | >> <meta name="GENERATOR" content="Microsoft FrontPage
| >>> | 5.0">
| >>> | >> <meta name="ProgId"
| > content="FrontPage.Editor.Document">
| >>> | >> <link rel="stylesheet" type="text/css"
| > media="print"
| >>> | >> href="print.css" />
| >>> | >> <title>July 2004</title>
| >>> | >> <meta name="Microsoft Theme" content="gk-copy-of-
| >>> | capsules
| >>> | >> 011, default">
| >>> | >> <meta name="Microsoft Border" content="tlb">
| >>> | >> </head>
| >>> | >> _____________________________________
| >>> | >> body {
| >>> | >> color : #000000;
| >>> | >> background : #ffffff;
| >>> | >> font-family : "Times New Roman", Times, serif;
| >>> | >> font-size : 12pt;
| >>> | >> }
| >>> | >> a { text-decoration : underline;
| >>> | >> background : #ffffff;
| >>> | >> color : #0000ff;
| >>> | >> }
| >>> | >> #navigation, #menu, #top, #"Microsoft Border" {
| >>> | >> display : none;
| >>> | >> }
| >>> | >>
| >>> | >> >-----Original Message-----
| >>> | >> >I've found the @rules work best. here's an
| > article you
| >>> | >> should read:
| >>> | >> >http://www.alistapart.com/articles/goingtoprint/
| >>> | >> >
| >>> | >> >also search that site for more print function
| > articles.
| >>> | >> >
| >>> | >> >HTH
| >>> | >> >
| >>> | >> >--
| >>> | >> >
| >>> | >> >--
| >>> | >> >Chris Leeds,
| >>> | >> >Microsoft MVP-FrontPage
| >>> | >> >
| >>> | >> >Please feel free to contact me here:
| >>> | >> >http://nedp.net/contact/
| >>> | >> >--
| >>> | >> >"George" <[email protected]>
| > wrote in
| >>> | >> message
| >>> | >> >| >>> | >> >> I wish to implement a printer friendly output
| > and
| >>> | >> >> attempted two approaches:
| >>> | >> >> 1. Using CSS with "<link rel="stylesheet"
| >>> | >> >> type="text/css" media="print"
| > href="print.css" />" in
| >>> | >> the
| >>> | >> >> head section and a print.css file in the same
| > dir.
| >>> | >> >> 2. Having "<LINK REL=alternate MEDIA=print
| >>> | >> >> HREF="test.htm">" in the head section and
| > test.htm
| >>> | >> >> (containing print preferable output).
| >>> | >> >>
| >>> | >> >> However, neither approach works, the printer
| > output
| >>> | is
| >>> | >> >> equal to no code at all. I am using FrontPage
| > and
| >>> | the
| >>> | >> >> site has shared borders. My issue is that I
| > want to
| >>> | >> >> eliminate the shared border for printing. I'll
| >>> | >> appreciate
| >>> | >> >> any advice/help.
| >>> | >> >>
| >>> | >> >>
| >>> | >> >>
| >>> | >> >>
| >>> | >> >
| >>> | >> >
| >>> | >> >.
| >>> | >> >
| >>> | >
| >>> | >
| >>> | >.
| >>> | >
| >>>
| >>>
| >>
| >>
| >>.
| >>
|
|
 
M

Murray

That's a good idea. You can customize to the extent that it inserts a link
to a print media stylesheet?

--
Murray

Stefan B Rusynko said:
Instead of adding a new style sheet, customize the theme to add your other
styles




| That's a drag....
|
| --
| Murray
|
| | > That's my experience. Whatever I tried, the save
| > operation of FP changed it. I have the impression that
| > stylesheets for print media cannot handle the suppression
| > of shared borders. Anyone disagreeing let me know how to
| > handle this!
| >>-----Original Message-----
| >>So you are saying that you cannot manually move the print
| > media stylesheet
| >>below this?
| >>
| >>--
| >>Murray
| >>
| > message
| >>| >>> Themes and shared border are always last
| >>> - so the theme cascades and is applied overruling all
| > other styles
| >>>
| >>> --
| >>>
| >>> _____________________________________________
| >>> SBR @ ENJOY (-: [ Microsoft MVP -
| > FrontPage ]
| >>> "Warning - Using the F1 Key will not break anything!"
| > (-;
| >>> To find the best Newsgroup for FrontPage support see:
| >>> http://www.net-sites.com/sitebuilder/newsgroups.asp
| >>> _____________________________________________
| >>>
| >>>
| > message
| >>> | >>> | Chris,
| >>> | The moving of the link to the bottom of "head" doesn't
| >>> | work since FrontPage seems to rearrange the code
| >>> | regardless what I try to do (Murray's suggestion);
| > Meta
| >>> | names "Theme and Border" are always moved to the
| > bottom!
| >>> | Regarding your suggestion: How do I "class or ID" code
| >>> | that isn't in the page? Shared borders are defined in
| >>> | meta names="Microsoft Border", they are dynamically
| > loaded
| >>> | and as far as I can judge not in the code of the page
| > I
| >>> | wish to print.
| >>> |
| >>> | >-----Original Message-----
| >>> | >ok, well, even though you may add the stuff for
| > print to
| >>> | the style sheet
| >>> | >doesn't necessarily mean that it'll work.
| >>> | >
| >>> | >you've got to use and @ rule in your page's head
| > section
| >>> | to let the browser
| >>> | >know which style sheet for print, and you've got to
| > class
| >>> | or ID the parts of
| >>> | >your page you don't want to print (in the page
| > itself).
| >>> | >
| >>> | >feel free to look at my pages http://nedp.net and hit
| >>> | file/ print preview
| >>> | >you'll see them differently formatted.
| >>> | >
| >>> | >you can also do view/ source on them to see how the
| > style
| >>> | sheets are being
| >>> | >called, and find links to the sheets themselves.
| >>> | >
| >>> | >It will work if configured properly.
| >>> | >
| >>> | >HTH
| >>> | >
| >>> | >--
| >>> | >Chris Leeds,
| >>> | >Microsoft MVP-FrontPage
| >>> | >
| >>> | >Please feel free to contact me here:
| >>> | >http://nedp.net/contact/
| >>> | >--
| > in
| >>> | message
| >>> | >| >>> | >> I read about everything on this subject.
| > Regardless
| >>> | what
| >>> | >> I code in "print.css" (changing font, color, etc)
| > it has
| >>> | >> no impact to the output at the printer; I want to
| > drop
| >>> | >> the "Microsoft Border" for print. I tested in IE6
| > and
| >>> | >> Mozilla5. Below is the head section of the test
| > page
| >>> | and a
| >>> | >> sample css. Why is this happening?
| >>> | >>
| >>> | >> <head>
| >>> | >> <meta name="GENERATOR" content="Microsoft FrontPage
| >>> | 5.0">
| >>> | >> <meta name="ProgId"
| > content="FrontPage.Editor.Document">
| >>> | >> <link rel="stylesheet" type="text/css"
| > media="print"
| >>> | >> href="print.css" />
| >>> | >> <title>July 2004</title>
| >>> | >> <meta name="Microsoft Theme" content="gk-copy-of-
| >>> | capsules
| >>> | >> 011, default">
| >>> | >> <meta name="Microsoft Border" content="tlb">
| >>> | >> </head>
| >>> | >> _____________________________________
| >>> | >> body {
| >>> | >> color : #000000;
| >>> | >> background : #ffffff;
| >>> | >> font-family : "Times New Roman", Times, serif;
| >>> | >> font-size : 12pt;
| >>> | >> }
| >>> | >> a { text-decoration : underline;
| >>> | >> background : #ffffff;
| >>> | >> color : #0000ff;
| >>> | >> }
| >>> | >> #navigation, #menu, #top, #"Microsoft Border" {
| >>> | >> display : none;
| >>> | >> }
| >>> | >>
| >>> | >> >-----Original Message-----
| >>> | >> >I've found the @rules work best. here's an
| > article you
| >>> | >> should read:
| >>> | >> >http://www.alistapart.com/articles/goingtoprint/
| >>> | >> >
| >>> | >> >also search that site for more print function
| > articles.
| >>> | >> >
| >>> | >> >HTH
| >>> | >> >
| >>> | >> >--
| >>> | >> >
| >>> | >> >--
| >>> | >> >Chris Leeds,
| >>> | >> >Microsoft MVP-FrontPage
| >>> | >> >
| >>> | >> >Please feel free to contact me here:
| >>> | >> >http://nedp.net/contact/
| >>> | >> >--
| >>> | >> >"George" <[email protected]>
| > wrote in
| >>> | >> message
| >>> | >> >| >>> | >> >> I wish to implement a printer friendly output
| > and
| >>> | >> >> attempted two approaches:
| >>> | >> >> 1. Using CSS with "<link rel="stylesheet"
| >>> | >> >> type="text/css" media="print"
| > href="print.css" />" in
| >>> | >> the
| >>> | >> >> head section and a print.css file in the same
| > dir.
| >>> | >> >> 2. Having "<LINK REL=alternate MEDIA=print
| >>> | >> >> HREF="test.htm">" in the head section and
| > test.htm
| >>> | >> >> (containing print preferable output).
| >>> | >> >>
| >>> | >> >> However, neither approach works, the printer
| > output
| >>> | is
| >>> | >> >> equal to no code at all. I am using FrontPage
| > and
| >>> | the
| >>> | >> >> site has shared borders. My issue is that I
| > want to
| >>> | >> >> eliminate the shared border for printing. I'll
| >>> | >> appreciate
| >>> | >> >> any advice/help.
| >>> | >> >>
| >>> | >> >>
| >>> | >> >>
| >>> | >> >>
| >>> | >> >
| >>> | >> >
| >>> | >> >.
| >>> | >> >
| >>> | >
| >>> | >
| >>> | >.
| >>> | >
| >>>
| >>>
| >>
| >>
| >>.
| >>
|
|
 
C

Chris Leeds, MVP-FrontPage

Total agreement.

As a matter of fact, whenever I have a vexing problem with the .css, it's
usually an underlying HTML problem that causing or exacerbating it.

--
Chris Leeds,
Microsoft MVP-FrontPage

Please feel free to contact me here:
http://nedp.net/contact/
--
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top