mirror of
https://github.com/ACSPRI/queXS
synced 2024-04-02 12:12:16 +00:00
Merging the updated Limesurvey 1.92+ branch of queXS to trunk
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
* other free or open source software licenses.
|
||||
* See COPYRIGHT.php for copyright notices and details.
|
||||
*
|
||||
* $Id: login_check.php 10925 2011-09-02 14:12:02Z c_schmitz $
|
||||
* $Id: login_check.php 12211 2012-01-26 17:02:27Z shnoulle $
|
||||
*/
|
||||
|
||||
|
||||
@@ -51,7 +51,7 @@ if(isset($_GET['user']) && isset($_GET['onepass']))
|
||||
else
|
||||
{
|
||||
//check if user exists in DB
|
||||
$query = "SELECT uid, users_name, password, one_time_pw, dateformat, full_name, htmleditormode FROM ".db_table_name('users')." WHERE users_name=".$connect->qstr($user);
|
||||
$query = "SELECT uid, users_name, password, one_time_pw, dateformat, full_name, htmleditormode, questionselectormode, templateeditormode FROM ".db_table_name('users')." WHERE users_name=".$connect->qstr($user);
|
||||
$ADODB_FETCH_MODE = ADODB_FETCH_ASSOC; //Checked
|
||||
$result = $connect->SelectLimit($query, 1) or safe_die ($query."<br />".$connect->ErrorMsg());
|
||||
if(!$result)
|
||||
@@ -101,6 +101,8 @@ if(isset($_GET['user']) && isset($_GET['onepass']))
|
||||
$_SESSION['loginID'] = $srow['uid'];
|
||||
$_SESSION['dateformat'] = $srow['dateformat'];
|
||||
$_SESSION['htmleditormode'] = $srow['htmleditormode'];
|
||||
$_SESSION['questionselectormode'] = $srow['questionselectormode'];
|
||||
$_SESSION['templateeditormode'] = $srow['templateeditormode'];
|
||||
$_SESSION['full_name'] = $srow['full_name'];
|
||||
GetSessionUserRights($_SESSION['loginID']);
|
||||
|
||||
@@ -181,7 +183,7 @@ if(!isset($_SESSION['loginID']) && $action != "forgotpass" && ($action != "logou
|
||||
|
||||
|
||||
//include("database.php");
|
||||
$sIp = $_SERVER['REMOTE_ADDR'];
|
||||
$sIp = getIPAddress();
|
||||
$query = "SELECT * FROM ".db_table_name('failed_login_attempts'). " WHERE ip='$sIp';";
|
||||
$ADODB_FETCH_MODE = ADODB_FETCH_ASSOC;
|
||||
$result = $connect->query($query) or safe_die ($query."<br />".$connect->ErrorMsg());
|
||||
|
||||
Reference in New Issue
Block a user