<?php
if(isset($_POST['email'])) {
// EDIT THE 2 LINES BELOW AS REQUIRED
$email_to = "demo@crunchpress.com";
$email_subject = "New Contact Form Submission";
function died($error) {
// your error code can go here
echo "We are very sorry, but there were error(s) found with the form you submitted. ";
echo "These errors appear below.<br /><br />";
echo $error."<br /><br />";
echo "Please go back and fix these errors.<br /><br />";
die();
}
// print_r($_POST);
// validation expected data exists
if(!isset($_POST['name']) ||
!isset($_POST['email']) ||
!isset($_POST['comments'])) {
died('We are sorry, but there appears to be a problem with the form you submitted.');
}
$first_name = $_POST['name']; // required
$email_from = $_POST['email']; // required
$comments = $_POST['comments']; // required
$error_message = "";
$email_exp = '/^[A-Za-z0-9._%-]+@[A-Za-z0-9.-]+\.[A-Za-z]{2,4}$/';
if(!preg_match($email_exp,$email_from)) {
$error_message .= 'The Email Address you entered does not appear to be valid.<br />';
}
if(strlen(trim($comments)) < 2) {
$error_message .= 'The Comments you entered do not appear to be valid.<br />';
}
if(strlen($error_message) > 0) {
died($error_message);
}
$email_message = "Form details below.\n\n";
function clean_string($string) {
$bad = array("content-type","bcc:","to:","cc:","href");
return str_replace($bad,"",$string);
}
$email_message .= "Name: ".clean_string($first_name)."\n";
$email_message .= "Email: ".clean_string($email_from)."\n";
$email_message .= "Comments: ".clean_string($comments)."\n";
// create email headers
$headers = 'From: '.$email_from."\r\n".
'Reply-To: '.$email_from."\r\n" .
'X-Mailer: PHP/' . phpversion();
@mail($email_to, $email_subject, $email_message, $headers);
?>
<!-- include your own success html here -->
<html>
<head>
<script type="text/javascript">
<!--
function delayer(){
window.location = "<?php echo $_SERVER['HTTP_REFERER']; ?>"
}
//-->
</script>
</head>
<body onLoad="setTimeout('delayer()', 1000)">
<h1> Charity / NGO Theme</h1>
<p> Thank you for contacting us. We will be in touch with you very soon. </p>
</body>
</html>
<?php
}
?>
没有合适的资源?快使用搜索试试~ 我知道了~
绿色大图幻灯商务响应式企业模板.rar
共251个文件
png:85个
jpg:60个
html:32个
0 下载量 106 浏览量
2023-03-01
15:50:40
上传
评论
收藏 1.41MB RAR 举报
温馨提示
具体页面可以查看我的文章——《html模板下载之“门户网站html模板页面下载”——html模板下载合集》。实训项目html模板下载,毕业设计html模板下载,绿色大图幻灯商务响应式企业模板_绿色 幻灯 菜单 大图 商务 响应式 responsive 手机 企业 整站 商务 科技 html5 css3 扁平化 bootstrap wap 宽屏 科技 咨询 互联网 标准 集团 全球 新闻 设计 门户
资源推荐
资源详情
资源评论
收起资源包目录
绿色大图幻灯商务响应式企业模板.rar (251个子文件)
bootstrap.css 151KB
style.css 67KB
font-awesome-ie7.css 34KB
font-awesome-ie7.min.css 30KB
font-awesome.css 24KB
prettyPhoto.css 20KB
font-awesome.min.css 19KB
calendar.css 13KB
customIE.css 5KB
gallery_widget.css 4KB
bxslider.css 4KB
social.css 3KB
nj.css 269B
bootstrap_or.css 51B
Thumbs.db 14KB
Thumbs.db 6KB
Thumbs.db 3KB
Thumbs.db 3KB
Thumbs.db 3KB
Thumbs.db 3KB
Thumbs.db 3KB
Thumbs.db 3KB
fontawesome-webfont.eot 29KB
bx_loader.gif 8KB
loader.gif 6KB
loader.gif 2KB
loader.gif 2KB
loader.gif 2KB
loader.gif 2KB
loader.gif 2KB
default_thumbnail.gif 227B
default_thumbnail.gif 227B
default_thumbnail.gif 227B
default_thumbnail.gif 227B
default_thumbnail.gif 227B
PIE.htc 2KB
checkout.html 96KB
shortcodes.html 81KB
product_listing_grid.html 34KB
product_listing_list.html 34KB
blog.html 33KB
index.html 32KB
blog_detail.html 31KB
event_detail.html 31KB
crowdfunding_listing.html 31KB
event_listing.html 31KB
event_venue.html 30KB
countdown.html 30KB
crowdfunding_detail.html 29KB
crowdfunding_payment.html 27KB
product_detail.html 27KB
sidebar.html 26KB
about-us.html 26KB
team.html 25KB
faqs.html 24KB
event_calander.html 24KB
gallery_4_col.html 24KB
career.html 23KB
cart.html 23KB
gallery_3_col.html 23KB
sitemap.html 23KB
gallery_2_col.html 22KB
gallery_1_col.html 22KB
contact_us.html 22KB
search.html 21KB
gallery_detail.html 21KB
404.html 21KB
inner_empty.html 19KB
comments.jpg 37KB
t_slider_5.jpg 24KB
t_slider_3.jpg 24KB
t_slider_1.jpg 24KB
t_slider_2.jpg 24KB
t_slider_4.jpg 24KB
gallery_large3.jpg 18KB
gallery_large1.jpg 18KB
gallery_large2.jpg 18KB
bgimg.jpg 12KB
blog3.jpg 9KB
blog_list_img_1.jpg 9KB
blog2.jpg 9KB
blog1.jpg 9KB
blog_detail.jpg 9KB
event4.jpg 9KB
crowd_funding_detail.jpg 9KB
event1.jpg 9KB
event3.jpg 9KB
event2.jpg 9KB
crowd_funding_main.jpg 9KB
gallery_img3.jpg 6KB
gallery_img4.jpg 6KB
gallery_img2.jpg 6KB
gallery_img1.jpg 6KB
about_main.jpg 5KB
product_image.jpg 5KB
office_1.jpg 3KB
office_4.jpg 3KB
office_3.jpg 3KB
office_2.jpg 3KB
slider_2_img.jpg 2KB
共 251 条
- 1
- 2
- 3
资源评论
我这头发越来越多呀
- 粉丝: 52
- 资源: 33
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功