javascript - On [for="description"]' click not working -


jsfiddle

i trying if label has attribute for="description" on click should focus other element.

i have tried following not working. possible click event on attribute. or other can possibilities achieve this? other adding class or id.

$('[for="description"]').on('click', function() {     console.log('test');     alert('test'); }); 

you have typo in click event keyword. should lowercase. code:

$('[for="description"]').on('click', function () {     alert('test'); }); 

otherwise, have not define element class name nicedit-main.

demo


Comments

Popular posts from this blog

python - No exponential form of the z-axis in matplotlib-3D-plots -

excel vba - VBA Proxy auto-configuration for http requests -

php - phpWord - Tables with borders in headers/footers -