Re: Math Script
| From: | David Robley | Date: | Sun, 04 Nov 2001 23:40:09 +0000 |
| Subject: | Re: Math Script | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-73427@lists.php.net to get a copy of this message | ||
On Mon, 5 Nov 2001 05:47, Kacey A. Murphy wrote:
> Is this possible what I want this to do is take a price say 10.00 in a
> field in the mySQL databse and do a math set such as -0.5 * 1
>
> This is in a link and I was echoing the field in the database but how
> do I put a math thingy in there. <?php echo
> $products->Fields("itm_aship")?>
>
> Could I do this
> <?php echo $products->Fields("itm_aship")-0.5*1?>
> or am I thinking all wrong... Thanks!
That idsea should work - but also consider doing the same thing in your
database query.
--
David Robley Techno-JoaT, Web Maintainer, Mail List Admin, etc
CENTRE FOR INJURY STUDIES Flinders University, SOUTH AUSTRALIA
"Your fly is undone," was Tom's zippy rejoinder.