From last few days i am facing strange issue, i cant login to frontend ONLY, using login snippet in IE10 and safari, Its working fine in FF and Chrome. It keeps redirecting to "returnUrl" field set in login chunk which is actually same page you know. Below is the simple snippet call i am using
[[!Login? &loginTpl=`multiloginT` &logoutTpl=`redirectendT` &rememberMeKey=`rememberme`]]
After googling for some time, i found something similar to my problem but that didnt worked for me, I am posting it here just in case it helps someone.
https://forums.modx.com/thread/76169/intermittent-ie-login-problem
Whats is strange ?
Instead of relying only on login snippet, i tried to login using runProcessor, and thats where i get stunned.
if($_POST){
$response = $modx->runProcessor('security/login', array(
'username' => $_POST['username'],
'password' => $_POST['password'],
));
print_r($response->response)."<br>";
echo "Logged User Id:".$modx->getLoginUserId();
}
Above code returns strange output as below
Array (
[success] => 1
[message] =>
[total] => 0
[errors] => Array ( )
[object] => Array (
[url] =>
[token] => modx51c448f4ca15f3.04843443_1052931305c07533.32607283
)
)
Logged User Id:0
Print_r line says that i am successfully logged in ([success] => 1) and on the next line it says i am not logged in (0).