kiwi1066 Posted April 4, 2011 Share Posted April 4, 2011 Hi Bit of an odd request, but can anyone tell me how to add a default value to the 'Day' part of the DoB on the Registration form.I don't require the day, but need customers to enter their month and year. I know how to hide the 'Day' field so if I can work out how to set a default value I can leave the rest of the code untouched and get the result I want.Thanks Link to comment Share on other sites More sharing options...
shokinro Posted April 4, 2011 Share Posted April 4, 2011 Please change the code as following in /themes/YourSiteTheme/authentication.tplReplace this code - {foreach from=$days item=day} {$day|escape:'htmlall':'UTF-8'} {/foreach} With this code {foreach from=$days item=day} {$day|escape:'htmlall':'UTF-8'} {/foreach} After change, the day part will be hidden and the default day will be set as 1st day.Hope this works for you Link to comment Share on other sites More sharing options...
kiwi1066 Posted April 4, 2011 Author Share Posted April 4, 2011 Thanks for the quick response, solution worked great. Link to comment Share on other sites More sharing options...
Wingz Posted April 4, 2011 Share Posted April 4, 2011 I was just looking at this from a different perspective - I'd like to reward customers on their brthdays but not have them balk at submitting too much personal information.How would I ask for only the day and month - not the year?I've been looking at this for twenty minutes trying to suss it out for myself but I must be short on coffee. Link to comment Share on other sites More sharing options...
ChrisLNZ Posted April 4, 2011 Share Posted April 4, 2011 I was just looking at this from a different perspective - I'd like to reward customers on their brthdays but not have them balk at submitting too much personal information.How would I ask for only the day and month - not the year?I've been looking at this for twenty minutes trying to suss it out for myself but I must be short on coffee. similar to above:find - {foreach from=$years item=year} {$year|escape:'htmlall':'UTF-8'} {/foreach} and replace with {foreach from=$years item=year} {$year|escape:'htmlall':'UTF-8'} {/foreach} not tested but.... Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now