Php interpreting

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
perpetual_dream
Forum Newbie
Posts: 1
Joined: Fri Feb 04, 2005 10:14 am

Php interpreting

Post 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
:)
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post 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.
Post Reply