模拟HTML文档中的分页。 [英] Emulate paging in an HTML document.

查看:56
本文介绍了模拟HTML文档中的分页。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想模仿HTML文档中的分页。类似的东西,


-------------------------

| |

| < DIV> |

| |

| <表>< /表> |

| |

| <表>< /表> |

| |

| < / DIV> |

| |

| < DIV PAGEBREAK> |

| |

| < DIV> |

| |

| <表>< /表> |

| |

| <表>< /表> |

| |

| < / DIV> |

| |

| |

| |


DIV(< DIV STYLE =" width:''100%''; position:relative;">)是

相对于身体和桌子定位(< TABLE

STYLE =" width:'''80%''; position:absolute; left:''0PX''; to p:' '0PX'';">)

绝对定位于DIV。


因此,当我打印预览文档时,我得到两张表在每个

页面;但是,在显示器中,应该在第二页页面中的表格与第一页面中的表格重叠。我猜测原因是因为DIVs的高度不包括孩子身高的总和

< TABLE>其中的元素。 (我在DIV周围放了一个

边框并确认了这一点。它只需要一个

字形/ px /等等......)


是否有可能实现我想要的?我不知道...


我非常感谢任何帮助。

问候,

Rithish。

I want to emulate paging in an HTML document. something like,

-------------------------
| |
| <DIV> |
| |
| <TABLE></TABLE> |
| |
| <TABLE></TABLE> |
| |
| </DIV> |
| |
| <DIV PAGEBREAK> |
| |
| <DIV> |
| |
| <TABLE></TABLE> |
| |
| <TABLE></TABLE> |
| |
| </DIV> |
| |
| |
| |

The DIVs( <DIV STYLE="width:''100%'';position:relative;"> ) are
positioned relative to the body, and the TABLEs ( <TABLE
STYLE="width:''80%'';position:absolute;left:''0PX'';to p:''0PX'';"> ) are
positioned absolute to the DIVs.

Thus, when I print preview the document, I get two tables in each
page; however, in the display, the tables that are supposed to be in
the second page page overlap the ones that are in the first page. I
guess the reason is ''cos the DIVs'' height will not consist of the sum
of the height of the child <TABLE> elements that are in it. ( I put a
border around the DIV and confirmed this. It takes only one
glyph/px/whatever.. )

Is it possible to acheive what I want to?? I dont know...

I would greatly appreciate any help.
Regards,
Rithish.

推荐答案

Rithish写道:
Rithish wrote:
是否有可能实现我想要的?我不知道...
Is it possible to acheive what I want to?? I dont know...




难道没有强制分页的CSS东西吗?


-

John MexIT: http://johnbokma.com/mexit/

个人页面: http://johnbokma.com/

经验丰富的Perl程序员可用: http://castleamber.com/



Isn''t there a CSS thing to force page breaks?

--
John MexIT: http://johnbokma.com/mexit/
personal page: http://johnbokma.com/
Experienced Perl programmer available: http://castleamber.com/


2004年5月11日07:32:09 -0700,Rithish< ri ***** @dacafe.com>写道:
On 11 May 2004 07:32:09 -0700, Rithish <ri*****@dacafe.com> wrote:
我想模仿HTML文档中的分页。


对我来说,这有点像在汽车上模仿疼痛,疲惫的腿和脚,但我会打球。

DIV(< DIV STYLE =" width:''100%''; position:relative;">)相对于身体定位,并且TABLE(<表
STYLE =" width:''80%''; position:absolute; left:''0PX'';到p:''0PX'';">)定位
绝对是DIV。

因此,当我打印预览文档时,我在每个
页面中得到两个表格;但是,在显示器中,应该位于第二页页面中的表格与第一页面中的表格重叠。我猜猜原因是因为DIVs的高度不包括孩子身高的总和<< TABLE>其中的元素。 (我在DIV周围放了一个
边框并确认了这个。它只需要一个
字形/ px /无论如何..)
I want to emulate paging in an HTML document.
To me, this is sort of like emulating sore, tired legs and feet in an
automobile, but I''ll play ball.
The DIVs( <DIV STYLE="width:''100%'';position:relative;"> ) are
positioned relative to the body, and the TABLEs ( <TABLE
STYLE="width:''80%'';position:absolute;left:''0PX'';to p:''0PX'';"> ) are
positioned absolute to the DIVs.

Thus, when I print preview the document, I get two tables in each
page; however, in the display, the tables that are supposed to be in
the second page page overlap the ones that are in the first page. I
guess the reason is ''cos the DIVs'' height will not consist of the sum
of the height of the child <TABLE> elements that are in it. ( I put a
border around the DIV and confirmed this. It takes only one
glyph/px/whatever.. )




什么是你的问题是,我不完全确定。您是否已阅读
http:// www .w3.org / TR / CSS2 / page.html#page-breaks ?如果是这样,你的问题是
分页符无法正常工作吗?我不太了解

CSS的这方面,也许有支持问题。


你的div是否包含你想要的表格,或者不?我真的不是很清楚。


请创建一个实例并发布一个URL,这样你所要求的就是

更透明。



What your issue is, I''m not entirely sure. Have you read
http://www.w3.org/TR/CSS2/page.html#page-breaks ? If so, is your issue
that the page break is not working? I don''t know much about this aspect of
CSS, perhaps there are support issues.

Is your div containing the tables as you desire, or not? I''m really not
clear on that.

Please create a live example and post a URL so what you''re asking can be
more lucent.


2004年5月11日星期二,John Bokma写道:
On Tue, 11 May 2004, John Bokma wrote:
Isn''有一个CSS的东西迫使


CSS永远不会强迫任何东西。它只提出建议,

客户代理可以根据需要采取行动。这是一个重要的

原则,而不仅仅是一种形式的文字。

分页?
Isn''t there a CSS thing to force
CSS never "forces" anything. It only makes proposals, which the
client agent can action or not as it sees fit. That''s an important
principle, not just a form of words.
page breaks?




不是那些。



Not those either.


这篇关于模拟HTML文档中的分页。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆