- Timestamp:
- 2011/01/20 03:03:24 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/version-2_5-dev/data/class/helper/SC_Helper_Customer.php
r19986 r19995 93 93 $array["update_date"] = "now()"; // 更新日 94 94 95 //-- パスワードの更新がある場合は暗号化 96 $salt = ""; 97 if ($array["password"] != DEFAULT_PASSWORD) { 95 // salt値の生成(insert時)または取得(update時)。 96 if(is_numeric($customer_id)) { 97 $salt = $objQuery->get("salt", "dtb_customer", "customer_id = ? ", array($customer_id)); 98 }else{ 98 99 $salt = SC_Utils_Ex::sfGetRandomString(10); 99 100 $array["salt"] = $salt; 101 } 102 //-- パスワードの更新がある場合は暗号化 103 if ($array["password"] == DEFAULT_PASSWORD or $array["password"] == "") { 104 //更新しない 105 unset($array["password"]); 106 } else { 100 107 $array["password"] = SC_Utils_Ex::sfGetHashString($array["password"], $salt); 101 } else { 102 unset($array["password"]); 103 } 104 if ($array["reminder_answer"] != DEFAULT_PASSWORD) { 105 if(is_numeric($customer_id) and $salt == "") { 106 $salt = $objQuery->get("salt", "dtb_customer", "customer_id = ? ", array($array['customer_id'])); 107 } 108 } 109 //-- 秘密の質問の更新がある場合は暗号化 110 if ($array["reminder_answer"] == DEFAULT_PASSWORD or $array["reminder_answer"] == "") { 111 //更新しない 112 unset($array["reminder_answer"]); 113 } else { 108 114 $array["reminder_answer"] = SC_Utils_Ex::sfGetHashString($array["reminder_answer"], $salt); 109 115 } 110 116 111 117 //-- 編集登録実行 112 118 if (is_numeric($customer_id)){ … … 164 170 * @return integer 0:登録可能 1:登録済み 2:再登録制限期間内削除ユーザー 3:自分のアドレス 165 171 */ 166 function lfCheckRegisterUserFromEmail($email){172 function sfCheckRegisterUserFromEmail($email){ 167 173 $return = 0; 168 174
Note: See TracChangeset
for help on using the changeset viewer.
