tracedef Posted August 13, 2015 Share Posted August 13, 2015 We would like to hire someone to create an action hook for the code below that we would like to be posted to viewcart.tpl. The code prevents a user registering for web hosting with a domain like mywebdomain.com from also using an email that uses mywebdomain.com such as tom@mywebdomain.com.... Our server thinks the domain is hosted locally and sends the emails locally, resulting in non-delivery as the client has yet to transfer their DNS to us. We used to simply paste the code at the top of viewcart.tpl, but this means we have to re-paste it everytime we upgrade. <script type="text/javascript"> var domains = new Array(); var products = new Array(); {foreach from=$domains item=array_item key=id} domains['{$id}'] = '{$array_item.domain}'; {/foreach} {foreach from=$products item=array_item key=id} products['{$id}'] = '{$array_item.domain}'; {/foreach} {literal} $(document).ready(function(){ $("#email").blur(function() { if ((jQuery.inArray($('#email').val().toLowerCase().split("@")[1], domains) != "-1") || (jQuery.inArray($('#email').val().toLowerCase().split("@")[1], products) != "-1")) { alert("The email you have chosen uses the same domain name as your website, " + $('#email').val().toLowerCase().split("@")[1] + ". Please use a different email account that is not related to the domain name you will be using with LeadPress."); $('#email').val(''); } }); }); {/literal} </script> 0 Quote Link to comment Share on other sites More sharing options...
lee-wservices Posted August 13, 2015 Share Posted August 13, 2015 (edited) Check out whmcsexpert they have done some for my customers and been great and done well. Edited August 13, 2015 by lee-wservices 0 Quote Link to comment Share on other sites More sharing options...
sentq Posted August 14, 2015 Share Posted August 14, 2015 please send your project requirements here 0 Quote Link to comment Share on other sites More sharing options...
brad Posted August 15, 2015 Share Posted August 15, 2015 You probably shouldn't be putting customers on the same server your WHMCS is on. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.