echo '<g:markers>';
Posted: Sun Feb 08, 2009 5:45 pm
Hello guys
I'm trying to manually parse <g:markers> tags below. I'm sure its reasonably simple but its doing my nut in. The ISO Latin 1 encoding for ":" is :
I've tried the simple line below but my php script wont parse the ":"
I've tried also the following but the script wont parse the ":" either
The code snippet is attached below .The rest of the code works ok , when I leave out the ":"
Can somebody oblige me? Thanks
I'm trying to manually parse <g:markers> tags below. I'm sure its reasonably simple but its doing my nut in. The ISO Latin 1 encoding for ":" is :
I've tried the simple line below but my php script wont parse the ":"
Code: Select all
echo '<g:markers>';I've tried also the following but the script wont parse the ":" either
Code: Select all
echo '<g:markers>' ;Can somebody oblige me? Thanks
Code: Select all
header("Content-type: text/xml");
// Start XML file, echo parent node
// the mySql connection string is not shown here but works ok
// I've tried using encoding =UTF8 but doesnt work either
echo '<?xml version="1.0" encoding="ISO-8859-1"?>';
echo '<g:markers>';
// Iterate through the rows, printing XML nodes for each
while ($row = @mysql_fetch_assoc($result)){
// ADD TO XML DOCUMENT NODE
echo '<marker ';
echo 'country="' . $row['country'] . '" ';
echo 'lat="' . $row['lat'] . '" ';
echo 'lng="' . $row['lng'] . '" ';
echo '/>'; }
// End XML file
echo '</g:markers>';