Re: PHP

Hi Cidy,

> I am new to PHP and have had problems with validating my code. I have been told that W3C's validating services does not validate php, asp etc…
> Can anyone tell me if this is true?

No, but the validator validates the HTML generated by your php (asp..) scripts.
Lets say your php script is this one:

<?php
echo "<html><body>";
echo "<h1>I am a header</h1>";
echo "</body></html>";
?>

The validator won't look to the eventual errors in this php script,
but it will look at the stuff that this script will display (echo)
In other words it will validate the thing that your php app will send
to the browser, since the validator is itself like an agent.

so it will validate this:
<html><body><h1>I am a header</h1></body></html>

--
Karim

Received on Saturday, 21 October 2006 18:45:27 UTC