My jQuery is starting to get unnecessarily long. Is there a way to easily combine these 2 functions. My first thought is to create a custom event out of the key down function. Any solutions or suggestions on what to read up on would be appreciated.
$('th:nth-child(3):first').click(function () {
$('#dtSelect').val(2).change();
});
$('th:nth-child(3):first').keydown(function(event){
if(event.keyCode==13){
$('#dtSelect').val(2).change();
}
});