Author Topic: Account maintenance  (Read 1356 times)

kessels1234

  • Jr. Member
  • **
  • Posts: 208
Account maintenance
« on: August 05, 2010, 14:36:50 pm »
Hi,

We've made some modifications to our VM install. Maybe someone has an answer to this:

In account maintenance we only want the customer to edit their password. In account.billing.tpl.php we have this code to only show the passwords fields:

Code: [Select]
foreach( $fields as $field ) {
if( $field->name != 'password' && $field->name != 'password2' )
$skip_fields[] = $field->name;

}

The rest of the file is original.

The problem is that this doesn't update the passwords and a popup warns: please enter your name. After testing it seems that it is looking for some required field because if I change the code to:

Code: [Select]
foreach( $fields as $field ) {
if( $field->name != 'password' && $field->name != 'password2' && $field->name != 'first_name' )
$skip_fields[] = $field->name;

}

The popup says: give your emailaddress.

I tried to disable the status required in the backend (user fields) and that didn't work. It's also not possible to set them not to show on account maintanance because I use these field also in the customerinfo in the backend. When I set it to not show on account maintenance it will also not be visible in customerinfo (backend).

I hope someone can help me out and please let me know if more info is needed.

Thanks in advance
Danny