This topic has 10 replies, 3 voices, and was last updated 8 years, 6 months ago ago by Jack Richardson
Hi,
I am not able to validate the e-mail field in the Blanco theme’s contact form. User can write anything in the field even other then the e-mail address. Is there a way I can
Hello,
Please provide us with FTP and wp-admin panel credentials in Private Content.
Regards,
Eva Kemp.
I need to take permission from the client before sending the Production Site Credentials. Will it work if I send you the details of our beta site rather then the production site? Which is the clone of the production site.
http://obaststenv.in/cms
username : admin
Password : admin
Hello,
In this case edit the file wp-content/themes/blanco/code/shortcodes.php and after line 125 add this code:
if (!filter_var($email, FILTER_VALIDATE_EMAIL)) {
$emailErr = "Invalid email format";
return $emailErr;
}
Regards,
Eva Kemp.
I edited the file in our beta site as per your instruction, but it didn’t work.
I used wp-admin to edit Blanco: shortcodes.php (code/shortcodes.php).
you an please check it here. http://obaststenv.in/cms/contact-us/
Hello,
Please provide us with FTP credentials.
Regards,
Eva Kemp.
FTP details are in private section
Hello,
Please take our apologies for delay.
I’ve added the following code in the wp-content/themes/blanco-3/js/script.js file in lines 338-344:
ethemeContactForm.find('.email').each(function(){
var re = /[A-Z0-9._%+-]+@[A-Z0-9.-]+.[A-Z]{2,4}/igm;
if (jQuery(this).val() == '' || !re.test(jQuery(this).val())) {
errmsg = "Please, enter a valid e-mail address!";
jQuery(this).addClass('validation-failed');
}
});
Clear browser cache and check the contact form now.
Best regards,
Jack Richardson.
thanks Jack, Fix is working.
Do you have intention to include it in your next version upgrade? Otherwise, with next version upgrade, our fix may get over-written.
Hello,
You’re welcome.
We passed this query to our developers.
It should be fixed in the next theme update.
Best regards,
Jack Richardson.
Tagged: best selling, contact form, email validation, seo friendly, themes, woocommerce
You must be logged in to reply to this topic.Log in/Sign up