Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Easy Newbie Question 2

Status
Not open for further replies.

LyallJ

MIS
Jul 18, 2001
124
US
First off, i am an EXTREME newbie to php. lots of VB background tho.

figured i make my first script easy. Ya right! [ponder]

When i try to run it, it gives me:
"Parse error: parse error, unexpected T_VARIABLE in /home/test/Hurriclean/qoutecode.php on line 10"

Heres a link to front end i have up:

Thanks again for yalls help.

Heres the code that i have:
<?php
/* get nums from form*/
$roomandhall=roomanhalltxt
$addroom=addroomtxt
$scotch=scotchtxt
$couch=couchtxt
$loveseat=loveseattxt
$chair=chairtxt
$drap=draptxt
$rugs=rugstxt
$stairs=stairstxt
/* figure prices for each*/
$tproomandhall=$roomandhall*10
$tpaddroom=$addromm*10
$tpscotch=$scotch*10
$tpcouch=$couch*10
$tploveseat=$loveseat*10
$tpchair=$chair*10
$tpdrap=$drap*10
$tprugs=$tprugs*10
$tpstairs=$stairs*10
/*get total price*/
$totalprice=$tproomandhall+$tpaddroom+$tpscotch+$tpcouch+$tploveseat+$chair+$tpdrap+$tprugs+$tpstairs
/*get tax of 8%*/
$tax=$totalprice*.08
/*get grand total, tax and all*/
$grandtotal=$tax+$totalprice
?>
 
Here's a quick hint:
PHP requires statments to be delimited by semicolons.
Code:
$variable = $value
;
 
ok, told ya i am a newbie. but i can bet you i will not forget ; anytime soon.

Star for both of ya!!!!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top