I am creating a one column, fixed width layout. It works fine as long as I put a comment at the top.
http://www.clickbasics.com/test_v3/l...ixed/index.php
However, it does not when there is none such comment or just a blank line.
http://www.clickbasics.com/test_v3/l...no_comment.php
The style sheet script is:
Code:
body {
width: 600px;
padding-left: 50%;
}
#frame {
/* set the width of the column */
/*WinIE value first, then the desired valuethe next 2 times */
width: 600px;
margin-left: -300;
}
The page script without the comment at the top is:
PHP Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"[url="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"]http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd[/url]">
<html xmlns="[url="http://www.w3.org/1999/xhtml"]http://www.w3.org/1999/xhtml[/url]">
<head>
<base href="[url="http://www.clickbasics.com/test_v3/"]http://www.clickbasics.com/test_v3/[/url]" />
<title>One Column Fixed Width - Template</title>
<meta http-equiv="content-Type" content="text/html; charset=iso-8859-1" />
<link rel="stylesheet" type="text/css" media="all" href="css/one_column_fixed.css" title="One Column Fixed Width " />
</head>
<body>
<!-- begin frame div -->
<div id="frame">
<h2>Your Website Name here</h2>
<h3>Your Website Description here</h3> ...
</div>
</body>
</html>
Any clue why the comment at the first line makes this script work OK?
Bookmarks