Authored by whb

找回密码

@@ -6,7 +6,7 @@ @@ -6,7 +6,7 @@
6 <div class="send-tips"><i class="iconfont">&#xe61e;</i>我们已经把验证邮件发送至您的邮箱,请在24小时内通过邮件内的<br>链接继续设置新的密码。</div> 6 <div class="send-tips"><i class="iconfont">&#xe61e;</i>我们已经把验证邮件发送至您的邮箱,请在24小时内通过邮件内的<br>链接继续设置新的密码。</div>
7 <div class="no-find">没有收到?到您邮箱的垃圾邮件里找找。</div> 7 <div class="no-find">没有收到?到您邮箱的垃圾邮件里找找。</div>
8 <div class="to-my-email"> 8 <div class="to-my-email">
9 - <a href="http://mail.qq.com" target="_blank" class="btn_b_ar_r">去我的邮箱&gt;</a> 9 + <a href="{{email}}" target="_blank" class="btn_b_ar_r">去我的邮箱&gt;</a>
10 </div> 10 </div>
11 11
12 </div> 12 </div>
@@ -20,7 +20,7 @@ class BackController extends WebAction { @@ -20,7 +20,7 @@ class BackController extends WebAction {
20 'coverImg' => $banner ['img'], 20 'coverImg' => $banner ['img'],
21 'countryCode' => '86', 21 'countryCode' => '86',
22 'countryName' => '中国', 22 'countryName' => '中国',
23 - 'captchaUrl' => '/passport/images?t=1449799445', 23 + 'captchaUrl' => SITE_MAIN.'/passport/images?t=1449799445',
24 'countryList' => RegData::getAreasData() 24 'countryList' => RegData::getAreasData()
25 ) 25 )
26 ); 26 );
@@ -34,7 +34,7 @@ class BackController extends WebAction { @@ -34,7 +34,7 @@ class BackController extends WebAction {
34 { 34 {
35 $phoneNum = $this->post('phoneNum', ''); 35 $phoneNum = $this->post('phoneNum', '');
36 $area = intval($this->post('area', '86')); 36 $area = intval($this->post('area', '86'));
37 - $verifyCode = $this->post('verifyCode', ''); 37 + $verifyCode = $this->post('verifyCode', '');//图形验证码
38 $data = array( 38 $data = array(
39 'code' => 200, 39 'code' => 200,
40 'message' => '验证成功' 40 'message' => '验证成功'
@@ -66,7 +66,7 @@ class BackController extends WebAction { @@ -66,7 +66,7 @@ class BackController extends WebAction {
66 public function emailAction() { 66 public function emailAction() {
67 $phoneNum = $this->post ('phoneNum', ''); 67 $phoneNum = $this->post ('phoneNum', '');
68 $area = intval ($this->post('area', '86')); 68 $area = intval ($this->post('area', '86'));
69 - $verifyCode = $this->post('verifyCode', ''); 69 + $verifyCode = $this->post('verifyCode', '');//图形验证码
70 if (Helpers::verifyEmail($phoneNum)) { // 验证邮箱 70 if (Helpers::verifyEmail($phoneNum)) { // 验证邮箱
71 $email = $phoneNum; 71 $email = $phoneNum;
72 $data = BackData::sendCodeToEmail($email); 72 $data = BackData::sendCodeToEmail($email);
@@ -100,7 +100,7 @@ class BackController extends WebAction { @@ -100,7 +100,7 @@ class BackController extends WebAction {
100 { 100 {
101 $mobile = $this->post ('mobile', ''); 101 $mobile = $this->post ('mobile', '');
102 $area = intval ($this->post( 'area', '86' )); 102 $area = intval ($this->post( 'area', '86' ));
103 - $verifyCode = $this->post ('verifyCode', ''); 103 + $verifyCode = $this->post ('verifyCode', '');//图形验证码
104 $data = array('code' => 400, 'message' =>'验证失败'); 104 $data = array('code' => 400, 'message' =>'验证失败');
105 if(Helpers::verifyMobile($mobile) && PassportModel::verifyCode($verifyCode)) { // 验证手机号 105 if(Helpers::verifyMobile($mobile) && PassportModel::verifyCode($verifyCode)) { // 验证手机号
106 $data = BackData::sendCodeToMobile($mobile, $area); 106 $data = BackData::sendCodeToMobile($mobile, $area);
@@ -117,12 +117,21 @@ class BackController extends WebAction { @@ -117,12 +117,21 @@ class BackController extends WebAction {
117 $this->redirect ('index'); 117 $this->redirect ('index');
118 } 118 }
119 $banner = PassportModel::getLeftBanner(PassportModel::BACK_LFFT_BANNER_CODE); 119 $banner = PassportModel::getLeftBanner(PassportModel::BACK_LFFT_BANNER_CODE);
  120 + $emailArr = explode('@', $email);
  121 + $emailUrl = '';//邮箱地址
  122 + $emailUrls = array('yoho.cn' =>'http://smail.yoho.cn');
  123 + if(in_array($emailArr[1], $emailUrls)){
  124 + $emailUrl = $emailUrls[$emailArr[1]];//邮箱后缀
  125 + } else {
  126 + $emailUrl = 'http://mail.'.$emailArr[1];
  127 + }
120 $data = array ( 128 $data = array (
121 'simpleHeader' => PassportModel::getSimpleHeader(false), 129 'simpleHeader' => PassportModel::getSimpleHeader(false),
122 'sendEmail' => array ( 130 'sendEmail' => array (
123 'coverHref' => $banner ['url'], 131 'coverHref' => $banner ['url'],
124 'coverImg' => $banner ['img'], 132 'coverImg' => $banner ['img'],
125 - 'countrys' => array () 133 + 'countrys' => array (),
  134 + 'email' => $emailUrl
126 ) 135 )
127 ); 136 );
128 $this->_view->display('send-email', $data); 137 $this->_view->display('send-email', $data);
@@ -133,7 +142,7 @@ class BackController extends WebAction { @@ -133,7 +142,7 @@ class BackController extends WebAction {
133 */ 142 */
134 public function backcodeAction() 143 public function backcodeAction()
135 { 144 {
136 - $code = $this->get('code'); 145 + $code = $this->get('code');//加密code兼容以前参数
137 $info = $this->checkCode($code); 146 $info = $this->checkCode($code);
138 $verifyState = false;//验证状态 147 $verifyState = false;//验证状态
139 $ret = array(); 148 $ret = array();
@@ -172,7 +181,7 @@ class BackController extends WebAction { @@ -172,7 +181,7 @@ class BackController extends WebAction {
172 */ 181 */
173 public function updateAction() 182 public function updateAction()
174 { 183 {
175 - $code = $this->post('code'); 184 + $code = $this->post('code');//加密code兼容以前参数
176 $password = $this->post('pwd'); 185 $password = $this->post('pwd');
177 $info = $this->checkCode($code); 186 $info = $this->checkCode($code);
178 if (Helpers::verifyPassword ($password)) { 187 if (Helpers::verifyPassword ($password)) {
@@ -224,7 +233,7 @@ class BackController extends WebAction { @@ -224,7 +233,7 @@ class BackController extends WebAction {
224 { 233 {
225 $mobile = $this->getSession ('mobile'); 234 $mobile = $this->getSession ('mobile');
226 $area = $this->getSession ('area'); 235 $area = $this->getSession ('area');
227 - $verifyCode = $this->getSession ('verifyCode'); 236 + $verifyCode = $this->getSession ('verifyCode');//图形验证码
228 if (empty ($mobile)) { 237 if (empty ($mobile)) {
229 $this->redirect ('index'); 238 $this->redirect ('index');
230 } 239 }
@@ -251,8 +260,8 @@ class BackController extends WebAction { @@ -251,8 +260,8 @@ class BackController extends WebAction {
251 { 260 {
252 $mobile = $this->post ( 'mobile' ); 261 $mobile = $this->post ( 'mobile' );
253 $area = $this->post ( 'area' ); 262 $area = $this->post ( 'area' );
254 - $verifyCode = $this->post ( 'verifyCode' );  
255 - $code = $this->post ( 'code' ); // code 263 + $verifyCode = $this->post ( 'verifyCode' );//图形验证码
  264 + $code = $this->post ( 'code' ); //手机验证码
256 $data = array('code'=> 400, 'message' => '验证码错误!','data' => SITE_MAIN.'/passport/back/index'); 265 $data = array('code'=> 400, 'message' => '验证码错误!','data' => SITE_MAIN.'/passport/back/index');
257 if ($this->getSession ( 'mobile' ) == $mobile && $this->getSession ( 'area' ) == $area && ! empty($code)) { 266 if ($this->getSession ( 'mobile' ) == $mobile && $this->getSession ( 'area' ) == $area && ! empty($code)) {
258 $result = BackData::validateMobileCode ( $mobile, $code, $area ); 267 $result = BackData::validateMobileCode ( $mobile, $code, $area );
@@ -19,13 +19,13 @@ class RegisterController extends WebAction @@ -19,13 +19,13 @@ class RegisterController extends WebAction
19 'registerPage' => true, 19 'registerPage' => true,
20 'simpleHeader' => PassportModel::getSimpleHeader(false), 20 'simpleHeader' => PassportModel::getSimpleHeader(false),
21 'passport' => array( 21 'passport' => array(
22 - 'actionUrl' => '/passport/register/mobileregister', 22 + 'actionUrl' => SITE_MAIN.'/passport/register/mobileregister',
23 'region' => RegData::getAreasData(), 23 'region' => RegData::getAreasData(),
24 'location' => '+86', 24 'location' => '+86',
25 - 'captchaUrl' => '/passport/images?t=1449799445', 25 + 'captchaUrl' => SITE_MAIN.'/passport/images?t=1449799445',
26 'itemUrl' => 'http://www.yohobuy.com/help/?category_id=9', 26 'itemUrl' => 'http://www.yohobuy.com/help/?category_id=9',
27 'referUrl' => $refer, 27 'referUrl' => $refer,
28 - 'loginUrl' => '/signin.html?refer='.$refer, 28 + 'loginUrl' => SITE_MAIN.'/signin.html?refer='.$refer,
29 'coverHref' => $cover['url'], 29 'coverHref' => $cover['url'],
30 'coverImg' => $cover['img'], 30 'coverImg' => $cover['img'],
31 'regBtnText' => '立即注册' 31 'regBtnText' => '立即注册'
@@ -185,7 +185,7 @@ class RegisterController extends WebAction @@ -185,7 +185,7 @@ class RegisterController extends WebAction
185 $verifyCode = strtolower(trim($this->post('verifyCode'),' '));//图形验证码 185 $verifyCode = strtolower(trim($this->post('verifyCode'),' '));//图形验证码
186 $code = trim($this->post('code'),'');//code 186 $code = trim($this->post('code'),'');//code
187 $password = $this->post('password'); 187 $password = $this->post('password');
188 - $url = '/passport/register/index'; 188 + $url = SITE_MAIN.'/passport/register/index';
189 $refer = $this->getCookie('refer'); 189 $refer = $this->getCookie('refer');
190 $data = array('code' => 400, 'message' => '', 'data' => ''); 190 $data = array('code' => 400, 'message' => '', 'data' => '');
191 if(!empty($refer)) { 191 if(!empty($refer)) {