RE: [PHP] beginner in PHP

From: Date: Thu, 13 Jun 2002 03:24:25 +0000
Subject: RE: [PHP] beginner in PHP
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-101872@lists.php.net to get a copy of this message
Thanks but that doesn't work. -----Original Message----- From: Tom Ray [mailto:tom@blazestudios.com] Sent: Wednesday, June 12, 2002 10:59 PM To: pperry@inter-design.net Cc: Php Subject: Re: [PHP] beginner in PHP Try this: echo "$catalog[unitprice]"; in my experience I've only been able to use the echo() without the quotation marks if I'm calling a function, for variables you need the quotation marks. Hope this helps. Phillip Perry wrote: >Can someone tell me why this doesn't work? >The $mycart array is fine and the $catalog array is also fine but nothing >inside the if statement prints. I've tried other echo statements but nothing >prints at all. > >while (list($key,$value) = each($mycart)) > { > if ($value == $catalog[itemcd]) > { > > echo $catalog[unitprice]; > > } > } > > >Thanks > >Phil > > > >

« previous php.general (#101872) next »