FORM(使用 Javascript)在 PHP 页面中不起作用!
我有一个简单的订阅表单: http://thepanamainsider.com/sanblas/index9.php 表单不起作用,它正在使用 JS。 在单独的 HTML 页面中编写时,与 JS 代码相同的 HTML 代码 ( http://thepanamainsider.com/form1.html )工作没有任何问题。
PHP 页面可以从以下位置下载:
http://manishkungwani.com /blog/wp-content/uploads/2011/03/indexORG.zip
请帮助我如何使表单运行?
澄清: 它不起作用意味着它应该重定向到 PDF 并向用户发送邮件。 如果 POST 是从 HTML 页面发送的,则接收 POST 请求的 form.php 工作正常,因此我预计发送的请求存在问题或验证存在问题。 该按钮重定向到同一页面!
进一步说明: 这个问题注定无法解决,因为编写的代码太糟糕了,另一个开发人员使用了示例页面来创建当前页面! (不好的做法) 我通过仅用 HTML 重写页面解决了这个问题,现在一切正常。 然而,最接近的回复已被标记为答案,因为预期的问题是验证。 抱歉浪费了时间。 (如果有的话:))
I have a simple subscribe form at : http://thepanamainsider.com/sanblas/index9.php
The form doesn't work, it is using JS.
The same HTML code with the JS code when written in a separate HTML page ( http://thepanamainsider.com/form1.html ) works without any issue.
The PHP page can be downloaded from:
http://manishkungwani.com/blog/wp-content/uploads/2011/03/indexORG.zip
Please help me as to how can I make the form run?
Clarification:
It doesn't work means that it is supposed to redirect to a PDF and send a mail to the user.
The form.php recieving the POST request works fine, if the POST is sent from the HTML page, thus I anticipate that there is an issue with the request being sent or an issue with the validation.
The button redirects to the same page!
Further Clarification:
The question was bound to remain unsolved because the code that was written was too bad, another developer had used a sample page to create the current page! (bad practice)
I resolved the issue by rewriting the page in only HTML and now everything works fine.
Yet the closest reply has been marked the answer as the anticipated issue was VALIDATION.
sorry for the waste of time. (if any :) )
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你的 php 代码中
没有像 pay1 这样的元素,这会导致 javascript 错误
you have in your php code
There is no such element in your code as pay1 which is causing javascript error