Milonic provide full featured pull down web menus for some of the worlds largest companies
click here to see what it can do for you

Download Milonic DHTML Menu
Buy Milonic DHTML Menu

Back To Start Of Archive
Taken From The Forum: Archived Topics for the old Version 3.0 JavaScript Menu
Forum Topic: Click to view post
Last Updated: Saturday July 14 2012 - 06:07:31

Non.JS browsers


Poster: gregorr
Dated: Monday May 5 2003 - 10:01:51 BST

Is there any way to "wrap" the JavaScript milonic menu code so that folks with non JS browsers can see at least a static menu of sorts?

Thx
R


Poster: kevin3442
Dated: Wednesday May 7 2003 - 0:07:28 BST

Hi R,

Short answer: No. If a site visitor disables js, the menus can't run. You could provide a <noscript> block that would take the visitor to another page, where you have static links to the various sections in your site (this is also a good approach to make sure your pages are catalogued by search engines).

Kevin


Poster: gregorr
Dated: Saturday May 10 2003 - 10:31:50 BST

Do you have an example for me of how to use the <noscript> tag?


Poster: kevin3442
Dated: Tuesday May 13 2003 - 0:11:17 BST

I don't really have an example. If you do a web search for <noscript> you should be able to find many examples and discussions. The general idea is that if someone's browser understands the script tag, then it will do what ever is specified in the tag. I the site visitor is using a browser that doesn't understand javascript or if they have javascript turned off, then the browser should skip the script tag and do what's in the noscript tag. Your code might look something like:
Code:
<script language=JavaScript src="menu_array.js" type=text/javascript></script>
<script language=JavaScript src="mmenu.js" type=text/javascript></script>
<noscript>Your browser does not recognize javascript or you have javascript disabled in your browser, so the javascript-based menus used to navigate this site will not function.  Please <a href="noscript_page.html">click here</a> to go to a page with non-javascript navigation for this site.</noscript>

You would replace "noscript_page.html" with a url to a navigation page where you have standard links to the main pages in your site. The user would click that link to go to a page that they could navigate your site from. Alternatively, you could place all of the appropriate links in the noscript block itself, but then it might be a large set of links and you might have difficulty placing it so that they are well integrated into your normal page layout; using a separate page might be a better way to go.

Hope that helps,

Kevin


Poster: gregorr
Dated: Tuesday May 13 2003 - 6:32:33 BST

Sounds like just what I was afraid of... I need 2 of every page on every site so I can accomadate .JS enabled browsers AND non-.JS enabled browsers to see every page.

Worse, the noscript pages need to be edits one at a time seprately to change tyhe menu onm them as there is no central menu to edit once for all pages on the site as Milonic does.


Poster: kevin3442
Dated: Tuesday May 13 2003 - 20:47:41 BST

Hi Gregorr,

Quote:
I need 2 of every page

Well... I didn't say that you'd need two of every page. You certainly could do it that way, but I think you only really need one additional page; sort of a site map. You might even want one of those anyway; people who could use the menus might find it useful, people who can't use the menus (noscript) would use it to navigate, and it would allow web crawling search engines to spider your site more completely (if the menus are the only navigation you have, I think most spiders will not find most of you pages, because most of them do not read js). You might place a link or button at the bottom of each page that goes to your site map page, then use the noscript tag to inform the non-script people that they should use the "Site Map" link or button at the bottom of each page to navigate.

Quote:
Worse, the noscript pages need to be edits one at a time seprately to change tyhe menu onm them as there is no central menu to edit once for all pages on the site as Milonic does.

I'm not sure what you mean here. You can certainly have one central menu for your site; that's how most people use the Milonic Menus. Maybe I misunderstood your point.

Kevin


Poster: gregorr
Dated: Wednesday May 14 2003 - 8:34:52 BST

I meant if text nav menus were on every page then every time there was a change I'd have to edit each page. This is what I wanted to get away from with the Milonic menus.

You are right though that if only the front page has full text nav menus then folks w/o JS support would have to hit BACK to nav the whole site but at least they (and the search engines) could still see everything, though not as easily! I assume non-JS browsers are (very much?) in the minority, but still, who wants to ignore ANY part of the population!


Poster: kevin3442
Dated: Wednesday May 14 2003 - 19:39:53 BST

I wouldn't even put the full text on the front page; it might mess up the layout that your probably work hard to achieve. I'd just provide a link to the text-only nav page. Then they could use their Back button to get back to it, or you could also use a noscript tag at the bottom of every page to provide a link to the text-only nav page for those few who do not or will not have js support.

Kevin