I realize this is NOT the fault of ajax module, but I doubted I'd get much help posting in the legal module issue queue simply because it's turning on ajax that causes the stall out.
So here are the lines of code from legal.module line 260-
$uid = $user->uid;
// Destroy the current session.
session_destroy();
module_invoke_all('user', 'logout', NULL, $user);
// We have to use $GLOBALS to unset a global variable.
$user = user_load(array('uid' => 0));
unset($_REQUEST['destination']);
$signatory = db_fetch_object(db_query_range('SELECT * FROM {users} WHERE uid = %d', $uid, 0, 1));
drupal_goto('legal_accept/' . $signatory->uid . '/' . md5($signatory->name . $signatory->pass . $signatory->login));
break;
So here's the issue. When you turn ajax on the legal module is trying to redirect users who haven't accepted the terms of use to a page where they can simply click 'agree'. However, their use of drupal goto causes and error because the ajax module is trying to do something else and the result is a simple "ajax.module: An unknown error has occurred."
If I use firebug, I see it's trying to run a GET request
GET http://iq2/legal_accept/53419/b6317c3a55eba8fcf169ef3863a75c73
200 OK 554ms
error [XMLHttpRequest { readyState=4, status=200, more...}, "parsererror", undefined]
So my questions would simply be. Is there a better way to adapt the legal module so as to not conflict with how the ajax module is trying to redirect the user to a given page? I could turn off ajax for hte login form, but I'm kinda needing it for another jquery issue.
More bluntly.
What would I have to modify on the ajax or legal module side of things to have the user/login form to remain ajaxy but still redirect to the legal_accept page above?
ANY insights would be appreciated. Thanks
Comments
Comment #1
Xnuiem commentedSubscribing. I have the same issue with a custom module I inherited.
Comment #2
venusrising commentedI too have a similar issue.
Comment #3
sepla commented+1
Comment #4
j_ten_man commentedTry changing
to
Comment #5
brendoncrawford commentedIf somebody supplies a patch for this, I will apply it.
Comment #6
brendoncrawford commented