Refactored Currency Display using PHP numfmt_format_currency() function as this is best practice and will put the right currency symbol in the right place based off locale and currency type
This commit is contained in:
@@ -101,7 +101,7 @@ $sql_categories = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_
|
||||
|
||||
|
||||
?>
|
||||
<td class="text-right"><?php echo get_currency_symbol($session_company_currency); ?> <?php echo number_format($payment_amount_for_month,2); ?></td>
|
||||
<td class="text-right"><?php echo numfmt_format_currency($currency_format, $payment_amount_for_month, $session_company_currency); ?></td>
|
||||
|
||||
<?php
|
||||
|
||||
@@ -109,7 +109,7 @@ $sql_categories = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_
|
||||
|
||||
?>
|
||||
|
||||
<td class="text-right text-bold"><?php echo get_currency_symbol($session_company_currency); ?> <?php echo number_format($total_payment_for_all_months,2); ?></td>
|
||||
<td class="text-right text-bold"><?php echo numfmt_format_currency($currency_format, $total_payment_for_all_months, $session_company_currency); ?></td>
|
||||
</tr>
|
||||
|
||||
<?php
|
||||
@@ -138,14 +138,14 @@ $sql_categories = mysqli_query($mysqli,"SELECT * FROM categories WHERE category_
|
||||
|
||||
?>
|
||||
|
||||
<th class="text-right"><?php echo get_currency_symbol($session_company_currency); ?> <?php echo number_format($payment_total_amount_for_month,2); ?></th>
|
||||
<th class="text-right"><?php echo numfmt_format_currency($currency_format, $payment_total_amount_for_month, $session_company_currency); ?></th>
|
||||
<?php
|
||||
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<th class="text-right"><?php echo get_currency_symbol($session_company_currency); ?> <?php echo number_format($total_payment_for_all_months,2); ?></th>
|
||||
<th class="text-right"><?php echo numfmt_format_currency($currency_format, $total_payment_for_all_months, $session_company_currency); ?></th>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
Reference in New Issue
Block a user