On node form validate JS isn't added

Created on 13 April 2018, about 6 years ago
Updated 7 February 2023, over 1 year ago

On node validate JS isn't added.
I suggest adding:

function node_edit_protection_node_validate($node, $form, &$form_state) {
if(isset($form['#node_edit_form'])) {
drupal_add_js(drupal_get_path('module', 'node_edit_protection') . '/node-edit-protection.js');
}
}
This should fix it.

Or adding a $form['#after_build'] function, like suggested here:
https://www.drupal.org/forum/support/post-installation/2011-08-18/add-js... β†’

πŸ› Bug report
Status

Closed: outdated

Version

1.1

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States fcortez

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.69.0 2024