My big questions would be where's your FIELDSET, and what the devil makes that a TABLE in the first place? Semantic markup could go a LONG ways towards cleaning that up into something functional instead of all those extra tags for NOTHING. LABEL and INPUT already have semantic meanings, there is NO reason to be wrapping those with other tags that have meanings like tables or lists.

... as could an echo statement and axing all that annoying hard to follow <?php ?> nonsense -- but that's probably just me; I'd like to see <?php and ?> removed from PHP in it's entirety... also on 'email' you're opening a quote before value that shouldn't be there.

NOT that you should be writing new code in transitional anyways -- this isn't 1997.

REGARDLESS of what you are doing for styling, it is VERY unlikely you should be using much more than:

Code:
} else {

	echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html
	xmlns="http://www.w3.org/1999/xhtml"
	lang="en"
	xml:lang="en"
><head>

<meta
	http-equiv="Content-Type"
	content="text/html; charset=utf-8"
/>

<meta
	http-equiv="Content-Language"
	content="en"
/>

<link
	type="text/css"
	rel="stylesheet"
	href="screen.css"
	media="screen,projection,tv"
/>

<title>
	Demo Form
</title>

</head><body> 

<form action="',$_SERVER['PHP_SELF'],'" method="POST"> 
	<fieldset>
	
		<div class="',form_row_class('NAME',$errors),'" > 
			<label for="NAME">Name</label>
			<input 
				type="text"
				name="NAME"
				id="NAME"
				value="',(isset($_POST['NAME']) ? hsc($_POST['NAME']) : ''),'"
			/> 
			',error_for('NAME',$errors),'
		</div>
		 
		<div class="',form_row_class('TELEPHONE',$errors),'"> 
			<label for="TELEPHONE">Telephone</label>
			<input
				type="text"
				name="TELEPHONE"
				id="TELEPHONE"
				value="',(isset($_POST['TELEPHONE']) ? hsc($_POST['TELEPHONE']) : ''),'"
			/> 
			',error_for('TELEPHONE',$errors),' 
		</div>
		 
		<div class="',form_row_class('EMAIL',$errors),'"> 
			<label for="EMAIL">Email Address</label>
			<input
				name="EMAIL"
				id="EMAIL"
				type="text"
				value="',(
					isset($_POST['EMAIL']) ? hsc($_POST['EMAIL']) : ''
				),'"
			/> 
			',error_for('EMAIL',$errors),'
		</div>
		 
		<div class="',form_row_class('COMMENTS',$errors),'"> 
			<label for="COMMENTS">Comments</label>
			<textarea
				name="COMMENTS"
				id="COMMENTS"
			>',(
				isset($_POST['COMMENTS']) ? hsc($_POST['COMMENTS']) : ''
			),'</textarea>
			',error_for('COMMENTS',$errors),' 
		</div> 
		
		<input type="submit" value="Go!" class="submit" /> 
		 
	</fieldset> 
</form> 

</body></html>';

}

?>
for the markup. Basically drag it kicking and screaming into THIS century.