|
![](/images/resource/spacer.gif) |
|
การคำนวณภาษี ไม่ตรงเพราะอะไรครับ ไม่เข้าใจเกี่ยวสูตรหรือเปล่า |
|
![](/images/resource/viewboard_01.gif?v=1001) |
|
|
![](/images/resource/viewboard_03.gif?v=1001) |
![](/images/resource/viewboard_04.gif?v=1001) |
|
ผมทำสูตรคำนวณภาษี ได้แต่ไม่ได้ค่าแค่ 1 เพราะอะไร
Code (PHP)
// ผลรวม ทั้งมหด
$total6= number_format($total4,2,'.',',');
// นำผลรวมมาคิดภาษี
$vat4= number_format($total4*7/100,2,'.',',');
//จำนวนเงินสุทธิ Net Total
$totalreal=number_format($total4+$vat4,2,'.',',');
![vattt vattt](https://www.thaicreate.com/upload/stock/20150406161936.jpg?v=1001)
จริงๆ ต้องได้
21187.49
Tag : PHP
![](/images/adv.jpg?v=1001)
|
ประวัติการแก้ไข 2015-04-06 16:22:06
|
![](/images/resource/blockviewtopic_01.gif?v=1001) |
![](/images/resource/blockviewtopic_02.gif?v=1001) |
![](/images/resource/blockviewtopic_03.gif?v=1001) |
![](/images/resource/blockviewtopic_04.gif?v=1001) |
Date :
2015-04-06 16:20:38 |
By :
chayaphol |
View :
1670 |
Reply :
3 |
|
![](/images/resource/blockviewtopic_06.gif?v=1001) |
![](/images/resource/blockviewtopic_07.gif?v=1001) |
![](/images/resource/blockviewtopic_08.gif?v=1001) |
![](/images/resource/blockviewtopic_09.gif?v=1001) |
|
|
|
![](/images/resource/viewboard_06.gif?v=1001) |
![](/images/resource/viewboard_07.gif?v=1001) |
|
![](/images/resource/viewboard_08.jpg?v=1001) |
![](/images/resource/viewboard_09.gif?v=1001) |
![](/images/resource/viewboard_01.gif?v=1001) |
|
|
![](/images/resource/viewboard_03.gif?v=1001) |
![](/images/resource/viewboard_04.gif?v=1001) |
|
// ผลรวม ทั้งมหด
$total6= number_format($total4,2,'.',',');
// นำผลรวมมาคิดภาษี
$vat4= number_format($tmp=($total4*7/100),2,'.',',');
//จำนวนเงินสุทธิ Net Total
$totalreal=number_format($total4+$tmp,2,'.',',');
$total4 + '1,386.10' = $total4 + 1
|
ประวัติการแก้ไข 2015-04-06 17:15:52
![](/images/resource/blockviewtopic_01.gif?v=1001) |
![](/images/resource/blockviewtopic_02.gif?v=1001) |
![](/images/resource/blockviewtopic_03.gif?v=1001) |
![](/images/resource/blockviewtopic_04.gif?v=1001) |
Date :
2015-04-06 16:35:56 |
By :
Chaidhanan |
|
![](/images/resource/blockviewtopic_06.gif?v=1001) |
![](/images/resource/blockviewtopic_07.gif?v=1001) |
![](/images/resource/blockviewtopic_08.gif?v=1001) |
![](/images/resource/blockviewtopic_09.gif?v=1001) |
|
|
![](/images/resource/viewboard_06.gif?v=1001) |
![](/images/resource/viewboard_07.gif?v=1001) |
|
![](/images/resource/viewboard_08.jpg?v=1001) |
![](/images/resource/viewboard_09.gif?v=1001) |
![](/images/resource/viewboard_01.gif?v=1001) |
|
|
![](/images/resource/viewboard_03.gif?v=1001) |
![](/images/resource/viewboard_04.gif?v=1001) |
|
// ผลรวม ทั้งมหด
$total6= number_format($total4,2,'.',',');
// นำผลรวมมาคิดภาษี
$vat4= number_format($total4*7/100,2,'.',',');
//จำนวนเงินสุทธิ Net Total
$totalreal=number_format($total4+$vat4,2,'.',',');
เขียนให้เข้าใจง่ายๆ
$total = $total4;
$vat = ($total*7/)100;
$net = $total+$vat;
number_format ไว้สำหรับแสดงรูปแบบครับ
|
![](/images/resource/blockviewtopic_01.gif?v=1001) |
![](/images/resource/blockviewtopic_02.gif?v=1001) |
![](/images/resource/blockviewtopic_03.gif?v=1001) |
![](/images/resource/blockviewtopic_04.gif?v=1001) |
Date :
2015-04-06 16:58:46 |
By :
mee079 |
|
![](/images/resource/blockviewtopic_06.gif?v=1001) |
![](/images/resource/blockviewtopic_07.gif?v=1001) |
![](/images/resource/blockviewtopic_08.gif?v=1001) |
![](/images/resource/blockviewtopic_09.gif?v=1001) |
|
|
![](/images/resource/viewboard_06.gif?v=1001) |
![](/images/resource/viewboard_07.gif?v=1001) |
|
![](/images/resource/viewboard_08.jpg?v=1001) |
![](/images/resource/viewboard_09.gif?v=1001) |
|
|
|
![](/images/digitalocean-banner.jpg)
|
Load balance : Server 03
|