Page 1 of 1

Php interpreting

Posted: Fri Feb 04, 2005 10:19 am
by perpetual_dream
I'm new to php.... but I'm training on some of the examples...
My first problem that I'm facing is that my browser I.E.6!! doesn't appear to intepret php... instead it shows the code itself!
for example I'm trying to use the date feature to post the date at which an order for example took place.... here is the outcome
Order processed at “; echo date(“H:i, jS F”); echo “
”; echo “

Your order is as follows:”; echo “
”; echo $tireqty.” tires
”; echo $oilqty.” bottles of oil
”; echo $sparkqty.” spark plugs
”; ?>
and here is the source code
<?
echo “<p>Order processed at “;
echo date(“H:i, jS F”);
echo “<br>”;
echo “<p>Your order is as follows:”;
echo “<br>”;
echo $tireqty.” tires<br>”;
echo $oilqty.” bottles of oil<br>”;
echo $sparkqty.” spark plugs<br>”;
?>
thanx
:)

Posted: Fri Feb 04, 2005 10:21 am
by feyd
General Discussion is not where this goes... :roll::roll:

Moved to PHP - Code.


The problem has to do with your server not set up to run this script as php. Your usage of angled double quotes is binary data, and will not work in a php script environment outside of strings.