Version 4.1.2
This commit is contained in:
1 parent
3ba79295ee
commit
28bd025b35
1131 files changed
+63658
-20579
No files matched your search
@@ -34,7 +34,7 @@ class _login extends \IPS\Dispatcher\Controller
|
||||
$url = \IPS\Http\Url::internal( "app=core&module=system&controller=login", 'admin', NULL, array(), \IPS\Settings::i()->logins_over_https );
|
||||
if ( isset( \IPS\Request::i()->ref ) )
|
||||
{
|
||||
$url = $url->setQueryString( 'ref', base64_encode( \IPS\Request::i()->ref ) );
|
||||
$url = $url->setQueryString( 'ref', \IPS\Request::i()->ref );
|
||||
}
|
||||
$login = new \IPS\Login( $url );
|
||||
$login->flagOptions = FALSE;
|
||||
@@ -62,14 +62,21 @@ class _login extends \IPS\Dispatcher\Controller
|
||||
$this->log( 'ok' );
|
||||
|
||||
/* Clean out any existing session ID in the URL */
|
||||
$queryString = '';
|
||||
|
||||
$queryString = array();
|
||||
if( isset( \IPS\Request::i()->ref ) )
|
||||
{
|
||||
$queryString = preg_replace( "/adsess=([a-zA-Z0-9]+)(?:&|$)/", '', base64_decode( \IPS\Request::i()->ref ) );
|
||||
$_queryString = array();
|
||||
parse_str( preg_replace( "/adsess=([a-zA-Z0-9]+)(?:&|$)/", '', base64_decode( \IPS\Request::i()->ref ) ), $_queryString );
|
||||
foreach ( $_queryString as $k => $v )
|
||||
{
|
||||
if ( in_array( $k, array( 'app', 'module', 'controller' ) ) )
|
||||
{
|
||||
$queryString[ $k ] = $v;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* Boink */
|
||||
\IPS\Output::i()->redirect( \IPS\Http\Url::internal( $queryString ) );
|
||||
\IPS\Output::i()->redirect( \IPS\Http\Url::internal( http_build_query( $queryString ) ) );
|
||||
}
|
||||
/* Error */
|
||||
else
|
||||
|
||||
Reference in new issue
Block a user