Oxid v.4.7.6 re: application-views-azure-tpl-form-fieldset-user_billing.tpl
Registration Page
My objective is to have a single input box for both street number and street as is customary in the US.
Have made the following changes within the user_billing.tpl:
<li [{if $aErrors.oxuser__oxstreet}]class="oxInValid"[{/if}]>
<label [{if $oView->isFieldRequired(oxuser__oxstreet)}]class="req"[{/if}]>[{ oxmultilang ident="FORM_FIELDSET_USER_BILLING_STREETANDSTREETNO" }]</label>
<!-- <input [{if $oView->isFieldRequired(oxuser__oxstreetnr) }]class=“js-oxValidate js-oxValidate_notEmpty” [{/if}]type=“text” data-fieldsize=“xsmall” maxlength=“16” name=“invadr[oxuser__oxstreetnr]” value="[{if isset( $invadr.oxuser__oxstreetnr ) }][{ $invadr.oxuser__oxstreetnr }][{else }][{ $oxcmp_user->oxuser__oxstreetnr->value }][{/if}]"> -->
<input [{if $oView->isFieldRequired(oxuser__oxstreet) }]class=“js-oxValidate js-oxValidate_notEmpty” [{/if}]type=“text” data-fieldsize=“pair-xsmall” maxlength=“255” name=“invadr[oxuser__oxstreet]” value="[{if isset( $invadr.oxuser__oxstreet ) }][{ $invadr.oxuser__oxstreet }][{else }][{ $oxcmp_user->oxuser__oxstreet->value }][{/if}]">
[{if $oView->isFieldRequired(oxuser__oxstreet) }]
<p class="oxValidateError">
<span class="js-oxError_notEmpty">[{ oxmultilang ident="EXCEPTION_INPUT_NOTALLFIELDS" }]</span>
[{include file="message/inputvalidation.tpl" aErrors=$aErrors.oxuser__oxstreet}]
</p>
[{/if}]
</li>
Then the following error message appears during registration:
“Specify a value for this required field.”
Which field it refers to is not specified.
How can I get it to validate?
Thank you,
Ray
Oxid v.4.7.6 CE re: application-views-azure-tpl-form-fieldset-user_billing.tpl
Registration Page
Finally made some sense out of the code for Registration page. I have it in usable form for now. Changes I wish I was smart enough to make include: 1) Eliminate Country entry, 2) Have state drop down independent of Country entry. 3) Enter State input between City and zip code line. and 4) Fix spacing in Birthday input.
Also required some changes in my egazure cust_lang.php and azure’s map.php file all at github/rmighty1.
You are free to use this code as I modified from Oxid at your own risk.
[{assign var="invadr" value=$oView->getInvoiceAddress()}]
[{assign var="blBirthdayRequired" value=$oView->isFieldRequired(oxuser__oxbirthdate)}]
[{if isset( $invadr.oxuser__oxbirthdate.month ) }]
[{assign var="iBirthdayMonth" value=$invadr.oxuser__oxbirthdate.month }]
[{elseif $oxcmp_user->oxuser__oxbirthdate->value && $oxcmp_user->oxuser__oxbirthdate->value != "00-00-0000" }]
[{assign var="iBirthdayMonth" value=$oxcmp_user->oxuser__oxbirthdate->value|regex_replace:"/^([0-9]{4})[-]/":""|regex_replace:"/[-]([0-9]{1,2})$/":"" }]
[{else}]
[{assign var="iBirthdayMonth" value=0}]
[{/if}]
[{if isset( $invadr.oxuser__oxbirthdate.day ) }]
[{assign var="iBirthdayDay" value=$invadr.oxuser__oxbirthdate.day}]
[{elseif $oxcmp_user->oxuser__oxbirthdate->value && $oxcmp_user->oxuser__oxbirthdate->value != "00-00-0000"}]
[{assign var="iBirthdayDay" value=$oxcmp_user->oxuser__oxbirthdate->value|regex_replace:"/^([0-9]{4})[-]([0-9]{1,2})[-]/":"" }]
[{else}]
[{assign var="iBirthdayDay" value=0}]
[{/if}]
[{if isset( $invadr.oxuser__oxbirthdate.year ) }]
[{assign var="iBirthdayYear" value=$invadr.oxuser__oxbirthdate.year }]
[{elseif $oxcmp_user->oxuser__oxbirthdate->value && $oxcmp_user->oxuser__oxbirthdate->value != "00-00-0000" }]
[{assign var="iBirthdayYear" value=$oxcmp_user->oxuser__oxbirthdate->value|regex_replace:"/[-]([0-9]{1,2})[-]([0-9]{1,2})$/":"" }]
This file has been truncated. show original
Cheers,
Ray
hey cool - thanks for sharing!
Hey Hebsacker, thanks for showing appreciation. I appreciate your appreciation!
Silly me, I probably should have included a link to the registration page so folks could see it first before decided to go through the effort of making those changes.
Here is the Pseudo-Americanized Registration page link: http://eldergems.com/en/open-account/
Cheers,
Ray
[QUOTE=RMIGHTY1;127726]I appreciate your appreciation![/QUOTE]
[QUOTE=RMIGHTY1;127726]I probably should have included a link to the registration page s[/QUOTE]
already found it
Great Hebsacker!
I have since made some necessary changes to the “Shipping Address” if it is different from the Billing Address.
After I run the site for awhile to see what I have missed, I will add these files to my github site and post here.
Cheers Hebsacker,
Ray