Problem:
I am using Google Map API using the link: http://www.phpinsider.com/php/code/GoogleMapAPI/ - and when I try to print out an address on the map manually it will show up but not when selected from a database.
PHP code (this works):
$map->addMarkerByAddress('114 53 Grevgatan 31','The Tudor Arms','<b>The Tudor Arms</b>');
PHP code (this does NOT work):
$location = $row['postalnumber'] . ' ' . $row['address'] . ' ' . $row['city'];
$map->addMarkerByAddress($location , $row['name'],'<b>'. $row['name'] .'</b>');
Desired solution:
To be able to extract data from a table in an SQL database and send it to the Google Map API function.
Additional remarks: When I echo the variables above the address and all information will print out but not when sent to the Google Map API function. Do I need to convert the data into a string?