RE: [PHP-WIN] About the unexpected T_VARIABLE
| From: | Denis Gerasimov | Date: | Wed, 29 Dec 2004 09:07:22 +0000 |
| Subject: | RE: [PHP-WIN] About the unexpected T_VARIABLE | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-25199@lists.php.net to get a copy of this message | ||
> -----Original Message-----
> From: michael@skys.com.cn [mailto:michael@skys.com.cn]
> Sent: Wednesday, December 29, 2004 8:41 AM
> To: php-windows@lists.php.net
> Subject: [PHP-WIN] About the unexpected T_VARIABLE
>
> Hi;
>
> I'm new in php. I has try some sample code in the book
> <? php
Has to be <?php (notice space char).
> $hamburger = 4.95;
>
> $milkshake = 1.95;
>
> $cola = .85;
>
> $food = 2 * $hamburger + $milkshake + $cola;
>
> $tax = $food * .075;
>
> $tip = $food * .16;
>
> $total = $food + $tax + $tip;
>
> print "Total cost of the meal is \$$total";
>
> ?>
>
> But I always get "Parse error: syntax error, unexpected T_VARIABLE in
> e:\Inetpub\wwwroot\meal.php on line 2"
>
> So any suggestion
>
> Regards
>
> Michael
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php