Skip to content

Instantly share code, notes, and snippets.

@chrisjm

chrisjm/gist:852096

Created Mar 3, 2011
Embed
What would you like to do?
function handleOnchange(item) {
if( descriptions[$(item).val()] ) {
$(item).parent().parent().find('.navTitle input').val(descriptions[$(item).val()].title);
$(item).parent().parent().find('.navTarget input').val(descriptions[$(item).val()].uri);
$(item).parent().parent().find('.navTarget input').attr( 'onFocus', 'blur();' );
$(item).parent().parent().find('.navTarget input').attr( 'class', 'disabled' );
} else {
$(item).parent().parent().find('.navTitle input').val('');
$(item).parent().parent().find('.navTarget input').val('');
$(item).parent().parent().find('.navTarget input').attr( 'onFocus', null );
$(item).parent().parent().find('.navTarget input').attr( 'class', '' );
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment