Advanced Forum alters the CSS ID for the node form, and the node form tag is not found, causing a JS error "Cannot call method 'setAttribute' of undefined".

Rather than add specific support for Advanced Forum it seemed like the best approach might be to simply use jQuery to just both #node_form and the more specific form ID in it's selector - this operates as a fallback for Advanced Forum and perhaps other modules.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Owen Barton’s picture

Status: Needs review » Needs work

The last submitted patch, 2097973-obscureurl-advanced-forum.patch, failed testing.

Sswater Shi’s picture

I meet the same problem and find the same reason.

My solution for reference:

Over "7.x-3.3", file "botcha.recipe.controller.inc", Line 897:

          $("#{$js_form_id},.{$js_form_id}").get(0).setAttribute('action', '{$submit}');
Deciphered’s picture

Issue summary: View changes
Status: Needs work » Needs review
FileSize
1.13 KB
578 bytes

Updated patch and added a tweak to the Comments rule so that it works if AJAX has changed the ID (which it does).