Home > php教程 > php手册 > php下通过POST还是GET来传值

php下通过POST还是GET来传值

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 12:28:14
Original
901 people have browsed it

细心的朋友一定注意到,上一次PHP页面间传递参数的专题中有这么一段程序:

    



    其中的method我用了POST,但为什么不用GET方法呢?

    首先来看看POST与GET传值的区别:

Post传输数据时,不需要在URL中显示出来,而Get方法要在URL中显示。 
Post传输的数据量大,可以达到2M,而Get方法由于受到URL长度的限制,只能传递大约1024字节。
    一般来说,我们用POST传值作为首选,这样做较为安全。 

     本文转载自www.cenusblog.com  
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
Latest Issues
php data acquisition?
From 1970-01-01 08:00:00
0
0
0
PHP extension intl
From 1970-01-01 08:00:00
0
0
0
How to learn php well
From 1970-01-01 08:00:00
0
0
0
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template