thientanchuong
06-22-2010, 12:24 PM
I use css to code my web layout and I also can view all images on Dreamweaver.
http://img684.imageshack.us/img684/8162/html1.jpg
However, when I view my web layout on Browsers( Firefox, IE), nothing appears.
http://img266.imageshack.us/img266/6919/html2.jpg
My code for HTML is:
<html>
<head>
<title>Hung</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" type="text/css" href="/template/style.css">
</head>
<body>
<div id="container">
<div id="header"></div>
<div id="menu"></div>
<div id="whitebody">
</div>
<div id="footer"></div>
</div>
</body>
</html>
And MY CSS CODE is:
body{
color:#FFF;
margin: 0px;
padding:0px;
}
#container{
background-position:center;
}
#header{
background:url(/template/images/header.gif);
background-repeat: no-repeat;
width: 800px;
height: 80px;
}
#menu{
background-image:url(/template/images/menu.gif);
background-repeat:no-repeat;
width: 800px;
height: 55px;
}
#whitebody{
background-image:url(/template/images/backgroundbdoy.gif);
background-repeat:no-repeat;
width: 800px;
height: 441px;
}
#footer{
background-image:url(/template/images/footer.gif);
background-repeat:no-repeat;
width: 800px;
height: 24px;
}
If the paths of images are wrong, I can not view on Dreamweaver but I can.
What wrong have I done ? please let me know and possibly give me a solution as you can.
Thank you very much.
http://img684.imageshack.us/img684/8162/html1.jpg
However, when I view my web layout on Browsers( Firefox, IE), nothing appears.
http://img266.imageshack.us/img266/6919/html2.jpg
My code for HTML is:
<html>
<head>
<title>Hung</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" type="text/css" href="/template/style.css">
</head>
<body>
<div id="container">
<div id="header"></div>
<div id="menu"></div>
<div id="whitebody">
</div>
<div id="footer"></div>
</div>
</body>
</html>
And MY CSS CODE is:
body{
color:#FFF;
margin: 0px;
padding:0px;
}
#container{
background-position:center;
}
#header{
background:url(/template/images/header.gif);
background-repeat: no-repeat;
width: 800px;
height: 80px;
}
#menu{
background-image:url(/template/images/menu.gif);
background-repeat:no-repeat;
width: 800px;
height: 55px;
}
#whitebody{
background-image:url(/template/images/backgroundbdoy.gif);
background-repeat:no-repeat;
width: 800px;
height: 441px;
}
#footer{
background-image:url(/template/images/footer.gif);
background-repeat:no-repeat;
width: 800px;
height: 24px;
}
If the paths of images are wrong, I can not view on Dreamweaver but I can.
What wrong have I done ? please let me know and possibly give me a solution as you can.
Thank you very much.