繁体   English   中英

在Magnific Popup Modal中加载PHP Webform

[英]Loading PHP webform in Magnific Popup Modal

我一直在创建一些Web表单,用于为IT设备设置会议要求。

我有一个预制的表单(equip_meeting.php),该表单是用CSS样式设置的,我想在Magnific Popup Modal中加载它。

输入数据并确认确认后,表单会将数据提交到equip_meeting_mail.php页面进行格式化,以将电子邮件传递到指定的电子邮件箱。

该模式将关闭,并且用户将被发送到确认页面,并随邮件发送成功消息一起输出。

我正在使用以下测试页代码,因此无法加载php表单。

以下是弹出页面代码:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<!-- Magnific Popup core CSS file -->
<link rel="stylesheet" type="text/css" href="itform.css">
<link rel="stylesheet" href="//code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css">
<link rel="stylesheet" href="magnific-popup/magnific-popup.css">
<!-- jQuery 1.7.2+ or Zepto.js 1.0+ -->
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script> 
<script src="//code.jquery.com/ui/1.10.4/jquery-ui.js"></script>
<!-- Magnific Popup core JS file -->
<script src="magnific-popup/jquery.magnific-popup.js"></script> 
<script language="javascript">
$(function () {
    $('.popup-modal').magnificPopup({
        type: 'inline',
        preloader: false,
        modal: true
    });
    $(document).on('click', '.popup-modal-dismiss', function (e) {
        e.preventDefault();
        $.magnificPopup.close();
    });
});

  $(function() {
    $( "#Borrow_Date" ).datepicker();
    $( "#Return_Date" ).datepicker();
  });

   $(function() {
    $( document ).tooltip();
  });
</script>
</head>
<body>
<!-- link that opens popup -->
<a class="popup-modal" href="#form">Open modal</a>

<!-- form itself -->
<div id="form" class="container white-popup-block mfp-hide">
<?php include "equip_meeting.php" ?>
<center><p><a class="popup-modal-dismiss" href="#">Dismiss</a></p></center>
</div>

</body>
</html>

正在打开的页面是样式表单页面。

显然,equip_meeting.php周围的单引号解决了此问题。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM