代码如图:(比较简单,就是一个input输入框和input提交按钮,注意type为submit,而不是button)

Home > Web Front-end > HTML Tutorial > HTML form value passing example is passed through get method_HTML/Xhtml_Web page production

HTML form value passing example is passed through get method_HTML/Xhtml_Web page production

WBOY
Release: 2016-05-16 16:37:28
Original
2539 people have browsed it

The google.html interface is as shown in the figure

The code is as shown in the figure: (relatively simple, it is an input input box and input submit button. Note that the type is submit, not button)

Copy code
The code is as follows:

















google.php The code is as shown in the figure: ($_GET is used to obtain the data passed by the form through the get method; $_POST is used to obtain the data passed by the form through the post method)

Copy Code
The code is as follows:

print "
"; <br>print_r($_GET); <br>print "
";
?>

The running result is as shown in the figure:
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