We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you two Citrix podcasts. Learn about 2020 trends and get answers to your biggest Citrix questions!Listen Now


ASP conditional javascript

webdork asked
Medium Priority
Last Modified: 2010-04-17
I like the dhtml drop down navigation menus... but of course it's conditional on javascript being present.

I usually put the nav in an include file. I'm looking for a way a reliable way to substitute the include file when js not enabled.

IF JS present THEN
<!--#include file="dhtml_nav.asp" -->
<!--#include file="hlink_nav.asp" -->

I'm open to a better solution.
Watch Question

Jesse BSystem Administrator

Using browsercap is probably your best bet.  Some code of what you can use it for is available at http://www.learnasp.com/freebook/asp/bc.aspx


Thanks for responding. That does not work in Firefox. Any idea why not?
System Administrator
It may be that the browsercap.ini file on your webserver is out of date.  You can get more recent versions at http://www.garykeith.com/browsers/downloads.asp

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.


Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.