• Since Croatia is starting to use EUR as official currency we need to display both HRK (Croatian Kuna) and Euro on all Invoices since September.
    I added a line under Total and tried to convert Total to EUR and show it but I always get 0 as a result. Could You please help me with this?

    `echo round(floatval($this->get_formatted_total())/7.5345,2).’€’;

    Thank You.

Viewing 1 replies (of 1 total)
  • Thread Starter lukaaa

    (@lukaaa)

    Hi there,
    I’ve managed to sort this out like this:

            <?php 
            $totalkn = (float)$this->order->get_total();
            $totaleur = round($totalkn/7.5345,2).'€';
            echo $totaleur;
            ?>

    Floatval() doesn’t seem to work here while (float) works just fine.
    Hope this will help someone. Bye.

Viewing 1 replies (of 1 total)
  • The topic ‘Double currency display for Total’ is closed to new replies.