!DOCTYPE? what to use...

liunx

Guest
How does a person know what DOCTYPE to use to valida a web page? I use <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> but sometimes I get an error message telling me that my DOCTYPE does not match the HTML code.<!--content-->Also what about the Character Encoding?<!--content-->I generally use <!doctype html public "-//w3c//dtd html 4.01 transitional//en"> and <br />
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> and everything works fine. Validates properly.<!--content--><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><br />
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" ><br />
<head><br />
<br />
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" /><!--content-->Thanks for the replys.<!--content-->
 
Top