php 在投递简历时向邮箱自动发送一份当前简历

WBOY
Release: 2016-06-23 13:43:21
Original
1171 people have browsed it

邮箱地址从数据库取,在一个招聘详细页面点有显示,当在该详细页面点击应聘时,怎么将邮箱地址动态传过来并在sendMail.php页面里面获取传过来的邮箱地址



谢谢


回复讨论(解决方案)

招聘详细页面里面:
连接+隐藏iframe

<iframe name="back_interface" id="back_interface"              style="display:block;width:100%;height:300px;"></iframe><a href="../php_test/sendmail.php?EnterpriseMailbox=327496144@qq.com"              target="back_interface" >应聘</a>
Copy after login

或者也可以用ajax传递,以jquery为例
<!doctype html><html>  <head>    <meta charset="UTF-8"/>    <title>Document</title>    <script src="http://static.blog.csdn.net/scripts/jquery.js" type="text/javascript"></script>    <script>  $(function(){    $("#send").click(function(){      var mailbox=$("#EnterpriseMailbox").html()      $.get("../php_test/sendmail.php", { EnterpriseMailbox:  mailbox } ,function(data){        alert("简历已发");      });    });  });</script>  </head>  <body>企业邮局:<div id="EnterpriseMailbox">327496144@qq.com</div><input id="send" type="button" value="应聘"  />  </body></html>
Copy after login





sendmail.php
中对应的改为
$address=$_GET['EnterpriseMailbox'];

招聘页面
应聘

招聘详细页面
$address = isset($_GET['address'])? $_GET['address'] : '';
?>

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!