Hello, I'm having a few problems with CSS external style sheets. They seem to simply not work. When I write an internal style sheet in the <style></style> tags everything works fine. However for an external file sheet it's as if the document isn't reading them.
Here's my index.php:
And here's my external style sheet, TEST.css:
Please help. I'll give you rep.
Here's my index.php:
PHP:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Scorpia</title>
<link rel="stylesheet" type="text/css" href="thestyle.css"/>
<style type="text/css">
body
{
background-color:PowderBlue;
}
</style>
<script type="text/javascript">
function show_alert()
{
alert("Why do people always press the button they are told not to push?");
}
</script>
</head>
<body>
<h1 class="a">HELLO WORLD!</h1>
<br />
<ul class="a">
<li class="a">
<a class="a"href="http://www.w3schools.com/html/default.asp">HTML</a></li>
<li class="a"><a class="a"href="http://www.w3schools.com/css/default.asp">CSS</a></li>
<li class="a"><a class="a"href="http://www.w3schools.com/js/default.asp">JavaScript</a></li>
<li class="a"><a class="a"href="http://www.w3schools.com/xml/default.asp">XML</a></li>
</ul>
<input type="button" onclick="show_alert()" value="Do NOT press this button!" />
</body>
</html>
And here's my external style sheet, TEST.css:
Code:
div.a
{
background-color:LightGreen;
outline-style:solid;
outline-color:LightBlue;
outline-width:3px;
}
ul.a
{
list-style-type:none;
margin:0;
padding:0;
overflow:hidden;
}
li.a
{
float:left;
}
a.a:link,a.a:visited
{
display:block;
width:120px;
font-weight:bold;
color:#FFFFF;
background-color:#98bf21;
text-align:center;
padding:4px;
text-decoration:none;
text-transform:uppercase;
}
a.a:hover,a.a:active
{
background-color:#7A991A;
}
h1.a
{
text-align:center;
}
Please help. I'll give you rep.
Last edited: