Tonyy Posted May 19, 2009 Share Posted May 19, 2009 我店铺出售的是虚拟物品,不需要your address啊,而且country那里又不全,我面向的可是全球用户。请问大家应该修改那个文件呢? Link to comment Share on other sites More sharing options...
Tonyy Posted May 19, 2009 Author Share Posted May 19, 2009 找到了,修改theme authentication.tpl 文件我删掉了没用的,但是不能注册啊,总是提示There are 5 errors : 1. country ID is required 2. alias is required 3. address (1) is required 4. postcode is required 5. city is invalid这些都是我删掉的,如何取消这个? Link to comment Share on other sites More sharing options...
Tung Posted May 26, 2009 Share Posted May 26, 2009 问题是他代码里面有写的,country 不全可以加上去的 Link to comment Share on other sites More sharing options...
Don Posted May 28, 2009 Share Posted May 28, 2009 找到了,修改theme authentication.tpl 文件我删掉了没用的,但是不能注册啊,总是提示There are 5 errors : 1. country ID is required 2. alias is required 3. address (1) is required 4. postcode is required 5. city is invalid这些都是我删掉的,如何取消这个? 你删掉的这些只是界面显示的部分.你还需要修改"../authentication.php"line74--line104把控制添加地址的地方注释掉. //$address = new Address(); //$address->id_customer = 1; //$errors = array_unique(array_merge($errors, $address->validateControler())); if (!sizeof($errors)) { $customer->active = 1; if (!$customer->add()) $errors[] = Tools::displayError('an error occurred while creating your account'); else { //$address->id_customer = intval($customer->id); /*if (!$address->add()) $errors[] = Tools::displayError('an error occurred while creating your address'); else { */ if (Mail::Send(intval($cookie->id_lang), 'account', 'Welcome!', array('{firstname}' => $customer->firstname, '{lastname}' => $customer->lastname, '{email}' => $customer->email, '{passwd}' => Tools::getValue('passwd')), $customer->email, $customer->firstname.' '.$customer->lastname)) $smarty->assign('confirmation', 1); $cookie->id_customer = intval($customer->id); $cookie->customer_lastname = $customer->lastname; $cookie->customer_firstname = $customer->firstname; $cookie->passwd = $customer->passwd; $cookie->logged = 1; $cookie->email = $customer->email; Module::hookExec('createAccount', array( '_POST' => $_POST, 'newCustomer' => $customer )); if ($back) Tools::redirect($back); /*}*/ Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now