is there anyway i could trigger a change event on select box on page load and select a particular option.
Also the function executed by adding the trigger after bin
To select an option, use .val('value-of-the-option')
on the select element. To trigger the change element, use .change()
or .trigger('change')
.
The problems in your code are the comma instead of the dot in $('.check'),trigger('change');
and the fact that you call it before binding the event handler.
Give links in value of the option tag
<select size="1" name="links" onchange="window.location.href=this.value;">
<option value="http://www.google.com">Google</option>
<option value="http://www.yahoo.com">Yahoo</option>
</select>