View Full Version : Question(s) for PHP Pros


User 4
02-12-2007, 09:13 AM
I'm taking a PHP + mySQL class at school, and I wanted to ask some regular php coders out there about how you put php into a page.

I know a small amount of php, enough to make just a simple database driven site. Every tutorial that I've learned from just slaps the php in where it needs to be used. An example would be this:
CODE
<?php

$date = date("F d, Y H:i:s a");

?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head><title>Comm393: </title>
<meta http-equiv="content-type" content="text/html;charset=utf-8" />
</head>
<body>

<h1>Hello World</h1>
<center><em><?php echo("$date") ?></em></center>
</body></html>

__________________
Dell Coupons[/ul] [url=http://www.movingoncourses.com]English course in summer (http://www.cheapstingybargains.com/)