For example, you want to get the currency symbol for a particular country.
Code: Select all
//get country
$sql = "SELECT country FROM customer_profiles WHERE (custid = '$custid')";
$result = mysql_query( $sql );
$row = mysql_fetch_assoc( $result );
extract($row, EXTR_OVERWRITE );
// get currency symbol
$sql = "SELECT currency_symbol FROM currencies WHERE (associated_country = '$country')";
$result = mysql_query( $sql );
$row = mysql_fetch_assoc( $result );
extract($row, EXTR_OVERWRITE );Thanks for your help.