Skip to content

Instantly share code, notes, and snippets.

@maxwellnewage
Created January 14, 2013 14:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maxwellnewage/4530330 to your computer and use it in GitHub Desktop.
Save maxwellnewage/4530330 to your computer and use it in GitHub Desktop.
en base a una seleccion del select option, imprime un mensaje en el div
$().ready(function(){
$("#selector").on('change', function(){
switch($("#selector option:selected").val()) {
case "1":
$("#mensaje").html("buena opcion");
break;
case "2":
$("#mensaje").html("medianamente buena opcion");
break;
case "3":
$("#mensaje").html("mala opcion");
break;
case "4":
$("#mensaje").html("una opcion");
break;
}
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment