- Timestamp:
- 2011/01/28 16:19:40 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/version-2_5-dev/data/class/pages/entry/LC_Page_Entry.php
r19995 r20041 38 38 /** フォームパラメータの配列 */ 39 39 var $objFormParam; 40 41 40 41 42 42 // }}} 43 43 // {{{ functions … … 54 54 $this->arrJob = $masterData->getMasterData("mtb_job"); 55 55 $this->arrReminder = $masterData->getMasterData("mtb_reminder"); 56 56 57 57 // 生年月日選択肢の取得 58 58 $objDate = new SC_Date(START_BIRTH_YEAR, date("Y",strtotime("now"))); … … 60 60 $this->arrMonth = $objDate->getMonth(true); 61 61 $this->arrDay = $objDate->getDay(true); 62 62 63 63 $this->httpCacheControl('nocache'); 64 64 65 65 $this->isMobile = Net_UserAgent_Mobile::isMobile(); 66 66 } … … 68 68 /** 69 69 * Page のプロセス. 70 * 70 * 71 71 * @return void 72 72 */ … … 75 75 $this->sendResponse(); 76 76 } 77 77 78 78 /* パラメータ情報の初期化 */ 79 79 function lfInitParam() { 80 80 81 81 $this->objFormParam->addParam("お名前(姓)", 'name01', STEXT_LEN, "aKV", array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" ,"MAX_LENGTH_CHECK")); 82 82 $this->objFormParam->addParam("お名前(名)", 'name02', STEXT_LEN, "aKV", array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" , "MAX_LENGTH_CHECK")); … … 100 100 $this->objFormParam->addParam("日", "day", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false); 101 101 $this->objFormParam->addParam("メールマガジン", "mailmaga_flg", INT_LEN, "n", array("EXIST_CHECK", "NUM_CHECK")); 102 102 103 103 if ($this->isMobile === false){ 104 104 $this->objFormParam->addParam("FAX番号1", 'fax01', TEL_ITEM_LEN, "n", array("SPTAB_CHECK")); … … 125 125 // PC時は規約ページからの遷移でなければエラー画面へ遷移する 126 126 $this->lfCheckReferer(); 127 127 128 128 // mobile用(戻るボタンでの遷移かどうかを判定) 129 129 if (!empty($_POST["return"])) { 130 130 $_POST["mode"] = "return"; 131 131 } 132 132 133 133 // パラメータ管理クラス,パラメータ情報の初期化 134 134 $this->objFormParam = new SC_FormParam(); … … 137 137 138 138 if ($_SERVER["REQUEST_METHOD"] == "POST") { 139 139 140 140 //CSRF対策 141 141 if (!SC_Helper_Session_Ex::isValidToken()) { 142 142 SC_Utils_Ex::sfDispSiteError(PAGE_ERROR, "", true); 143 143 } 144 144 145 145 $this->objFormParam->convParam(); 146 146 $this->objFormParam->toLower('email'); 147 147 $this->objFormParam->toLower('email02'); 148 148 $this->arrForm = $this->objFormParam->getHashArray(); 149 149 150 150 //-- 確認 151 if ($ _POST["mode"]== "confirm") {151 if ($this->getMode() == "confirm") { 152 152 153 153 $this->arrErr = $this->lfErrorCheck(); 154 154 155 155 // 入力エラーなし 156 156 if(count($this->arrErr) == 0) { 157 157 158 158 $this->list_data = $this->objFormParam->getHashArray(); 159 159 160 160 //パスワード表示 161 161 $passlen = strlen($this->arrForm['password']); 162 162 $this->passlen = SC_Utils_Ex::lfPassLen($passlen); 163 163 164 164 $this->tpl_mainpage = 'entry/confirm.tpl'; 165 165 $this->tpl_title = '会員登録(確認ページ)'; 166 166 } 167 167 168 } elseif ($ _POST["mode"]== "complete") {168 } elseif ($this->getMode() == "complete") { 169 169 //-- 会員登録と完了画面 170 170 171 171 // 会員情報の登録 172 172 $this->CONF = $CONF; … … 182 182 SC_Response_Ex::sendRedirect('complete.php', array("ci" => $customer_id)); 183 183 exit; 184 184 185 185 } 186 186 } … … 202 202 // 会員情報の登録 203 203 function lfRegistData() { 204 204 205 205 $objQuery = new SC_Query(); 206 206 $arrRet = $this->objFormParam->getHashArray(); 207 207 $sqlval = $this->objFormParam->getDbArray(); 208 208 209 209 // 登録データの作成 210 210 $sqlval['birth'] = SC_Utils_Ex::sfGetTimestamp($arrRet['year'], $arrRet['month'], $arrRet['day']); … … 216 216 $count = $objQuery->count("dtb_customer", "secret_key = ?", array($uniqid)); 217 217 } 218 218 219 219 // 仮会員登録の場合 220 220 if(CUSTOMER_CONFIRM_MAIL == true) { … … 242 242 SC_Helper_Customer_Ex::sfEditCustomerData($sqlval); 243 243 $objQuery->commit(); 244 244 245 245 return $uniqid; 246 246 } 247 247 248 248 function lfSendMail(){ 249 249 // 完了メール送信 … … 305 305 $objErr->doFunc(array("FAX番号", "fax01", "fax02", "fax03") ,array("TEL_CHECK")); 306 306 } 307 307 308 308 // 現会員の判定 → 現会員もしくは仮登録中は、メアド一意が前提になってるので同じメアドで登録不可 309 309 $register_user_flg = SC_Helper_Customer_Ex::sfCheckRegisterUserFromEmail($arrRet["email"]); … … 320 320 return $objErr->arrErr; 321 321 } 322 322 323 323 function lfCheckReferer(){ 324 324 /** 325 325 * 規約ページからの遷移でなければエラー画面へ遷移する 326 */ 326 */ 327 327 if ($this->isMobile === FALSE 328 328 && empty($_POST)
Note: See TracChangeset
for help on using the changeset viewer.
