By sylvaingirard on
I got this:
$form['isvrij'] = array(
'#title' => t('Heeft nu vrije plaats'),
'#type' => 'checkbox',
'#attributes' => array('onclick'=>'$("#edit-vrijvanaf-datepicker-popup-0").text();')
);
which is sent to the client as:
onclick="$("#edit-vrijvanaf-datepicker-popup-0").text();"
Is it possible to disable html encoding or escape not-to-be-encoded characters in form declarations?
Comments
Why?
Why is that a problem? & " and ' should be escaped in attribute values. If not, your onclick attribute context would suddenly end before #edit-vrij.
Right, it should be single
Right, it should be single quotes, which don't close the attribute value.
The reason I was looking for this was that the js wasn't doing what it was supposed to do. But that was another problem.
Thanks