Why wont my form submit???


ive tried cant form submit?

 

this comes when hit 'submit'

 

fatal error: call undefined function isinjected() in /websites/123reg/linuxpackage23/cl/oc/kd/clockdoctors.co.uk/public_html/memorials/estimate -to-email.php on line 42

 

but why?

 

 

http://www.milesmemorials.com/estimator.html

 

<?php

if(array_key_exists('catwebformbutton', $_post))

{

$cat_custom_76922 = $_post['cat_custom_76922'];

$cat_custom_00000 = $_post['cat_custom_00000'];

$cat_custom_76926 = $_post['cat_custom_76926'];

$cat_custom_76924 = $_post['cat_custom_76924'];

$cat_custom_76927 = $_post['cat_custom_76927'];

$total = $_post['total'];

$cat_custom_76928 = $_post['cat_custom_76928'];

$cat_custom_76930 = $_post['cat_custom_76930'];

$cat_custom_76923 = $_post['cat_custom_76923'];

$cat_custom_00006 = $_post['cat_custom_00006'];

$cat_custom_00003 = $_post['cat_custom_00003'];

$cat_custom_76929 = $_post['cat_custom_76929'];

$total_crem_disbursements = $_post['total_crem_disbursements'];

$cat_custom_76928 = $_post['cat_custom_76928'];

$cat_custom_76931 = $_post['cat_custom_76931'];

$cat_custom_00005 = $_post['cat_custom_00005'];

$cat_custom_00001 = $_post['cat_custom_00001'];

$cat_custom_00004 = $_post['cat_custom_00004'];

$total_burial_disbursements = $_post['total_burial_disbursements'];

$grand_total = $_post['grand_total'];

$firstname = $_post['firstname'];

$lastname = $_post['lastname'];

$emailaddress = $_post['emailaddress'];

$homeaddress = $_post['homeaddress'];

$homecity = $_post['homecity'];

$homestate = $_post['homestate'];

$homezip = $_post['homezip'];

$homecountry = $_post['homecountry'];

$homephone = $_post['homephone'];

$cellphone = $_post['cellphone'];

 

 

 

 

//validate first

if(empty($total)||empty($grand_total)||empty($firstname)||empty($lastname)||empty($emailad dress)||empty($homeaddress)||empty($homecity)||empty($homestate)||empty($homezip)||empty($ homecountry)||empty($homephone)||empty($cellphone))

{

    echo "please make sure fields filled in!";

    exit;

}

if(isinjected($emailaddress))

 

 

 

 

{

    echo "bad email value!";

    exit;

}

 

 

$email_from = 'milesmemorials.com';//<== update email address

$email_subject = "estimate m&d website";

$email_body .= "name: $firstname.\n";

$email_body .= "surname: $lastname.\n";

$email_body .= "address: $homeaddress.\n";

$email_body .= "city: $homecity.\n";

$email_body .= "county: $homestate.\n";

$email_body .= "postcode: $homezip.\n";

$email_body .= "country: $homecountry.\n";

$email_body .= "phone: $homephone.\n";

$email_body .= "mob: $cellphone.\n";

$email_body .= "removal milage: $cat_custom_76922.\n";

$email_body .= "viewing: $cat_custom_00000.\n";

$email_body .= "coffin: $cat_custom_76926.\n";

$email_body .= "route: $cat_custom_76924.\n";

$email_body .= "limousines: $cat_custom_76927.\n";

$email_body .= "sub funeral cost: $total.\n";

$email_body .= "cremation: $cat_custom_76928.\n";

$email_body .= "cremation fees: $cat_custom_76930.\n";

$email_body .= "carry in night before: $cat_custom_76923.\n";

$email_body .= "venue service: $cat_custom_00006.\n";

$email_body .= "minister fees: $cat_custom_00003.\n";

$email_body .= "doctors fees: $cat_custom_76929.\n";

$email_body .= "total cremation disbursements: $total_crem_disbursements.\n";

$email_body .= "burial: $cat_custom_76928.\n";

$email_body .= "cemetery fees: $cat_custom_76931.\n";

$email_body .= "carry in night before: $cat_custom_00005.\n";

$email_body .= "venue service: $cat_custom_00001.\n";

$email_body .= "minister fees: $cat_custom_00004.\n";

$email_body .= "total burial disbursements: $total_burial_disbursements.\n";

$email_body .= "total funeral cost: $grand_total.\n";

 

 

 

$to = "ness_rob@yahoo.com";//<== update email address

$headers = 'from: '.$emailaddress."\r\n";

$headers .='reply-to:'.$emailaddress."\r\n";

//send email!

mail($to,$email_subject,$email_body,$headers);

//done.  redirect payment page.

header('location: thankyou_estimate.html');

 

 

// function validate against email injection attempts

function isinjected($str)

{

  $injections = array('(\n+)',

              '(\r+)',

              '(\t+)',

              '(%0a+)',

              '(%0d+)',

              '(%08+)',

              '(%09+)'

              );

  $inject = join('|', $injections);

  $inject = "/$inject/i";

  if(preg_match($inject,$str))

    {

    return true;

  }

  else

    {

    return false;

}

 

}

}

 

?>

first, fix page. thw w3c validator finds 41 errors, 103 warnings. may not directly problem here, but, if have stuff throwing errors on page, form may not function correctly.



More discussions in Dreamweaver support forum


adobe

Comments

Popular posts from this blog

Upgrade 3.4.8 to 3.5.1 failed "download package failed" - Joomla! Forum - community, help and support

Joomal 3.6.3 update error - PHP temporary folder is not set - Joomla! Forum - community, help and support

Fatal error during instalation - Joomla! Forum - community, help and support