jquery not working

milano

New Member
I am trying to alert when someone presses the submit button and when the option is "Text 3". My code isn't working here:Html:\[code\]<select id="some"> <option value="http://stackoverflow.com/questions/15585070/1">Text 1</option> <option value="http://stackoverflow.com/questions/15585070/2">Text 2</option> <option value="http://stackoverflow.com/questions/15585070/3">Text 3</option> </select><input type="submit" id="Submit" value="http://stackoverflow.com/questions/15585070/Submit"/>\[/code\]Jquery:\[code\]$(document).ready(function(){ $("#submit").click(function(); { var some = $("#some").val(); if (some == Text 3) { alert("Hello"); } }}\[/code\]
 
Back
Top