Note that there are some explanatory texts on larger screens.

plurals
  1. POprint page margins doesnt work in chrome and ie
    text
    copied!<p>I want to set margin-top and bottom to my print page for writing header and footer. </p> <p>I did it in firefox. But it doesnt work in chrome and internet explorer. </p> <p>When i used <code>@page</code> code it works in chrome. But I cant write header on the top and footer on the bottom. How can i solve this problem ?</p> <p>Here is my code</p> <p>pagination.php</p> <pre><code>&lt;!DOCTYPE HTL&gt; &lt;html&gt; &lt;head&gt; &lt;meta http-equiv="Content-Type" content="text/html; charset=iso-8859-9"&gt; &lt;meta name="robots" content="noindex, nofollow"&gt; &lt;meta name="googlebot" content="noindex"&gt; &lt;meta http-equiv="cache-control" content="no-cache"&gt; &lt;title&gt;Brove.NET ISO Yazılımı&lt;/title&gt; &lt;link rel="stylesheet" type="text/css" href="css/pagination.css" /&gt; &lt;/head&gt; &lt;body&gt; &lt;table class="header" cellpadding="0" cellspacing="0"&gt; &lt;tr&gt; &lt;td&gt;header &lt;/td&gt; &lt;/tr&gt; &lt;/table&gt; &lt;table class="content" cellpadding="0" cellspacing="0"&gt; &lt;tr&gt; &lt;td valign="top"&gt; content &lt;/td&gt; &lt;/tr&gt; &lt;/table&gt; &lt;table class="footer" cellpadding="0" cellspacing="0"&gt; &lt;tr&gt; &lt;td&gt;footer &lt;/td&gt; &lt;/tr&gt; &lt;/table&gt; &lt;/body&gt; &lt;/html&gt; </code></pre> <p>pagination.css</p> <pre><code>@media screen{ .header{ width:768px; height:100px; border:2px solid #000; } .content{ width:768px; margin-top:10px; margin-bottom:10px; height:1000px; } .footer{ width:768px; height:100px; border:2px solid #000; } } @media print{ .header{ position:fixed; top:0; left:0; width:768px; height:100px; border:2px solid #000; } .content{ width:768px; margin-top:120px; margin-bottom:120px; height:1000px; } .footer{ position:fixed; left:0; bottom:0; width:768px; height:100px; border:2px solid #000; } @page{ margin-bottom:150px; } } </code></pre> <p>IE screenshot:</p> <p><img src="https://i.stack.imgur.com/6uAm7.png" alt="enter image description here"></p> <p>Firefox screenshot:</p> <p><img src="https://i.stack.imgur.com/MRBbg.png" alt="enter image description here"></p> <p>Chrome screenshot:</p> <p><img src="https://i.stack.imgur.com/5oh4P.png" alt="enter image description here"></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload