
July 20th, 2004, 10:23 AM
|
|
Registered User
|
|
Join Date: Jun 2004
Location: Bristol UK
Posts: 29
Time spent in forums: 4 h 34 m 48 sec
Reputation Power: 0
|
|
|
Minus margins and printing crashes
Anyone come across this...?
Put a minus margin as part of a class and it'll display & print OK in IE. Displays fine in Firefox but craches the browser when you try to print.
I tried to isolate the code with the minus margins but it works fine on its own (see below). So it appears to be conflicting with something else on a more complex page. Sound familiar to anyone?
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style>
body {
font-family: Georgia, "Times New Roman", Times, serif;
font-size: small;
color: #666666;
}
p{
margin:0px;
padding: 0px 0px 0.7em 0px;
}
.play {
position:relative;
font-family: Georgia, "Times New Roman", Times, serif;
font-size: x-small;
color: #666666;
margin-left: 0px;
padding-left:75px;
}
.character {
position:relative;
font-family: Georgia, "Times New Roman", Times, serif;
font-weight:bold;
font-size: xx-small;
color: #666666;
width:70px;
float:left;
margin-left:-75px;
}
</style>
</head>
<body>
<div class="play">
<p><span class="character">Char1</span> Some line in a play.</p>
<p><span class="character">Char2</span> Some other line in a play.</p>
<p>That carries on for a bit.</p>
<p><span class="character">Char1</span> The first person again.</p>
</div>
</body>
</html>
|