Solved

Option form JavaScript issue

Posted on 2010-09-15
1
343 Views
Last Modified: 2012-05-10
Hey all,

I'm having an issue with a select form that calls a modal, based on your selection. I need the first option (Pick a region) to be shown but not selectable. I'm sure its a small fix. It might be helpful for the selection to pop up an alert when clicked. Any help would be great.    
show: function() {
			var value = $("selURL").get("value");
			
			var args = {
				content: $(value),
				width: 925,
				height:455
			};
			VZT.ModalHandler.show(args);
	}

<select id=selURL class="fl" style="padding:6px 8px;height:32px;margin-right:10px;" onchange="VZT.RegionalStoryHandler.show();">
  <option disabled="disabled" selected="selected">Pick a region</option>
  <option value="why_settle" >New York</option>
  <option value="why_settle" >Philidelphia</option>
  <option value="why_settle">Pittsburg</option>
  <option value="why_settle" >Tampa Bay</option>
</select>

<a href="javascript:VZT.RegionalStoryHandler.show();" class="button"><span class="grey"><span><span>Ok</span></span></span></a>

Open in new window

0
Comment
Question by:yando18
1 Comment
 
LVL 75

Accepted Solution

by:
Michel Plungjan earned 250 total points
ID: 33688904

<select id=selURL class="fl" style="padding:6px 8px;height:32px;margin-right:10px;" onchange="VZT.RegionalStoryHandler.show();">
  <option value="" selected="selected">Pick a region</option>

show: function() {
  var value = $("selURL").get("value");
  if (value=="") return;
  var args = {
    content: $(value),
    width: 925,
    height:455
  };
  VZT.ModalHandler.show(args);
}

0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Use these top 10 tips to master the art of email signature design. Create an email signature design that will easily wow recipients, promote your brand and highlight your professionalism.
This article discusses four methods for overlaying images in a container on a web page
In this tutorial viewers will learn how to embed videos in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <video> tag to insert a video. Define the src as the URL of your video; this is similar to …
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

840 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