Jump to content

Lastname Optional


fioxx

Recommended Posts

Hi, I have a problem with prestashop 1.6, I want disable the lastname required in the registration form. How can I do it?

P.s. Excuse me for my English, but I'm Italian and I can't speak English very well.

Thanks,

Filippo Mereu.

Link to comment
Share on other sites

Try removing required => true from the address.php class file. It should work. Then do the same for the customer class

Yes, i do it. But it is not enough.

I modified on the MySql the table ps_customer, I have changed the field "Null" from No to Yes. It work!

In the file authenthication.tpl, I have delete "required" and "is_required validate", from the lines of lastname.

Thank you!

Edited by fioxx (see edit history)
Link to comment
Share on other sites

  • 6 years later...

In order to remove this required field
Edit these files

  1. Address.php
  2. Custome.php
  3. AddressFormat.php

And remove the required flag

its better to do an override and not touch the core

also it is better to put some random data inside these as it is the core, and maybe some services are using this field. so removing it may result into unnecessary development

Edited by Ali Samie (see edit history)
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...