Plik CSS
#newsglowny {
padding: 5px 20px 5px 20px;
position:relative;
width:500px;
height:300px;
background:#ff0000;
}
#newsglowny em b {
position:absolute;
font-size:150px;
font-family:arial;
color:#ff0000;
line-height:40px;
font-weight:normal;
}
#newsglowny p {
position:relative;
z-index:100;
padding:5px 10px;
}
#ctl, #cbl, #ctr, #cbr {
position:absolute;
width:20px;
height:20px;
color:#9caf9c;
background:#fff;
overflow:hidden;
font-style:normal;
z-index:1;
}
#ctl {
top:0;
left:0;
}
#cbl {
bottom:0;
left:0;
}
#ctr {
top:0;
right:0;
}
#cbr {
bottom:0;
right:0;
}
#ctl b {
left:-8px;
}
#ctr b {
left:-25px;
}
#cbl b {
left:-8px;
top:-17px;
}
#cbr b {
left:-25px;
top:-17px;
}
Dwa pliki
rogi.html:
<link rel="stylesheet" type="text/css" href="rogi.css" />
index.php [Kod po wygenerowaniu: fragment]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2" /> <link rel="stylesheet" type="text/css" href="style.css" /> <link rel="stylesheet" type="text/css" href="rogi.css" /> <link rel="stylesheet" type="text/css" href="menubar.css" title=""/> <script type="text/javascript" language="JavaScript" src="menubar.js"></script> Tu jest menu
<br /><div id='pozostalenewsy'> <h4>Pozostałe newsy
</h4>Dzisiaj jest 2008-01-21
<br /></div> Panel administracyjny serwisu heniek.ovh.org
<br />Wszystkie dane zastrzeżone, kopiowanie bez zgody autora (tj. właściciela) surowo zabronione.
<br />Copyright © by Heniek --> 2008 - 2008-01-21
</div>
</body>
</html>
W pierwszym pliki rogi działają bez zarzutu, zaś w drugim coś jest nie tak.
Kod pliku style.css
body {
background: #fff center top repeat-y;
margin: 0px;
font-family: Tahoma, Verdana, Trebuchet Ms;
font-size: 12px;
color: #000;
}
#naglowek {
background: #dddddd;
height: 180px;
}
#tresc {
background: #fff;
padding: 20px 10px 20px 10px;
}
#stopka {
background: #ff0000;
text-decoration: none;
text-align: center;
padding: 20px 10px 20px 10px;
}
#menu {
height: 25px;
}
#pozostalenewsy {
padding: 5px 5px 5px 5px;
width: 500px;
background: #ff0000;
}
h4 {
text-decoration: underline;
text-align: center;
font-size: 18px;
}