hitage Posted May 27, 2013 Share Posted May 27, 2013 First of all, sorry for my english, I'm from spain, and I also created a Post in Spanish forum but seems to be there more activity here ^^ Hi there, I was searching for days, but I can't find something else anymore, so I went there to post my concerns. I'm building my first shop in Prestashop, I bought a theme from Templatemonster, and the case is, my shop is almost 100% a digital shop, so I don't need Addresses or somerhing like this in the account registration. I'll just need something like User - Password - Email and maybe if possible Skype username, but not antything else. The problem is, I found the authentication.tpl and AuthController.php files, and I figured out that authentication is the one that's printing in the webpage the fields, and maybe AuthController the one that's checking for errors on the form. So I was able to "Delete" / "Comment" the Fields I didn't need at all, but when I just click on "Register account" it showed me errors of the fields are not filled (The ones that are no there showing up). I went to AuthController but was almost impossible to me with my PHP knowledge to make it work, I think I'll have to also do something in database if I want to add more fields etc. Can you please, teach me how to do it, if it's possible? Thank you so much! I'm very frustrated atm Link to comment Share on other sites More sharing options...
vekia Posted May 27, 2013 Share Posted May 27, 2013 go to the localization -> countries click on edit icon near the each country you've got available in your store, and edit the: remember that it is necessary to edit it for all available countries in your store 2 Link to comment Share on other sites More sharing options...
hitage Posted May 27, 2013 Author Share Posted May 27, 2013 Hi there, I tried to do what you said, and I still have problems : I just putted there "firstname" but It's still asking for > City, alias, firstname, lastname address(1) I'm doing in same country ofc Link to comment Share on other sites More sharing options...
vekia Posted May 27, 2013 Share Posted May 27, 2013 you should also edit: classes/address.php you've got there: public static $definition = array( 'table' => 'address', 'primary' => 'id_address', 'fields' => array( 'id_customer' => array('type' => self::TYPE_INT, 'validate' => 'isNullOrUnsignedId', 'copy_post' => false), 'id_manufacturer' => array('type' => self::TYPE_INT, 'validate' => 'isNullOrUnsignedId', 'copy_post' => false), 'id_supplier' => array('type' => self::TYPE_INT, 'validate' => 'isNullOrUnsignedId', 'copy_post' => false), 'id_warehouse' => array('type' => self::TYPE_INT, 'validate' => 'isNullOrUnsignedId', 'copy_post' => false), 'id_country' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId', 'required' => true), 'id_state' => array('type' => self::TYPE_INT, 'validate' => 'isNullOrUnsignedId'), 'alias' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName', 'required' => true, 'size' => 32), 'company' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName', 'size' => 64), 'lastname' => array('type' => self::TYPE_STRING, 'validate' => 'isName', 'required' => true, 'size' => 32), 'firstname' => array('type' => self::TYPE_STRING, 'validate' => 'isName', 'required' => true, 'size' => 32), 'vat_number' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName'), 'address1' => array('type' => self::TYPE_STRING, 'validate' => 'isAddress', 'required' => true, 'size' => 128), 'address2' => array('type' => self::TYPE_STRING, 'validate' => 'isAddress', 'size' => 128), 'postcode' => array('type' => self::TYPE_STRING, 'validate' => 'isPostCode', 'size' => 12), 'city' => array('type' => self::TYPE_STRING, 'validate' => 'isCityName', 'required' => true, 'size' => 64), 'other' => array('type' => self::TYPE_STRING, 'validate' => 'isMessage', 'size' => 300), 'phone' => array('type' => self::TYPE_STRING, 'validate' => 'isPhoneNumber', 'size' => 32), 'phone_mobile' => array('type' => self::TYPE_STRING, 'validate' => 'isPhoneNumber', 'size' => 32), 'dni' => array('type' => self::TYPE_STRING, 'validate' => 'isDniLite', 'size' => 16), 'deleted' => array('type' => self::TYPE_BOOL, 'validate' => 'isBool', 'copy_post' => false), 'date_add' => array('type' => self::TYPE_DATE, 'validate' => 'isDateFormat', 'copy_post' => false), 'date_upd' => array('type' => self::TYPE_DATE, 'validate' => 'isDateFormat', 'copy_post' => false), ), ); remove the 'required' => true param from those files which we are talking about before: http://i.imgur.com/x0AFjSI.png and affter changes the effect is: 2 Link to comment Share on other sites More sharing options...
vekia Posted May 27, 2013 Share Posted May 27, 2013 btw. i moved this thread to the correct forum section regards 1 Link to comment Share on other sites More sharing options...
Gamemunchies Posted September 21, 2013 Share Posted September 21, 2013 (edited) I don't have the code you gave in the address.php I only have: <?php /* * 2007-2013 PrestaShop * * NOTICE OF LICENSE * * This source file is subject to the Open Software License (OSL 3.0) * that is bundled with this package in the file LICENSE.txt. * It is also available through the world-wide-web at this URL: * http://opensource.org/licenses/osl-3.0.php * If you did not receive a copy of the license and are unable to * obtain it through the world-wide-web, please send an email * to [email protected] so we can send you a copy immediately. * * DISCLAIMER * * Do not edit or add to this file if you wish to upgrade PrestaShop to newer * versions in the future. If you wish to customize PrestaShop for your * needs please refer to http://www.prestashop.com for more information. * * @author PrestaShop SA <[email protected]> * @copyright 2007-2013 PrestaShop SA * @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) * International Registered Trademark & Property of PrestaShop SA */ /** * This file will be removed in 1.6 * You have to use index.php?controller=page_name instead of this page * * @deprecated 1.5.0 */ require(dirname(__FILE__).'/config/config.inc.php'); Tools::displayFileAsDeprecated(); Tools::redirect('index.php?controller=address'.((count($_GET) || count($_POST)) ? '&'.http_build_query(array_merge($_GET, $_POST), '', '&') : ''), __PS_BASE_URI__, null, 'HTTP/1.1 301 Moved Permanently'); I would like to edit my addres form but I can't figure it out... All I need is: address postalcode city country phone Address title Edited September 21, 2013 by Gamemunchies (see edit history) Link to comment Share on other sites More sharing options...
vekia Posted September 21, 2013 Share Posted September 21, 2013 you have to edit classes/Address.php file, not address.php located in root dir of prestashop 2 Link to comment Share on other sites More sharing options...
El Patron Posted September 21, 2013 Share Posted September 21, 2013 I have a question, are all your products free? If so then removing registration information will not cause problem. If you plan on having customers pay for products, i.e. a PrestaShop payment module, then it's probably going to result in the payment method failing as it needs to pass address and other info to the payment gateway. hope that helps some... 1 Link to comment Share on other sites More sharing options...
Gamemunchies Posted September 22, 2013 Share Posted September 22, 2013 Thanks. It's solved! I overlooked classes . Link to comment Share on other sites More sharing options...
LM Foong Posted November 27, 2013 Share Posted November 27, 2013 Hello, I hope this message receive attention. I also have similar problem which I could not customize the registration form. I have followed instruction i this thread, first modify the "company" to "school" at locationization>country, Then I edited the file at classes/Address.php Nothing seems to change. What am I missing Please advice Link to comment Share on other sites More sharing options...
hurquiza Posted December 4, 2013 Share Posted December 4, 2013 (edited) Cache disabled? If not, please do and refresh the page Edited December 4, 2013 by hurquiza (see edit history) Link to comment Share on other sites More sharing options...
dzoxen Posted December 5, 2013 Share Posted December 5, 2013 Hi, everybody, I'm having a problem with changing "labels" in dropdownlist for months, I need to translate it to Danish, and can't do that in Localizations -> Translations because of "Warning your PHP configuration limits the maximum number of fields in a form 1000 for max_input_vars.Ask your hosting provider to increase this limit to 1490 at least, or edit the translation file manually" error displaying..Help! Thanx Link to comment Share on other sites More sharing options...
hurquiza Posted December 11, 2013 Share Posted December 11, 2013 Do you have access to your server /etc/php.ini file? You can easily edit it there then restart apache and voila Link to comment Share on other sites More sharing options...
vekia Posted December 11, 2013 Share Posted December 11, 2013 Thanks. It's solved! I overlooked classes . so you removed required=> true? 1 Link to comment Share on other sites More sharing options...
vekia Posted December 11, 2013 Share Posted December 11, 2013 Hi, everybody, I'm having a problem with changing "labels" in dropdownlist for months, I need to translate it to Danish, and can't do that in Localizations -> Translations because of "Warning your PHP configuration limits the maximum number of fields in a form 1000 for max_input_vars.Ask your hosting provider to increase this limit to 1490 at least, or edit the translation file manually" error displaying.. Help! Thanx it's not related to this topic. please create new thread, topic closed. Link to comment Share on other sites More sharing options...
Recommended Posts