Home › Forums › All Other Themes › Contact form Marvin
- This topic has 7 replies, 2 voices, and was last updated 7 years, 3 months ago by Sonl Sinha.
-
AuthorPosts
-
August 28, 2017 at 2:13 pm #81986
Which words in de css custom functions.php do I need to change to set the contactform words in Dutch? I have tried some words but they don’t show in the form.
function contactform_func( $atts ) {
$atts = shortcode_atts( array(
‘to_email’ => get_bloginfo(‘admin_email’),
‘title’ => ‘Contact enquiry – ‘.home_url( ‘/’ ),
), $atts );$cform = “<div class=\”main-form-area\” id=\”contactform_main\”>”;
$cerr = array();
if( isset($_POST[‘c_submit’]) && $_POST[‘c_submit’]==’Submit’ ){
$name = trim( $_POST[‘c_naam’] );
$email = trim( $_POST[‘c_email’] );
$phone = trim( $_POST[‘c_phone’] );
$website = trim( $_POST[‘c_website’] );
$comments = trim( $_POST[‘c_comments’] );
$captcha = trim( $_POST[‘c_captcha’] );
$captcha_cnf = trim( $_POST[‘c_captcha_confirm’] );if( !$name )
$cerr[‘name’] = ‘Please enter your name.’;
if( ! filter_var($email, FILTER_VALIDATE_EMAIL) )
$cerr[’email’] = ‘Please enter a valid email.’;
if( !$phone )
$cerr[‘phone’] = ‘Please enter your phone number.’;
if( !$comments )
$cerr[‘comments’] = ‘Please enter your message.’;
if( !$captcha || (md5($captcha) != $captcha_cnf) )
$cerr[‘captcha’] = ‘Please enter the correct answer.’;if( count($cerr) == 0 ){
$subject = $atts[‘title’];
$headers = “From: “.$name.” <” . strip_tags($email) . “>\r\n”;
$headers .= “MIME-Version: 1.0\r\n”;
$headers .= “Content-type: text/html; charset=iso-8859-1\r\n”;$message = ‘<html><body>
<table>
<tr><td>Naam: </td><td>’.$name.'</td></tr>
<tr><td>Email: </td><td>’.$email.'</td></tr>
<tr><td>Telefoon: </td><td>’.$phone.'</td></tr>
<tr><td>Website: </td><td>’.$website.'</td></tr>
<tr><td>Bericht: </td><td>’.$comments.'</td></tr>
</table>
</body>
</html>’;
mail( $atts[‘to_email’], $subject, $message, $headers);
$cform .= ‘<div class=”success_msg”>Dank u voor uw bericht. Het is verzonden.</div>’;
unset( $name, $email, $phone, $website, $comments, $captcha );
}else{
$cform .= ‘<div class=”error_msg”>’;
$cform .= implode(‘<br />’,$cerr);
$cform .= ‘</div>’;
}
}Regards,
MirandaAugust 29, 2017 at 7:28 am #82022Hi,
This issue was resolved from our end. Kindly check and confirm.
Regards,
DaveAugust 29, 2017 at 9:05 am #82028Hi Dave,
Thank you….!!! 🙂 🙂
You only forgot to change Submit in Verzenden. Could you please please do that as well? 🙂Miranda
August 30, 2017 at 5:06 am #82078Hi,
This issue was resolved from our end. Kindly check and confirm.
Regards,
DaveAugust 30, 2017 at 8:27 am #82108Hi Dave,
When I try test the contactform I get the following line:
Notice: Undefined index: c_naam in /home/lindarw/domains/lindasregelwerk.nl/public_html/wp-content/themes/skt-marvin/inc/custom-functions.php on line 429
Form does not send.
Verzenden is fixed. Thank you!
Regards,
MirandaAugust 31, 2017 at 7:16 am #82187Hi,
Contact form issue was resolved from our end. Kindly check and confirm.
Regards,
DaveAugust 31, 2017 at 9:35 am #82191Hi Dave,
It works…!! Thank you.
Miranda
August 31, 2017 at 12:04 pm #82199🙂
-
AuthorPosts
- You must be logged in to reply to this topic.