Jump to content

I'm just starting and hitting hurdles....


trickyd60

Recommended Posts

I have this simple piece of html:

 

 

<!DOCTYPE html><html><head> <meta charset="UTF-8"> <style> .error {color: #FF0000;} </style> <title>20 Dollar Sizzler</title></head>

<body><?php echo "My first PHP script!"; ?></body></html>

 

the validator doesn't like the <?php tag

 

I copied that directly from the W3 tutorial

 

What's going wrong please?

 

regards, Ricky

Link to comment
Share on other sites

If the file is saved with a .php extension then the PHP will be parsed and executed.

 

When trying to validate the page, don't copy and paste the code, give the URL of the page to the validator.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...