views:

33

answers:

1

i am getting this error on this code:

<style>
#tt {
 position:absolute;
 display:block;
 background:url(images/tt_left.gif) top left no-repeat;
 }
 #tttop {
 display:block;
 height:5px;
 margin-left:5px;
 background:url(images/tt_top.gif) top right no-repeat;
 overflow:hidden;
 }
 #ttcont {
 display:block;
 padding:2px 12px 3px 7px;
 margin-left:5px;
 background:#666;
 color:#fff;
 }
#ttbot {
display:block;
height:5px;
margin-left:5px;
background:url(images/tt_bottom.gif) top right no-repeat;
overflow:hidden;
}
</style>

<?xml version="1.0" encoding="UTF-8" standalone="no"?>

does anyone know why i am getting this error? where should i be pasting the style?

+1  A: 

The XML declaration…

<?xml version="1.0" encoding="UTF-8" standalone="no"?>

…, if included, must be the very first thing in the document. You have it appearing after a style element.

That said, version 1.0 is the default, UTF-8 is the default, and no is the default. So you can leave it out entirely.

What's more, assuming you are writing XHTML and serving it as text/html, you should leave it out entirely, as per the first of the compatibility guidelines.

where should i be pasting the style?

A style element can only appear in an XHTML 1.0 document as a child element of the head element.

David Dorward
im sorry can you show me exactly what you mean
I__
You would probably be better off reading a good introduction to the subject such as http://wsc.opera.com/ rather then trying to learn very basic stuff from very specific questions.
David Dorward
i appreciate your input, can you clarify what you mean before
I__