TWO PART QUESTION:
1)How would you go about specifying a specific width for an element in the CSS of an XHTML (strict) document?
Ex:
.something {
width: 75px;
}
This displays correct in regular old HTML (transitional)
but change the DTD to XHTML (strict or transitional) and no width is given and in this case all the words run together.
I have provided two test case examples:
HTML- <!-- m --><a class="postlink" href="http://www.32fish.com/test/case1.html">http://www.32fish.com/test/case1.html</a><!-- m -->
XHTML - <!-- m --><a class="postlink" href="http://www.32fish.com/test/case2.html">http://www.32fish.com/test/case2.html</a><!-- m -->
2) I am trying to leave tables behind forever, but I can't get my page to display correctly. Two paragraphs of text disapear when the page is loaded in IE 6 (works fine in Mozilla) but if I select the text it remains, or if I open a window in front of the page and close it the text on my problem page appears.
Check out the example:
<!-- m --><a class="postlink" href="http://www.32fish.com/testware/index2.html">http://www.32fish.com/testware/index2.html</a><!-- m -->
(you may need to refresh if the page displays correctly)Perhaps XHTML requires height to be declared as well? (You can use height:auto; if you don't want a fixed size.)You first problem is that you don't now what XHTML is. All elements need both an opening and a closing tag and tags for empty elements get combined thusly:
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
Also note that you should use external stylesheets with XHTML.I found this page useful when learning XHTML:
Introduction to XHTML: Differences with HTML 4 (<!-- m --><a class="postlink" href="http://www.wdvl.com/Authoring/Languages/XML/XHTML/dif.html">http://www.wdvl.com/Authoring/Languages ... L/dif.html</a><!-- m -->)
1)How would you go about specifying a specific width for an element in the CSS of an XHTML (strict) document?
Ex:
.something {
width: 75px;
}
This displays correct in regular old HTML (transitional)
but change the DTD to XHTML (strict or transitional) and no width is given and in this case all the words run together.
I have provided two test case examples:
HTML- <!-- m --><a class="postlink" href="http://www.32fish.com/test/case1.html">http://www.32fish.com/test/case1.html</a><!-- m -->
XHTML - <!-- m --><a class="postlink" href="http://www.32fish.com/test/case2.html">http://www.32fish.com/test/case2.html</a><!-- m -->
2) I am trying to leave tables behind forever, but I can't get my page to display correctly. Two paragraphs of text disapear when the page is loaded in IE 6 (works fine in Mozilla) but if I select the text it remains, or if I open a window in front of the page and close it the text on my problem page appears.
Check out the example:
<!-- m --><a class="postlink" href="http://www.32fish.com/testware/index2.html">http://www.32fish.com/testware/index2.html</a><!-- m -->
(you may need to refresh if the page displays correctly)Perhaps XHTML requires height to be declared as well? (You can use height:auto; if you don't want a fixed size.)You first problem is that you don't now what XHTML is. All elements need both an opening and a closing tag and tags for empty elements get combined thusly:
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
Also note that you should use external stylesheets with XHTML.I found this page useful when learning XHTML:
Introduction to XHTML: Differences with HTML 4 (<!-- m --><a class="postlink" href="http://www.wdvl.com/Authoring/Languages/XML/XHTML/dif.html">http://www.wdvl.com/Authoring/Languages ... L/dif.html</a><!-- m -->)