spacer

Webref WebRef   Sitemap · Experts · Tools · Services · Newsletters · About i.com

home / web / dev / menus / nonlive2

Non-live Related Menus

Developer News
Microsoft Shows Off Silverlight 4, IE9 Plans
Metasploit Expands Vulnerability Test Framework
HyperCard Reborn?

Universal Related Popup Menus

Choose a subject:
---> Choose a topic:

Related Select Lists

Choose a subject:
---> Choose a topic:

Changing the related live popups to non-live popups takes one more step. We comment out the "jmp(formName,elementNum)" from the "relate" else clause, to make the left popup non-live for JavaScript 1.0 browsers.

    ...
    aln2=a.length;
    var formNum = getFormNum(formName);
    if (formNum>=0) {
    	formNum++; // reference next form, assume it follows in HTML
    	with (document.forms[formNum].elements[elementNum]) {
    		for (var i=options.length-1;i>0;i--) options[i]=null;
    		for (var i=1;i<aln2;i++) options[i-1]=a[i];
    		options[0].selected=true;
    	}
    }
    } else {
    // jmp(formName,elementNum);
    // commented out to make left menu non-live for js 1.0 browsers
    }
    }

As before, to make the right popup non-live, we simply remove the onChange event from the second SELECT tag.

    <SELECT NAME="m2">
    

With these "non-live" related menus, the left menu changes the right menu for JavaScript 1.1 browsers, but the right one is now not live (removed the onChange from the SELECT tag as in the single non-live menu), users must hit the "Go" button to jump to that page. The left menu is also non-live for JavaScript 1.0 browsers, as we commented out the "jmp(formName,elementNum)" from the "else JavaScript 1.0" clause from the relate function. So to jump to any page within each of these two menus the user must click on the matching Go button.

Comments are welcome

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs

webref The latest from WebReference.com Browse >
Rolling Out Your Own HTML Application Version Control · HTML 5: Client-side Storage · Working with Ajax Server Extensions
Sitemap · Experts · Tools · Services · Email a Colleague · Contact FREE Newsletters 
 The latest from internet.com
Wi-Fi Product Watch, November 2009 · Chip Market Recovering From '08 Collapse · Low-Cost Tools to Kickstart Your New Business

 



Created: Oct. 29, 1997
Revised: July 22, 1999

URL: http://webreference.com/dev/menus/nonlive2.html