|
|
|
ผมอยากเขียน code ให้มันใส่ลูกน้ำ ตรงค่าเงินอะครับ |
|
|
|
|
|
|
|
ตามนี้ครับ(PHP)
$number=123456.02;
echo number_format( $number )."<br />"; //123,456
|
|
|
|
|
Date :
2012-09-19 13:41:53 |
By :
mangkunzo |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
เพิ่มเติม
Code (PHP)
<?php
$number = 1234.56;
// english notation (default)
$english_format_number = number_format($number);
// 1,235
// French notation
$nombre_format_francais = number_format($number, 2, ',', ' ');
// 1 234,56
$number = 1234.5678;
// english notation without thousands separator
$english_format_number = number_format($number, 2, '.', '');
// 1234.57
?>
|
|
|
|
|
Date :
2012-09-19 14:09:00 |
By :
mr.win |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ขอบคุณคับ
|
|
|
|
|
Date :
2012-09-19 15:23:55 |
By :
sorn |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Load balance : Server 05
|