471,599 Members | 931 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,599 software developers and data experts.

orphans / widows

m
Hello,

I have been trying to use orphan and widow control to prevent page
breaks immediately after h1 elements (on a CV). I have validated the
css and html, and used the following hoping this would work:

h1 {
orphans: 4;
widows: 1;
}

Because it's a resume, all the h1 elements are one line only, so I
assumed this would prevent any h1's from appearing as the last thing
on a page, with nothing following it below.

I was hoping this would work in Opera so I could print from that
browser, because it supposedly supports this feature. But it doesn't
seem to work. When I try to print from Opera, there is an h1 on the
third page that is at the very bottom, with nothing beneath it

The page is here: http://www.mdessen.com/mdcv.html

If anyone were to take the time to figure out what is wrong here, I
offer many kind thanks in advance.

michael dessen

Aug 24 '07 #1
3 2785
m
I just re-read the page-break specs and now see what you mean. THANK
YOU for the help!

michael dessen

Aug 24 '07 #2
Scripsit m@mdessen.com:
I just re-read the page-break specs and now see what you mean.
Unfortunately, that's not the end of the story.

Although page-break-after: always and page-break-before: before are
well-supported, the same does not apply to settings that _prevent_ page
breaks or, to put it better, suggest that a page break should _not_ occur.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

Aug 24 '07 #3
in comp.infosystems.www.authoring.stylesheets, Jukka K. Korpela wrote:
Scripsit m@mdessen.com:
I just re-read the page-break specs and now see what you mean.

Unfortunately, that's not the end of the story.

Although page-break-after: always and page-break-before: before are
well-supported, the same does not apply to settings that _prevent_ page
breaks or, to put it better, suggest that a page break should _not_ occur.
Actually, page-break-before: avoid is often more likely cause page-break
than prevent it on some browser I tested about 2-3 years ago.

--
Lauri Raittila <http://www.iki.fi/lr>
Aug 24 '07 #4

This discussion thread is closed

Replies have been disabled for this discussion.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.