I want to know what currency code lies in my variable value.
For example:
$var = "$200";
$check = array("$", "AU$", "CA$", "£", "€", "¥");
If $var has "$"
$currency = USD
else if $var has "£"
$currency = GBP
and so on..
What I was trying is:
$result = strpos($var, $check);
if ($result === '$') {
$currency = 'USD';
} else if ($result === '£') {
$currency = 'GBP';
| else ...