| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
Tidy up registration | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||
|
|||||||
Tidy up registration
I had complaints about having to fill in your name too many times on registration etc. So heres the code to clean it up, see link below to see how it looks.
http://www.qvsdirect.com/reg_x-cart.jpg THIS HAS BEEN DONE FOR VERSION 4.014 1. <xcart_dir>/skin1/main/register_billing_address.tpl: replace {if $default_fields.title.avail eq 'Y'} <TR> <TD align="right">{$lng.lbl_title}</TD> <TD>{if $default_fields.title.required eq 'Y'}<FONT class="Star">*</FONT>{else} {/if}</TD> <TD nowrap> <SELECT name="b_title"> {section name=title loop=$name_titles} <OPTION {if $userinfo.b_title eq $name_titles[title]}selected{/if}>{$name_titles[title]}</OPTION> {/section} </SELECT> </TD> </TR> {/if} {if $default_fields.firstname.avail eq 'Y'} <TR> <TD align="right">{$lng.lbl_first_name}</TD> <TD>{if $default_fields.firstname.required eq 'Y'}<FONT class="Star">*</FONT>{else} {/if}</TD> <TD nowrap> <INPUT type="text" name="b_firstname" size="32" maxlength="32" value="{$userinfo.b_firstname}"> {if $reg_error ne "" and $userinfo.b_firstname eq "" && $default_fields.firstname.required eq 'Y'}<FONT class="Star"><<</FONT>{/if} </TD> </TR> {/if} {if $default_fields.lastname.avail eq 'Y'} <TR> <TD align="right">{$lng.lbl_last_name}</TD> <TD>{if $default_fields.lastname.required eq 'Y'}<FONT class="Star">*</FONT>{else} {/if}</TD> <TD nowrap> <INPUT type="text" name="b_lastname" size="32" maxlength="32" value="{$userinfo.b_lastname}"> {if $reg_error ne "" and $userinfo.b_lastname eq "" && $default_fields.lastname.required eq 'Y'}<FONT class="Star"><<</FONT>{/if} </TD> </TR> {/if} with <input type="hidden" name="b_title" value=""> <input type="hidden" name="b_firstname" value=""> <input type="hidden" name="b_lastname" value=""> and replace <TR> <TD height="20" colspan="3"><B>{$lng.lbl_billing_address}</B><HR size="1" noshade></TD> </TR> with {if $action ne 'cart'} <TR> <TD height="20" colspan="3"><B>{$lng.lbl_billing_address}</B><HR size="1" noshade></TD> </TR> {/if} 2. <xcart_dir>/skin1/customer/main/register.tpl: find the following line: function check_registerform_fields() {ldelim} and insert the code below after that line {if $default_fields.title.avail eq 'Y' and $action eq 'cart'} document.registerform.b_title.value = document.registerform.title.value; {/if} {if $default_fields.firstname.avail eq 'Y' and $action eq 'cart'} document.registerform.b_firstname.value = document.registerform.firstname.value; {/if} {if $default_fields.lastname.avail eq 'Y' and $action eq 'cart'} document.registerform.b_lastname.value = document.registerform.lastname.value; {/if} Hope it helps a few people.
__________________
xcart version 4.1.6 UK - Brighton QVS ELECTRICAL SUPPLIES - http://www.qvsdirect.com We supply a huge range of cables, electrical accessories, heating, ventilation, fire and security products, consumer units & circuit distribution, indoor and outdoor lighting, showers and water heating, tools and fixings, timer switches, sockets, switches, air conditioning, trunking, and much much more. |
|||||||
#2
|
|||||||
|
|||||||
Re: Tidy up registration
works great on 4.0.12 as well.
Good mod QVS!
__________________
Quiet please... I'm trying to unscramble my brian. http://lizzybug.co.uk (live, minor mods, 4.0.15) EZCheckout/EZUpsell (Must have mods!) Firetank's Featured Products Manager, and loads of little mods off the forum (thanks all!) http://www.jellybeangifts.co.uk (live, 4.0.18 ) Fancy Cats + custom colour mod |
|||||||
#3
|
|||||||||
|
|||||||||
Re: Tidy up registration
That is great! It got rid of forcing the customer to input their names twice. I always thought that unprofessional, but could never find an easy fix. Thanks!!!!
__________________
Mary Lee ------------------- Dinner and a Murder Mystery Games http://www.dinnerandamurder.com x-cart version 4.7.5 / Mac OS 10.10.5 and Windows 8/10 sometimes - Ideal Responsive Template |
|||||||||
#4
|
|||||||
|
|||||||
Re: Tidy up registration
Looked great, exactly what I've been looking for. Unfortunatly when customer goes to register it errors out with message stating required information missing?
__________________
Lew |
|||||||
|
|||
X-Cart forums © 2001-2020
|