Jump to content

Format money value inconjunction with setlocale


Ne0_Dev

Recommended Posts

Hi Guys,

 

I'm after a bit of help/guidance on an issue I am currently trying to resolve.  I currently have a page where I use setlocale(LC_MONETARY) to automatically format values to a specific currency depending on which country parameter I pass to this function.  At the moment I only require one currency for all values on the page.

 

I am now trying to figure out a way to have different currency values on the same page and just wondered if it is possible to specify multiple setlocale on a page?

 

If so I would need to use either an if/else/if statement or a switch statement to determine which one to use based on the country value of the record being returned from the database.

 

At the moment I am specifying the setlocale in a php block at the top of the page.

Any thoughts or suggestions are most appreciated.

 

Ne_Dev

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.