Closed (fixed)
Project:
Ajaxify Drupal with JQuery Ajax
Version:
7.x-1.6
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
20 Nov 2012 at 22:01 UTC
Updated:
6 Apr 2013 at 04:17 UTC
Hello,
it's me again ^ ^
I get the following error in Chrome, caused by the script file "page--ajax.tpl.php"
Uncaught TypeError: Cannot call method 'replace' of undefined
I remove this script. I no longer error and everything works perfectly. What is this script?
Comments
Comment #1
serjas commentedYou can remove the script .. Its to alter form action incase a validation error comes
Comment #2
serjas commentedComment #3
serjas commentedComment #4
paularmand commentedI got the same error, and removing the script indeed "solves" it.
I have got another issue, which I presume could be linked to the removal of the script however. The issue: when an error is given by a view (only tested views) loading via an ajax link (through this module), it does some strange things to the DOM as from that moment clicking on other ajax-links results in strange behavior (nothing loading, or stuff loading at the wrong place). Is my gut feeling that it's related correct? If so, can this issue be reopened?
Ps1: Can't give any url from the site as it's localhost development for the time being.
Thanks for the module btw, tried to make my own ajax module, and ran into problems... your module is definitely way better ;)
Comment #5
rob c commentedI've added this
if (formAction) {
}
End result now is:
if (formAction) {
formAction = formAction.replace("?ajax=1", "");
$("form").attr('action', formAction);
}
No errors + works with loading form validation. (i really needed that to work, axing the script breaks that)
Hope it helps.
Comment #6
serjas commentedComment #7
serjas commentedComment #8
serjas commentedIssue fixed and committed to 7.x-1.x-dev. Thanks to Rob
Comment #9
serjas commented