Detelin Markov Posted February 15, 2014 Share Posted February 15, 2014 Hi developers, By default presta auto get Fist and Last name for Delivery address from New Customer field. Okay way to show several times same information for clients? I want to make these fields more user friendly. I want to hide FIRST and LAST NAME from delivery address in opc-new-account.tpl (customer view) but in dashboards to have these information in order delivery address - I want to hide fields for customer but not for me - lets they again to be auto filled from New Customers field info. Attach picture if you miss understanding. I try to hide it with div class and css but without success. Suggestions? Link to comment Share on other sites More sharing options...
sanl Posted July 3, 2014 Share Posted July 3, 2014 Your theme/order-opc-new-account.tpl edit: on 182 line you can find: <h3>{l s='Delivery address'}</h3> <p class="required text"><label for="firstname">{l s='First name'} <sup>*</sup></label> <input type="text" class="text" id="firstname" name="firstname" value="{if isset($guestInformations) && $guestInformations.firstname}{$guestInformations.firstname}{/if}" /> </p> {elseif $field_name eq "lastname"} <p class="required text"> <label for="lastname">{l s='Last name'} <sup>*</sup></label> <input type="text" class="text" id="lastname" name="lastname" value="{if isset($guestInformations) && $guestInformations.lastname}{$guestInformations.lastname}{/if}" /> </p> U can delete it or just comment. Link to comment Share on other sites More sharing options...
HaCos Posted September 23, 2014 Share Posted September 23, 2014 Your theme/order-opc-new-account.tpl edit: on 182 line you can find: <h3>{l s='Delivery address'}</h3> <p class="required text"><label for="firstname">{l s='First name'} <sup>*</sup></label> <input type="text" class="text" id="firstname" name="firstname" value="{if isset($guestInformations) && $guestInformations.firstname}{$guestInformations.firstname}{/if}" /> </p> {elseif $field_name eq "lastname"} <p class="required text"> <label for="lastname">{l s='Last name'} <sup>*</sup></label> <input type="text" class="text" id="lastname" name="lastname" value="{if isset($guestInformations) && $guestInformations.lastname}{$guestInformations.lastname}{/if}" /> </p> U can delete it or just comment. If you just delete these lines, you will get an error thats first & last name is missing & required. Even if you remove the validation, the delivery address will have no data saved for the fields (first name, last name). I believe that the proper approach should be to hide the first & last name fields from lines 88 - 98 and update them by the input thats is inserted in the same fields for the delivery address block. Link to comment Share on other sites More sharing options...
Recommended Posts