jQuery issue with HTML indexes -
in html have textarea element id of employment[duties].
when try access element through jquery, ignores it.
i think because of whole input[type='text'] selector jquery has can select specific items within [] brackets.
is there way @ around this?
use escape square brackets:
$('#employment\\[duties\\]') edit: problem doesn't apply in plain javascript, opens other options you:
you can use plain javascript:
document.getelementbyid('employment[duties]')or can define variable
var emp = document.getelementbyid('employment[duties]');, wrap jquery$(emp), use jquery selectors on it.
Comments
Post a Comment