Thanks for the help... I fixed it! I'm a bonehead!

So this may help someone else...

When Google maps links back to the kml there appears to be nothing in
the http header 'HTTP_USER_AGENT' which causes the PHP get_browser
function to fail and spew errors into the result buffer. I assume that
there is nothing in the http header 'HTTP_USER_AGENT' because the way
I fixed it was simple:

if( $_SERVER['HTTP_USER_AGENT'] )
{
$browserInfo = get_browser( $_SERVER['HTTP_USER_AGENT'], true );

$this->m_xslt_args['browser'] = $browserInfo['browser'];
$this->m_xslt_args['browser-major'] = $browserInfo['majorver'];
$this->m_xslt_args['browser-minor'] = $browserInfo['minorver'];
$this->m_xslt_args['browser-platform'] = $browserInfo['platform'];
}

Obviously if null == $_SERVER['HTTP_USER_AGENT'] then don't go in
here. Problem solved. It's also why all the other verifications
produced valid results... All the ways that I could think of to check
for an error used a browser and therefore it didn't fail. This doesn't
happen with aspx... The browser info under Microsoft may well report
an error but I don't check for it and the Microsoft server doesn't
spew the error into the output buffer.

I'm so used to an xslt style of "if it ain't there don't do anything"
approach that I didn't think of it.

Anyway....
Here's the links, and if you want to see the code click the code link
and then the code info link.
http://www.phsalumni1971.net/phptest/index.php
http://www.dlgreene.com/default.aspx

Thanks again for everyone's help.

On Apr 24, 5:34 am, dlgreene <[email protected]> wrote:
> This link 
> works:http://maps.google.com/maps?geocode=&q=http://www.dlgreene.com/gmap_d...
> Microsoft Server.
> Much more info and view the kml in IE (firefox won't) and code that
> made the kml from xslt:http://www.dlgreene.com/code_info.aspx
>
> This link 
> fails:http://maps.google.com/maps?geocode=&q=http://www.phsalumni1971.net/p...
>
> I'm highly confident both kml's are the same. Both kml's are generated
> from the same xslt. Again same code info and viewing 
> at:http://www.phsalumni1971.net/phptest/code_info.php
>
> Both sites are mine. The php site (phsalumni1971) seem's to force all
> browsers to download instead of viewing the kml(xml). You can add ?
> displaycode=true to view the xslt and xml that generated the xhtml.
> All pages verify at W3C.
> You can view the aspx C# and the php code at the code_info page at
> either site. The code info page is available on any page via the code
> link top and bottom left then code info.
>
> I've seen many posts about this similar problem. This case might be a
> good study because IE responds differently to the same kml on
> differing servers. I wonder how much is it the browsers and how much
> is the servers? And more important... Anyone know how to fix this?
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to