This topic has 9 replies, 2 voices, and was last updated 8 years, 6 months ago ago by Jack Richardson
Hi, how do I edit the shortcodes.php so I can record the telephone no. for the person and so that information is sent to me in the confirmation email please?
I have attempted to edit it by changing the website section from line 249 to 254 but it does not send me the captured telephone no.
Many thanks
Hello,
You need also edit the file wp-content/themes/royal/framework/theme-functions.php (the section “! Send message from contact form”).
Best regards,
Jack Richardson.
Hi, I edited as you suggested with the following:
}
if(trim($_GET[‘contact-telephone’]) === ” || !isValidEmail($_GET[‘contact-telephone’])) {
$error_email = true;
} else{
$email = trim($_GET[‘contact-telephone’]);
}
and it shortcodes.php with :
<div class=”form-group”>
<p class=”form-name”>
<label for=”contact-telephone” class=”control-label”><?php _e(‘Telephone’, ETHEME_DOMAIN) ?> <span class=”required”>*</span></label>
<input type=”text” name=”contact-telephone” class=”form-control” id=”contact-telephone”>
</p>
</div>
but the contact form will now give an error “(‘Please, fill in the required fields!’
what have I missed?
thanks
Hello,
Please provide us with FTP credentials in private content.
Best regards,
Jack Richardson.
ok, please find details in private area
Hello,
I’ve edited theme-functions.php file and changed the line 1401 to $website = stripslashes(trim($_GET['contact-telephone']));
and line 1415 to $body .= " and contact on phone at $website" . PHP_EOL . PHP_EOL;
.
Please check form now.
Best regards,
Jack Richardson.
Hi – cannot access the site at all now – just a white screen – would this be something to do with the changes you have made?
Hi – I have had this message from hosting co: When trting to access the site now we get:
Parse error: syntax error, unexpected ‘=>’ (T_DOUBLE_ARROW) in /home/linweb40/f/fitterstronger.org/user/htdocs/wp-content/themes/royal/framework/theme-functions.php on line 2270
Can you help with this please asap?
Many thanks
Hello,
The issue has been fixed.
Please check.
Best regards,
Jack Richardson.
You must be logged in to reply to this topic.Log in/Sign up