[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now


Javascript Validation

Posted on 2004-09-22
Medium Priority
Last Modified: 2009-12-16
I need to insert another form field named "pAccessLevel" and the user can only enter the values '1' or '0'. What is the javascript for that?

My current code is as follows:

function validForm()
      var Frm, pass;              
         Frm = document.AdminListUser;
      pass = true;

      if (IsEmptyField(Frm.pUserName.value) )
            alert("Please enter User ID.");
            pass = false;
      else if (IsEmptyField(Frm.pName.value) )
            alert("Please enter Name.");
            pass = false;

etc. etc....
Question by:zamorin
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
LVL 49

Accepted Solution

Roonaan earned 500 total points
ID: 12120933
<select name="pAccesslevel">
 <option value="0">0</option>
 <option value="1">1</option>



Author Comment

ID: 12120943
O.K, that was silly.

Let me try it, I'll get back to you soon.

Author Comment

ID: 12120965
works like a dream!

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to write a Context Sensitive Help (an online help that is obtained from a specific point in state of software to provide help with that state) ,  first we need to make the file that contains all topics, which are given exclusive IDs. …
FAQ pages provide a simple way for you to supply and for customers to find answers to the most common questions about your company. Here are six reasons why your company website should have a FAQ page
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.
Suggested Courses

650 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