Re: [PHP] Money format
LukÃÅ Moravec - PTV Servis wrote: is there any function wich can format a "double" or "string" into "money format".for example: 1526789,99 to 1.526.789,99 or something like that.? number_format() -- ---John Holmes... Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/ php|architect: The Magazine for PHP Professionals â www.phparch.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Money format
[snip] Hi to all, is there any function wich can format a "double" or "string" into "money format".for example: 1526789,99 to 1.526.789,99 or something like that.? Regards Lukas [/snip] http://www.php.net/number_format -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Money format
> Hi to all, > is there any function wich can format a "double" or "string" into "money > format".for example: 1526789,99 to 1.526.789,99 or something like that.? > Regards Lukas > You could try http://us2.php.net/manual/en/function.money-format.php or http://us2.php.net/manual/en/function.number-format.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Money format
Hi, From php.net/sprintf: I think you'd have to format the . and , a bit differently, but that should be a start. -Dan Joseph > -Original Message- > From: Lukáš Moravec - PTV Servis [mailto:[EMAIL PROTECTED] > Sent: Tuesday, July 20, 2004 2:10 PM > To: [EMAIL PROTECTED] > Subject: [PHP] Money format > > Hi to all, > is there any function wich can format a "double" or "string" into "money > format".for example: 1526789,99 to 1.526.789,99 or something like that.? > Regards Lukas -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Money format
As I said it is almost what I want but not quite. If it can be done a code snipit would be good. Ben At 19:44 30/01/2003 -0700, V Dub wrote: http://php.net search in functions for number_format Cheers! Quoting Ben Edwards <[EMAIL PROTECTED]>: ### I wish to format money with a £ sign, two decimal places and commas ### separating thousands. I seem to be able to do the £ and decimal places with ### ### sprintf or use money_format to do the commas but cant find how to do ### both/combine them. ### ### any insight, ### ben ### ### ### * Ben Edwards +44 (0)117 968 2602 * ### * Critical Site Builderhttp://www.criticaldistribution.com * ### * online collaborative web authoring content management system * ### * Get alt news/views films online http://www.cultureshop.org * ### * i-Contact Progressive Video http://www.videonetwork.org * ### * Smashing the Corporate image http://www.subvertise.org * ### * Bristol Indymedia http://bristol.indymedia.org * ### * Bristol's radical news http://www.bristle.org.uk * ### * PGP : F0CA 42B8 D56F 28AD 169B 49F3 3056 C6DB 8538 EEF8 * ### ### -- Richard Whitney Transcend Development Producing the next phase of your internet presence. [EMAIL PROTECTED] http://xend.net 602-971-2791 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.449 / Virus Database: 251 - Release Date: 27/01/2003 * Ben Edwards +44 (0)117 968 2602 * * Critical Site Builderhttp://www.criticaldistribution.com * * online collaborative web authoring content management system * * Get alt news/views films online http://www.cultureshop.org * * i-Contact Progressive Video http://www.videonetwork.org * * Smashing the Corporate image http://www.subvertise.org * * Bristol Indymedia http://bristol.indymedia.org * * Bristol's radical news http://www.bristle.org.uk * * PGP : F0CA 42B8 D56F 28AD 169B 49F3 3056 C6DB 8538 EEF8 * --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.449 / Virus Database: 251 - Release Date: 27/01/2003 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Money format--concatenate?
I hope this helps. Have you thought of concatenation? $a=spritf(however you set it up to get your decimals and comas) $b="£".$a; Will that not work? Leonard. -Original Message- From: V Dub [mailto:[EMAIL PROTECTED]] Sent: Thursday, January 30, 2003 9:45 PM To: Ben Edwards Cc: [EMAIL PROTECTED] Subject: Re: [PHP] Money format http://php.net search in functions for number_format Cheers! Quoting Ben Edwards <[EMAIL PROTECTED]>: ### I wish to format money with a £ sign, two decimal places and commas ### separating thousands. I seem to be able to do the £ and decimal places with ### ### sprintf or use money_format to do the commas but cant find how to do ### both/combine them. ### ### any insight, ### ben ### ### ### * Ben Edwards +44 (0)117 968 2602 * ### * Critical Site Builderhttp://www.criticaldistribution.com * ### * online collaborative web authoring content management system * ### * Get alt news/views films online http://www.cultureshop.org * ### * i-Contact Progressive Video http://www.videonetwork.org * ### * Smashing the Corporate image http://www.subvertise.org * ### * Bristol Indymedia http://bristol.indymedia.org * ### * Bristol's radical news http://www.bristle.org.uk * ### * PGP : F0CA 42B8 D56F 28AD 169B 49F3 3056 C6DB 8538 EEF8 * ### ### -- Richard Whitney Transcend Development Producing the next phase of your internet presence. [EMAIL PROTECTED] http://xend.net 602-971-2791 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Money format
http://php.net search in functions for number_format Cheers! Quoting Ben Edwards <[EMAIL PROTECTED]>: ### I wish to format money with a £ sign, two decimal places and commas ### separating thousands. I seem to be able to do the £ and decimal places with ### ### sprintf or use money_format to do the commas but cant find how to do ### both/combine them. ### ### any insight, ### ben ### ### ### * Ben Edwards +44 (0)117 968 2602 * ### * Critical Site Builderhttp://www.criticaldistribution.com * ### * online collaborative web authoring content management system * ### * Get alt news/views films online http://www.cultureshop.org * ### * i-Contact Progressive Video http://www.videonetwork.org * ### * Smashing the Corporate image http://www.subvertise.org * ### * Bristol Indymedia http://bristol.indymedia.org * ### * Bristol's radical news http://www.bristle.org.uk * ### * PGP : F0CA 42B8 D56F 28AD 169B 49F3 3056 C6DB 8538 EEF8 * ### ### -- Richard Whitney Transcend Development Producing the next phase of your internet presence. [EMAIL PROTECTED] http://xend.net 602-971-2791 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php