By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,493 Members | 1,936 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,493 IT Pros & Developers. It's quick & easy.

about page-break-before

P: n/a
Hi

I'm trying to apply the page-break-before attribute in a <h2> tag like this:
<h2.newpg>Title here</h2>
where:
..newpg { page-break-before:always;}

However,
1. In IE 6.0 while the heading (and the text below it) starts from the top
of the page2, the page1 text (as it isn't too much to cover the whole page)
starts from the middle of the page leaving a big blank space at the top.

2. MozFirebird 0.7 doesn't recognize the style at all and it returns the
whole text without the break.

3. Disappointed from the result I didn't try to test it in Navigator 7.x and
Opera 7 :)

(Tests done in winXP Pro environment)
Am I doing something wrong with the style, or what?

Thanks.

____________________
Merlin dying, to the Lady of the Lake:
"we lived our lives with passion and devotion"

-=- geotso -=-
(remove the TRAP to contact me)
Jul 20 '05 #1
Share this Question
Share on Google+
6 Replies


P: n/a
geotso wrote:
Hi

I'm trying to apply the page-break-before attribute in a <h2> tag like
this:
<h2.newpg>Title here</h2>
Should be <h2 class="newpg">Title here</h2>
where:
.newpg { page-break-before:always;}
Looks fine? Have you specified the media-type somewhere? Make sure it is
on print it is not on all.
(Tests done in winXP Pro environment)
Am I doing something wrong with the style, or what?


Yes

Out of date example that still works:
<http://annevankesteren.nl/test/print/>
--
Anne van Kesteren
<http://www.annevankesteren.nl/>
Jul 20 '05 #2

P: n/a
according "Anne van Kesteren":
geotso wrote:
Hi

I'm trying to apply the page-break-before attribute in a <h2> tag like
this:
<h2.newpg>Title here</h2>

Should be <h2 class="newpg">Title here</h2>

Sorry, my mistake! I corrected it.
where:
.newpg { page-break-before:always;}

Looks fine? Have you specified the media-type somewhere? Make sure it is
on print it is not on all.

the style is in an external stylesheet that I call like this:
<link href="../Styles/print.css" rel="stylesheet" type="text/css" media="print">
(Tests done in winXP Pro environment)
Am I doing something wrong with the style, or what?

Yes

Out of date example that still works:
<http://annevankesteren.nl/test/print/>

I'm going there right now, as the first two suggestions *don't* resolve my
problem :(

--
____________________
Merlin dying, to the Lady of the Lake:
"we lived our lives with passion and devotion"

-=- geotso -=-
(remove the TRAP to contact me)
Jul 20 '05 #3

P: n/a
>> Out of date example that still works:
<http://annevankesteren.nl/test/print/>

I'm going there right now, as the first two suggestions *don't* resolve
my problem :(


Unless the comments of the stylesheets are hidding something vital (I don't
know your language) there is nothing different with my page. I even changed
the style I use for the page-brake from a class to an ID as in your example
and yet the problem is still there. The only (obvious) difference I can see
is that your text is in DIV tags, while mine is in a table's cell.
Could this cause the problem?

Thanks again.
Jul 20 '05 #4

P: n/a
geotso wrote:
Unless the comments of the stylesheets are hidding something vital (I don't
know your language)
It's Dutch. Once I have time I will translate that test into English and
make it better.
there is nothing different with my page. I even changed
the style I use for the page-brake from a class to an ID as in your example
and yet the problem is still there. The only (obvious) difference I can see
is that your text is in DIV tags, while mine is in a table's cell.
Could this cause the problem?


Yes, certainly. You know that tables are not supposed to be used for layout?

--
Anne van Kesteren
<http://www.annevankesteren.nl/>
Jul 20 '05 #5

P: n/a
according "Anne van Kesteren":
geotso wrote:
Unless the comments of the stylesheets are hidding something vital (I
don't
know your language)

It's Dutch. Once I have time I will translate that test into English and
make it better.
> there is nothing different with my page. I even changed

the style I use for the page-brake from a class to an ID as in your
example
and yet the problem is still there. The only (obvious) difference I
can see
is that your text is in DIV tags, while mine is in a table's cell.
Could this cause the problem?

Yes, certainly. You know that tables are not supposed to be used for
layout?

just fancy!
I didn't even think of it...
Well, I'll try to re-design the page.

Thanks.

--
____________________
Merlin dying, to the Lady of the Lake:
"we lived our lives with passion and devotion"

-=- geotso -=-
(remove the TRAP to contact me)
Jul 20 '05 #6

P: n/a
Hi!

When I want to print a long table, which dosen't fit on one
page IE adds one empty row on the end on each page.
This empty row is visible due to I need to have borders around
each <td> element. See examples:

http://ceti.pl/~kubik/template/example.html - a long table which I want
print

http://ceti.pl/~kubik/template/example.gif - printed table with visible
empty row
on the bottom
I tried with page-break styles but nothing works correctly...

Can anyone help me? I need to solve this problem, which occurs only
in MSIE. Other browsers print it fine.

Thomas
Jul 20 '05 #7

This discussion thread is closed

Replies have been disabled for this discussion.