예제 #1
0
파일: setfun.php 프로젝트: novnan/meiju
function SetSafe($add, $userid, $username)
{
    global $ecms_config;
    $r[do_loginauth] = $add[loginauth];
    $r[do_ecookiernd] = $add[ecookiernd];
    $r[do_ckhloginip] = (int) $add[ckhloginip];
    $r[do_ckhsession] = (int) $add[ckhsession];
    $r[do_ckhanytime] = (int) $add[ckhanytime];
    $r[do_theloginlog] = (int) $add[theloginlog];
    $r[do_thedolog] = (int) $add[thedolog];
    $r[do_ckfromurl] = (int) $add[ckfromurl];
    $r[do_ckhash] = (int) $add[ckhash];
    $r[phome_cookiedomain] = $add[cookiedomain];
    $r[phome_cookiepath] = $add[cookiepath];
    $r[phome_cookievarpre] = $add[cookievarpre];
    $r[phome_cookieadminvarpre] = $add[cookieadminvarpre];
    $r[phome_cookieckrnd] = $add[cookieckrnd];
    $r[phome_cookieckrndtwo] = $add[cookieckrndtwo];
    //原来设置
    $r[efw_open] = $ecms_config['fw']['eopen'];
    $r[efw_pass] = $ecms_config['fw']['epass'];
    $r[efw_adminloginurl] = $ecms_config['fw']['adminloginurl'];
    $r[efw_adminhour] = $ecms_config['fw']['adminhour'];
    $r[efw_adminweek] = $ecms_config['fw']['adminweek'];
    $r[efw_adminckpassvar] = $ecms_config['fw']['adminckpassvar'];
    $r[efw_adminckpassval] = $ecms_config['fw']['adminckpassval'];
    $r[efw_cleargettext] = $ecms_config['fw']['cleargettext'];
    $string = ReturnSettingString($r);
    GetSettingConfig($string);
    //操作日志
    insert_dolog('');
    if ($ecms_config['esafe']['ecookiernd'] != $r[do_ecookiernd] || $ecms_config['cks']['ckadminvarpre'] != $r[phome_cookieadminvarpre] || $ecms_config['esafe']['ckhanytime'] != $r[do_ckhanytime]) {
        printerror('SetSafeSuccessLogin', '../index.php');
    }
    printerror('SetSafeSuccess', 'SetSafe.php' . hReturnEcmsHashStrHref2(1));
}
예제 #2
0
function SetSafe($add, $userid, $username)
{
    global $efw_open, $efw_pass, $efw_adminloginurl, $efw_adminhour, $efw_adminweek, $efw_adminckpassvar, $efw_adminckpassval, $efw_cleargettext, $do_ecookiernd, $phome_cookieadminvarpre;
    $r[do_loginauth] = $add[loginauth];
    $r[do_ecookiernd] = $add[ecookiernd];
    $r[do_ckhloginfile] = (int) $add[ckhloginfile];
    $r[do_ckhloginip] = (int) $add[ckhloginip];
    $r[do_theloginlog] = (int) $add[theloginlog];
    $r[do_thedolog] = (int) $add[thedolog];
    $r[phome_cookiedomain] = $add[cookiedomain];
    $r[phome_cookiepath] = $add[cookiepath];
    $r[phome_cookievarpre] = $add[cookievarpre];
    $r[phome_cookieadminvarpre] = $add[cookieadminvarpre];
    $r[phome_cookieckrnd] = $add[cookieckrnd];
    //原来设置
    $r[efw_open] = $efw_open;
    $r[efw_pass] = $efw_pass;
    $r[efw_adminloginurl] = $efw_adminloginurl;
    $r[efw_adminhour] = $efw_adminhour;
    $r[efw_adminweek] = $efw_adminweek;
    $r[efw_adminckpassvar] = $efw_adminckpassvar;
    $r[efw_adminckpassval] = $efw_adminckpassval;
    $r[efw_cleargettext] = $efw_cleargettext;
    $string = ReturnSettingString($r);
    GetSettingConfig($string);
    //操作日志
    insert_dolog('');
    if ($do_ecookiernd != $r[do_ecookiernd] || $phome_cookieadminvarpre != $r[phome_cookieadminvarpre]) {
        printerror('SetSafeSuccessLogin', '../index.php');
    }
    printerror('SetSafeSuccess', 'SetSafe.php');
}