Hi,
I have used this article (Using PHP/ MySQL with Google Maps) :
http://code.google.com/apis/maps/articles/phpsqlajax.html.
The code works correctly, reading the longitude and lattitude values
from the database and creating pointers on the map as it is supposed
to.
However in the genxml.php file I want to modify the query so that it
selects the longitude and latitude values just for the product the
user is currently viewing. The database table stores the longitude and
latitude values for all the products I have. However on the map i wish
to display only the markers for the product the user is viewing at
that moment in time.
I have modified my query so that it is:
$result = mysql_query("SELECT p.productTypeID, productName, GPSLon,
GPSLat
FROM product p, productType pt, observation o
WHERE p.productTypeID = $productID
AND p.productTypeID = pt.productTypeID
AND p.productID = o.productID");
$productID on the first line of the WHERE clause is a variable I
created earlier in this script which reads from the session the
product ID of the product the user is currently viewing.
However it is this line which keeps failing and if I go to view the
map, nothing is displayed - just blank white page. But instead if I
substitute a product ID, then the map displays just the markers for
that product.
Any ideas what the problem could be or if anyone has encountered such
an issue.
Thanks in advance.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Maps API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/Google-Maps-API?hl=en
-~----------~----~----~----~------~----~------~--~---