Jump to content

Remove Date of Birth Field


Recommended Posts

There are several posts about how to remove the Date of Birth field from the information on the user registration form.

 

I'm using 1.6.0.5 and have commented out the DoB code in authentication.tpl, identity.tpl and order-opc-new-account.tpl (though I'm not configured for OPC), where these files are in /themes/mytheme, which is active.

 

I have cleared the cache in Advanced Parameters, Performance and have forced recompilation many times. I've also manually deleted the Smarty cache.

 

I have also cleared my browser cache and tried different browsers.

 

However, Date of Birth still appears in the user registration form.

 

Could anyone suggest a way to remove this field, which works in 1.6.0.5?

 

Many Thanks,

 

Alan

Link to comment
Share on other sites

Thanks for coming back on this issue.

 

Localization, Countries shows Date of Birth as a field that can be included in the Address Format, but I can see no option to include or exclude it from the User Registration process.

 

Where exactly is it being generated?

 

Thanks,

 

Alan

  • Like 1
Link to comment
Share on other sites

You can remove it in authentication.tpl

 

Around line 133 find

					<div class="form-group date-select">
						<label>{l s='Date of Birth'}</label>
						<div class="row">
							<div class="col-xs-8">
								<select id="days" name="days" class="form-control">
									<option value="">-</option>
									{foreach from=$days item=day}
										<option value="{$day}" {if ($sl_day == $day)} selected="selected"{/if}>{$day}  </option>
									{/foreach}
								</select>
								{*
									{l s='January'}
									{l s='February'}
									{l s='March'}
									{l s='April'}
									{l s='May'}
									{l s='June'}
									{l s='July'}
									{l s='August'}
									{l s='September'}
									{l s='October'}
									{l s='November'}
									{l s='December'}
								*}
							</div>
							<div class="col-xs-8">
								<select id="months" name="months" class="form-control">
									<option value="">-</option>
									{foreach from=$months key=k item=month}
										<option value="{$k}" {if ($sl_month == $k)} selected="selected"{/if}>{l s=$month} </option>
									{/foreach}
								</select>
							</div>
							<div class="col-xs-8">
								<select id="years" name="years" class="form-control">
									<option value="">-</option>
									{foreach from=$years item=year}
										<option value="{$year}" {if ($sl_year == $year)} selected="selected"{/if}>{$year}  </option>
									{/foreach}
								</select>
							</div>
						</div>
					</div>

remove this part or comment it out. Then the date of birth field will be gone.

Edited by prestamax (see edit history)
Link to comment
Share on other sites

Thanks for coming back on this - I commented out this code in authentication.tpl, identity.tpl and order-opc-new-account.tpl (though I'm not configured for OPC), where these files are in /themes/mytheme, which is active. I have also tried deleting the code.

 

I have flushed the PrestaShop cache both manually and in the BO interface and recompiled the templates, but the Date of Birth field still appears. I have also flushed my browser cache and tried different browsers.

 

Do you have any ideas on where the Date of Birth field is coming from?

 

Many Thanks,

 

Alan

Link to comment
Share on other sites

I found that the Date of Birth field seems to be coming from code further down in authentication.tpl - I'd commented out the block at line 133, but the code that actually places the field on the page appears to be at line 452.

 

Having commented this out, the Date of Birth field no longer appears.

 

Thanks to the people who came back to me on this.

 

Alan

Link to comment
Share on other sites

  • 1 month later...
  • 1 month later...

I really love Prestashop, however I sometimes wonder if the developers have any experience running an ecommerce operation.

 

One of the Cardinal rules in registration or in checkout, is to collect as little information as possible to complete an order.

 

I was absolutely shocked when I found that Prestashop was asking for birthdates.  I'm not sure what it is like in Europe, but if you ask a women her age in North America, you are most likely going to get slapped on the face.

 

If you must ask for this information, then at least wait until the order Thank You page, as you already have the customers credit card, before you piss them off.

 

It's a minor task, to remove all this superficial crap, however since you are changing core files, it's makes the update process tedious.

 

Prestashop Developers, please get some experts in Ecommerce on your team, and if you insist on adding this fluff, make sure we have the option to disable it in the backoffice

  • Like 6
Link to comment
Share on other sites

@nortonlgn

 

I too don't like the personal information prestashop defaults users to collect.

 

Perhaps in Europe they must have it included because if there isn't a simple "remove button" then they must have it for that or gathering private info on us.

  • Like 1
Link to comment
Share on other sites

  • 1 month later...

I really love Prestashop, however I sometimes wonder if the developers have any experience running an ecommerce operation.

 

One of the Cardinal rules in registration or in checkout, is to collect as little information as possible to complete an order.

 

I was absolutely shocked when I found that Prestashop was asking for birthdates.  I'm not sure what it is like in Europe, but if you ask a women her age in North America, you are most likely going to get slapped on the face.

 

If you must ask for this information, then at least wait until the order Thank You page, as you already have the customers credit card, before you piss them off.

 

It's a minor task, to remove all this superficial crap, however since you are changing core files, it's makes the update process tedious.

 

Prestashop Developers, please get some experts in Ecommerce on your team, and if you insist on adding this fluff, make sure we have the option to disable it in the backoffice

100% agree

 

Just building my first Prestashop and cannot go live because I cannot get rid of those fields.

 

It is serious in the UK, apart from the fact that most visitors will leave the site when they see that there is a risk of failure to comply with the Data Protection Act (exists in most of Europe under different names).

 

Site owners risk heavy fines for keeping this kind of information if they do not register the database on which it is kept.

Many are unaware that however they keep it - even pencil and paper constitutes a database in the opinion of the law.

 

A real trap which Prestashop should deal with urgently.

  • Like 2
Link to comment
Share on other sites

  • 1 month later...

I attempted to remove the date of birth code from identity.tpl and order.opc.newaccount.tpl and it worked but after I tried to process an order to make sure the links worked, I got the white screen of death. Obviously removed something wrong. The website loads fine, its the checkout at https://christianexpressions.com/quick-order

I tried searching for the original coding so I could reinstall but cannot find for the new version.Can someone help?

 

UPDATE: I changed the template compilation and was able to get the checkout page to come up but it won't let me complete the new account. It keeps saying phone # is required (I put a phone # in both boxes) Can someone help me figure out what code I need to put back in?

Edited by jlennon1863 (see edit history)
Link to comment
Share on other sites

I do not know what else you did but in themes/yourdir/authenticate.tpl you need to comment out from about line 134 to 174 so you start

 

{* 
    
<div class="form-group date-select">

 and end

</div>
     
*}

 

I have this on a live site for a customer and it works OK

 

Edward

Link to comment
Share on other sites

  • 2 weeks later...

Hi!

 

Is there a way to remove DOB fields from "Guest Checkout" and keep them in "Create an Account"?

 

So far I found a number of posts suggesting to edit three files. In fact, I managed. However, I would like to have this in an account creating area as it is still valuable bit of data that customers are sometimes wiling to reveal... as they expect birthday vouchers and etc.

 

Any hints?

Link to comment
Share on other sites

×
×
  • Create New...