About jQueryMobile form submission Servlet problem_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 12:03:32
Original
1548 people have browsed it

The front desk uses a form form of jQueryMobile, and then submits it to the Servlet for processing. The redirection of the response in the servlet cannot be used. After clicking submit on the mobile phone, the page displays the errorpage prompt text. After querying, it is said that ajax needs to be disabled. After I added data-ajax="false" to the form tag, the server reported an exception after submission.

Without adding data-ajax="false", the submitted content can be saved in the database, but the page will not jump. After adding it, the submitted data cannot even be saved in the database. I don't know if data-ajax= is added. "false", please give me some advice on whether to modify the Servlet, thank you very much!


Reply to the discussion (solution)

Then just use ajax. Why am I so stupid? I solved it myself. .

	    $(document).ready(function () {			$("#submitbtn").click(function(){					cache: false,					$.ajax({					  type: "POST",					  url: "feedback",					  data: $('#feedbackform').serialize(),					  success:function(data){					  		$.mobile.changePage("success.html");					  }			  	});			});        });
Copy after login

Related labels:
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!