Solved

Relational Select Menu

Posted on 1998-08-18
2
189 Views
Last Modified: 2008-03-17
http://members.home.net:80/kerrie/insurance/index.html

I'm sort of confused with this relational thang!

I need to alert if user selects an article but no month "Select month"...  

I have succeeded with a alert if user selects no article (SelectMenu.SelectPrimary) but am getting confused with working with (SelectMenu.SelectSecondary).

As always, thanks for the advice...Kerrie
0
Comment
Question by:kerrie
2 Comments
 
LVL 8

Accepted Solution

by:
jbirk earned 50 total points
Comment Utility
OK, here is the corrected code.  I'm just changing the function changePage():

function changePage()
{
 menuNum = document.SelectMenu.SelectPrimary.selectedIndex;
 if (menuNum == 0)
  {alert("Please select a category from the menu.");
   document.SelectMenu.SelectPrimary.focus();
   return;
  }
 else
  {i = document.SelectMenu.SelectSecondary.selectedIndex;
   if (i==0)
     {alert("Please select a month from the menu.");
      document.SelectMenu.SelectSecondary.focus();
      return;
    }
   else
    window.location.href = url[i];
  }
}

That should od it for you!
-Josh
0
 

Author Comment

by:kerrie
Comment Utility
Thank you so much - sorry the code was such a mess.  Have a great night... Kerrie
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

This article will give core knowledge of JavaScript and will head in to your first JavaScript program. I am Durvesh Naik and I am here to deal with this series of JavaScript. I will teach you JavaScript in part wise , as its quite boring to read big…
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now