Skip to content

Instantly share code, notes, and snippets.

@cfobel
Last active August 3, 2020 02:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cfobel/271784bda8987a2093d07a5e1dd2d6e0 to your computer and use it in GitHub Desktop.
Save cfobel/271784bda8987a2093d07a5e1dd2d6e0 to your computer and use it in GitHub Desktop.
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Display the source blob
Display the rendered blob
Raw
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
<style>
body { margin: 1em 2em }
h1 { text-decoration : underline }
div { border: 10px solid; background: #ddd }
@page { margin: 2.5cm; }
header {
position: fixed;
top: -2.5cm;
left: -2.5cm;
height: 2cm;
width: 8.5in;
background-color: #4d4d4d;
color: white;
}
footer {
position: fixed;
bottom: -2.5cm;
left: -2.5cm;
height: 2cm;
width: 8.5in;
padding: 0;
}
footer div {
display: table-cell;
width: 8.5in;
height: 2cm;
border: 0;
vertical-align: bottom;
background-color: #265dab;
color: white;
}
span.footer {
display: inline-block;
vertical-align: bottom;
line-height: normal;
}
</style>
<header>Header here</header>
<footer><div><span class="footer">Footer here</span></div></footer>
<h1>Weasyprint testing</h1>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
<div><ul><li>Hello, world!</li></ul></div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment