till wrote:
On Feb 6, 2008 9:47 PM, daniel@nullroutes.com daniel@nullroutes.com wrote:
(...) I don't suppose anyone could help me locate the required section of code so I can edit.
In trunk: http://trac.roundcube.net/browser/trunk/roundcubemail/index.php#L173
The code has pretty good inline documentation and since we feed *everything* through index.php - that's the place to look at. I am not sure which version you run, so you may have to "translate" line 173 to your's.
Hope that helps! Till
Hi Till
Thanks so much for your reply .. however could I ask for some further help please.
Would I change this line (173 on index.php)
else { $OUTPUT->show_message($IMAP->error_code == -1 ? 'imaperror' : 'loginfailed', 'warning'); rcmail_kill_session(); }
To
else { $OUTPUT->show_message($IMAP->error_code == -1 ? 'imaperror' : 'loginfailed', 'warning'); http://www.myloginpage.com rcmail_kill_session(); }
I'm not too sure on PHP .. any help would be appreciated!
Thanks
Dan _______________________________________________ List info: http://lists.roundcube.net/users/
daniel@nullroutes.com wrote:
till wrote:
On Feb 6, 2008 9:47 PM, daniel@nullroutes.com daniel@nullroutes.com wrote:
(...) I don't suppose anyone could help me locate the required section of code so I can edit.
In trunk: http://trac.roundcube.net/browser/trunk/roundcubemail/index.php#L173
The code has pretty good inline documentation and since we feed *everything* through index.php - that's the place to look at. I am not sure which version you run, so you may have to "translate" line 173 to your's.
Hope that helps! Till
Hi Till
Thanks so much for your reply .. however could I ask for some further help please.
Would I change this line (173 on index.php)
else { $OUTPUT->show_message($IMAP->error_code == -1 ? 'imaperror' : 'loginfailed', 'warning'); rcmail_kill_session(); }
To
else { $OUTPUT->show_message($IMAP->error_code == -1 ? 'imaperror' : 'loginfailed', 'warning'); http://www.myloginpage.com rcmail_kill_session(); }
I'm not too sure on PHP .. any help would be appreciated!
Thanks
Dan _______________________________________________ List info: http://lists.roundcube.net/users/
Update:
I managed to add this
else { header("Location:http://myloginsite.com"); $OUTPUT->show_message($IMAP->error_code == -1 ? 'imaperror' : 'loginfailed', 'warning'); rcmail_kill_session(); } }
So now it redirects back perfect - however it doesn't display the error .. eg "login failed" etc.
Any ideas?
Thanks
List info: http://lists.roundcube.net/users/
daniel@nullroutes.com wrote:
I managed to add this
else { header("Location:http://myloginsite.com"); $OUTPUT->show_message($IMAP->error_code == -1 ? 'imaperror' : 'loginfailed', 'warning'); rcmail_kill_session(); } }
I'd suggest to call rcmail_kill_session(); before redirecting. This will remove all the garbage and reset some vars that are assigned to the session cookie.
So now it redirects back perfect - however it doesn't display the error .. eg "login failed" etc.
Of course it does not display the message because the browser leaves RoundCube and goes to a complete new site. In order to show some message you need to code it on your loginsite and pass some parameter when redirecting there:
header("Location: http://myloginsite.com?loginerror=1");
~Thomas _______________________________________________ List info: http://lists.roundcube.net/users/