views:

517

answers:

1

I have a select form, with a few option values, and I want the page to reload when someone selects another option value, without having a submit button that is. Just reload the page when someone change the value. I would like to skip fetching the data with an AJAX request. So the idea here is to call a HTTP-request when the option value is changed. I thought jQuery would be a nice way to do this, but maybe there's another way.

So the question is;

How do I call a HTTP request in the event of someone changing the value in a select form without a submit-button?

+3  A: 
$('#selectId').change( function(){
  document.location.href = '/newUrl';
});
redsquare
Thank you sir! That worked perfeclty.
Stefan Konno