On Jun 28, 9:20 pm, "[email protected]" <[email protected]> wrote: > On Jun 28, 6:07 pm, oedipa <[email protected]> wrote: > > Hi- > > > I did spend a few hours researching this before posting here. Tried a > > few suggestions out there (like calling getElements instead of > > documentElement) and so on... Nothing's worked. It's a weird error. > > Or maybe it's obvious and I'm too tired to see it. > > > A few months ago I created a store locator based on Google's code and > > tutorial that they've had online for a little while now. It seems > > that recently, the client has noticed the searches have stopped > > working consistently. They return intermittent results. From a > > search on Roanoke, for instance, we got several different result > > sets. This ONLY happens with IE. Naturally, the other browsers were > > fine and the search works as expected. > > > The XML output looks valid and I ran it through an online validator > > (below is the link) that confirms this: > > http://validator.w3.org/check?uri=http%3A%2F%2Ffacilitylocator.vhca.o... > > It is valid, but it is empty... > <?xml version="1.0"?> > <markers/> > > If I make the search radius > bigger:http://validator.w3.org/check?uri=http%3A%2F%2Ffacilitylocator.vhca.o... > > It is not valid.
http://www.geocodezip.com/GenericMapBrowser.asp?zoom=3&lngattr=Lng&latattr=Lat&url=http%3A%2F%2Ffacilitylocator.vhca.org%2Fphpadv_genxml.php%3Flat%3D37%26lng%3D78%26radius%3D5000 and it looks like you have a problem on your server with negative longitudes, I don't think this point is supposed to be in China... Company="Blue Ridge Rehabilitation Center" Address="P.O. Box 4904, 300 Blue Ridge St." City="Martinsville" State="VA" ... Lat="36.6915262" Lng="79.8725386" -- Larry > > > > > > > The Map Locator is found here: > > > http://facilitylocator.vhca.org/ > > > A view-source will reveal the code at work there. Nothing > > special...all leveraged off of Google's example (v2 API). > > > > The really weird part about all this is, it only happens with IE (7 > > and 8 from what we can see) and it happens intermittently. However, > > it does consistently fail with searches on Roanoke, VA (I'm sure there > > are others). Some cities, it behaves just fine. This is a recent > > development. I half suspected that something in the database stored > > info (which gets updated via a form) was breaking it, but the > > validator seems to think it's all good and I can't see anything off > > hand... > > > If you just type Roanoke into the map search (not the alpha search > > above it), you'll see what I mean. you might get a result set for > > Roanoke the first time, but try changing the radius. It won't change > > the result set and then it errors every time with this msg. Or > > sometimes, it won't return anything at all: > > > > Webpage error details > > User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/ > > 4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR > > 3.0.30729; Media Center PC 6.0; MDDR; Tablet PC 2.0; .NET4.0C) > > Timestamp: Tue, 29 Jun 2010 00:54:41 UTC > > Message: 'documentElement' is null or not an object > > Line: 87 > > Char: 8 > > Code: 0 > > URI:http://facilitylocator.vhca.org/ > > > Here's some of the backend code (again this is from Google with my > > parameters entered). I did add the utf encoding just in case it was > > that...: > > > // Opens a connection to a mySQL server > > $connection=mysql_connect (localhost, $username, $password); > > $db_selected = mysql_select_db($database, $connection); > > $result = mysql_query($query); > > if (!$result) { > > die("Invalid query: " . mysql_error());} > > > header('Content-Type: text/html; charset=utf-8'); > > // Iterate through the rows, adding XML nodes for each > > while ($row = @mysql_fetch_assoc($result)){ > > $node = $dom->createElement("marker"); > > $newnode = $parnode->appendChild($node); > > $newnode->setAttribute("ID", $row['ID']); > > $newnode->setAttribute("Company", $row['Company']); > > $newnode->setAttribute("Address", $row['Address']); > > $newnode->setAttribute("City", $row['City']); > > $newnode->setAttribute("State", $row['State']); > > $newnode->setAttribute("Zip", $row['Zip']); > > $newnode->setAttribute("distance", $row['distance']); > > $newnode->setAttribute("Lat", $row['Lat']); > > $newnode->setAttribute("Lng", $row['Lng']);} > > > //create XML for the map to read. Done! > > echo $dom->saveXML(); > > > Any help or insight would be very much appreciated!!!!!!- Hide quoted text - > > - Show quoted text -- Hide quoted text - > > - Show quoted text - -- 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.
