CSS @page rules

PHPz
Release: 2023-08-30 09:05:23
forward
1509 people have browsed it

CSS @page规则

You can specify the size, direction, margins, etc. of the page box in the @page rule. The dimensions of the page box are set by the 'size' attribute. The size of the page area is the size of the page box minus the margin area.

For example, the following @page rule sets the page box dimensions to 8.5×11 inches and creates a margin of '2cm' on all sides between the page box edge and the page area:

<style>
   <!--
      @page { size:8.5in 11in; margin: 2cm }
   -->
</style>
Copy after login

The above is the detailed content of CSS @page rules. For more information, please follow other related articles on the PHP Chinese website!

source:tutorialspoint.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!