Any help, with this welcome

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
jumpmuppet
Forum Newbie
Posts: 2
Joined: Wed Sep 06, 2006 7:06 am

Any help, with this welcome

Post by jumpmuppet »

Hi would greatly welcome any help with this

,,,////////////turn it into currency/////////////////////
setlocale(LC_MONETARY, 'en_US');
$price = money_format('%(#10n', $price) ;
$pricehigh = money_format('%(#10n', $pricehigh) ;
////////////turn it into currency/////////////////////

Above written for Linux based server.... Anybody got an idea how i can change it to run on windows??? ::)
User avatar
n00b Saibot
DevNet Resident
Posts: 1452
Joined: Fri Dec 24, 2004 2:59 am
Location: Lucknow, UP, India
Contact:

Post by n00b Saibot »

have to tried to run it on windows... ?
jumpmuppet
Forum Newbie
Posts: 2
Joined: Wed Sep 06, 2006 7:06 am

MMMMM

Post by jumpmuppet »

General failure????? Hard disk reading???

script will not run in windows,,, Money_Format is undefined,,, hence the reason to get a version of this similar to run on windows server....

any ideas
User avatar
n00b Saibot
DevNet Resident
Posts: 1452
Joined: Fri Dec 24, 2004 2:59 am
Location: Lucknow, UP, India
Contact:

Post by n00b Saibot »

PHP Manual wrote: Usage: string money_format ( string format, float number )

Purpose: Formats a number as a currency string
Availability: PHP 4 >= 4.3.0, PHP 5
so there is such a function in PHP. try running it atleast...
nickvd
DevNet Resident
Posts: 1027
Joined: Thu Mar 10, 2005 5:27 pm
Location: Southern Ontario
Contact:

Post by nickvd »

I just tried on my windoze box, and although php.net says the function exists on (PHP 4 >= 4.3.0, PHP 5), it isn't on my version (5.1.4)...

Very Strange
User avatar
n00b Saibot
DevNet Resident
Posts: 1452
Joined: Fri Dec 24, 2004 2:59 am
Location: Lucknow, UP, India
Contact:

Post by n00b Saibot »

eeps, my bad!! sorry.. :oops:
PHP Manual wrote: Note:
The function money_format() is only defined if the system has strfmon capabilities. For example, Windows does not, so money_format() is undefined in Windows
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Post Reply