In this tutorial i want to show you how you can create age verification popup with multi-tool to create popups in e-commerce pages based on PrestaShop engine. This tool is called PopUp Pro - and at the moment it is the most popular and powerful addon to create responsive popup box in your online store.
Why age verification?
In some countries it is necessary to display age verification window on website, especially when website contains adult materials (cigarettes, alcohol etc.). So if you're online store owner and if you sell adult stuff to meet law requirements you have to create age verification tool. It's more than necessary from law point of view.
How to create age verification window?
As I already mentioned i will show how to achieve it with PopUp pro module to create responsive modal popups. So, please install addon and go to module configuration page. On module configuration page please open "add new popup" section where you can define popup specification. Exactly as i show on image below.
Popup pro module configuration page
Age verification Popup Configuration
Now it's time to next step. Please fill out all necessary fields like name, active, test mode etc. The most important part is a section where we will display buttons to accept / decline notification about age restriction. It's a code of the popup. To create popup like here (click to see image) you have to use configuration:
Name | Age Verification |
Active | Yes |
Test Mode | No (optionally YES when you want to test it) |
Display again | 36000000 |
Popup Border | 5 |
Popup border color | FF7575 |
Popup background | FFFFFF |
Overlay backgrund | 000000 |
Overlay opacity | 0.8 |
Disable "close" | YES |
Disable "click anywhere" | YES |
And the most important part, the code. please use it in "desktop view" code, but you can also use it for other devices (tablet and mobile)
Width | 600 |
Height | 300 |
<h1 style="text-align: center;"><span style="color: #ff0000; background-color: #ffffff;"><strong>Adult content - access restricted</strong></span></h1> <h2 style="text-align: center;">Please confirm that you're over 18<br />or leave the website<br /><br /></h2> <div> <table style="width: 600px; text-align: center; margin-left: auto; margin-right: auto;"> <tbody> <tr> <td style="text-align: center;"><a style="width: 130px; text-align: center;" class="button lnk_view btn btn-default" onclick="hideThisPopup();"><span>I'm over 18</span></a></td> <td style="text-align: center;"><a style="width: 130px; text-align: center;" class="button lnk_view btn btn-default" href="http://mypresta.eu"><span>Exit</span></a></td> </tr> </tbody> </table> </div>
And that's all! Your page will have not age veriification popup with feature to remember selection, close popup (if user is over 18) or exit the website )if user is not over 18). Of course you can define own content and own different buttons. For example, you can add own fancy images, backgrunds, even add sounds etc. It's because of extended tinyMCE editor that allows to add everything to popup window! You can see video of the popup below.