Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

AOL/Browser help

Status
Not open for further replies.

gasparrelli

Programmer
Sep 13, 2000
24
0
0
US
We are having some trouble with certain browsers not handling the CF-generated JavaScript (or any JS for that matter) How do we determine which browsers support this and keep users of those browsers from continuing? AOL seems particularly troublesome for us.

I have seen that I can catch the browser version with errors - is there any way to catch this without creating an error (wouldn't want it to go to site wide error handler if we are only trying to get browser version and do some logic to see if user can continue)

Does anyone know how to interpret the browser info that comes to us? All errors seem to say Mozilla (I thought for some reason that was Netscape), even the Internet Explorer generated ones.

Thanks for advice on how you have handled this in your projects,
Kim
 
I think IE returns Mozilla to show that it is Netscape compatible. At least I think I heard that somewhere. There are probably better ideas, but you might use some javascript to redirect the page to another page with the CF include. But make sure to have a notice about what the user is missing or some other content on the redirecting page so there is something displayed if the JS is ignored by the browser.

Here's a quick (untested) sample code:

<head>
<script language=&quot;javascript&quot;>
<!--
self.location.replace(&quot;file.cfm&quot;)
-->
</script>
</head>
<body>
<div align=&quot;center&quot;>
Your missing the best part!! Come back with a better browser
</div>
</body>

if the javascript isn'tunderstood, the user will get the message (or content) in the body.

bankholdup
 
Thanks bankholdup. That's a terrific idea, I'm going to give that a try!

I have also found a custom tag at Allaire's website called cf_browser which can return the browser type and version, but for some reason I don't think I've installed the tag in the right place or I'm calling it wrong, because it always tells me 'not found' Is it satisfactory to put the cf_browser.vtm as is into the same folder with the page that's calling it? Do I also need to leave cf_browser.cfm in that folder? Or should I put all files from the download somewhere in particular?

Thanks for helping the new guy, I know much of this is probably pretty obvious. But writtem resources around here are pretty slim and I'm still awating the books I've ordered...

Kim
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top