If the user does not enter a title and submits the node it will fail validation. After the page reloads auto_menutitle.js is not added. After doing some research I discovered this page http://www.appnovation.com/drupaladdjs-and-drupaladdcss-hookformalter-an... which mentions:
"A big change in Drupal 6 was the fact that forms were being cached. So adding CSS files and JS
files in hook_form_alter or hook_form would lead to issues if the form was reloaded after failing validation."
After doing some more searching I found this page which had a solution that seemed to work:
http://drupal.org/node/671574#comment-3061880
I'm not sure if this is the best way to fix the issue but it seems to work. Please review / test the attached patch. The patch was made for 6.x-1.21
| Comment | File | Size | Author |
|---|---|---|---|
| validation.patch | 1.13 KB | gooddesignusa |
Comments
Comment #1
alexkb commentedHi gooddesignusa - nice work on the bug find and patch!
I've committed it to the repo, so it should be available in the -dev release shortly. Once people have tested it a bit, we'll roll it as an official version.
Thanks again!
Comment #2
alexkb commented