当前位置:网站首页>GET 和 POST 请求类型的区别
GET 和 POST 请求类型的区别
2022-07-06 06:41:00 【辰风沐阳】
1. 前言
GET 和 POST 请求类型的区别 ?
虽然这个问题是基础知识,但这也算是面试热门问题,做下总结就当复习了吧
2. GET 和 POST 的区别
1. 使用场景
GET 请求方式一般用于获取和删除数据,POST 请求方式一般用于添加和修改数据
2. 传参方式
GET 请求方式传递参数会将参数拼接到 URL 地址中
POST 请求方式传递参数会将参数放到请求体(Request Body)中
3. 安全性
GET 是显式提交,安全性较低;POST 是隐式提交,安全性较高
4. 传输的数据大小
GET 请求方式传输的数据大小不能大于 2KB,而 POST 请求方式传输的数据大小没有限制
5. 上传文件
GET 请求方式不能上传文件,而 POST 请求方式可以上传文件
3. GET 和 POST 的区别总结
GET 请求方式一般用于获取数据,会将数据拼接到 URL 地址中,属于显式提交,安全性较低,传输的数据大小限制在 2KB 以内,不能上传文件
POST 请求方式一般用于添加和更新数据,会将数据存放在请求体中,属于隐式提交,安全性较高,传输的数据没有大小限制,可以上传文件
边栏推荐
- 钓鱼&文件名反转&office远程模板
- In English translation of papers, how to do a good translation?
- Introduction and underlying analysis of regular expressions
- How to reconstruct the class explosion caused by m*n strategies?
- Cobalt Strike特征修改
- 翻译影视剧字幕,这些特点务必要了解
- Summary of leetcode's dynamic programming 4
- C语言_双创建、前插,尾插,遍历,删除
- Is it difficult for girls to learn software testing? The threshold for entry is low, and learning is relatively simple
- Day 248/300 thoughts on how graduates find jobs
猜你喜欢
Cobalt Strike特征修改
What is the difference between int (1) and int (10)? Senior developers can't tell!
Bitcoinwin (BCW): 借贷平台Celsius隐瞒亏损3.5万枚ETH 或资不抵债
Reflex WMS中阶系列3:显示已发货可换组
Introduction and underlying analysis of regular expressions
A method to measure the similarity of time series: from Euclidean distance to DTW and its variants
The internationalization of domestic games is inseparable from professional translation companies
My creation anniversary
CS通过(CDN+证书)powershell上线详细版
Explain in detail the functions and underlying implementation logic of the groups sets statement in SQL
随机推荐
Chinese English comparison: you can do this Best of luck
Phishing & filename inversion & Office remote template
详解SQL中Groupings Sets 语句的功能和底层实现逻辑
Pallet management in SAP SD delivery process
金融德语翻译,北京专业的翻译公司
Day 246/300 ssh连接提示“REMOTE HOST IDENTIFICATION HAS CHANGED! ”
Making interactive page of "left tree and right table" based on jeecg-boot
关于新冠疫情,常用的英文单词、语句有哪些?
中英对照:You can do this. Best of luck祝你好运
Fledgling Xiao Li's 103rd blog CC2530 resource introduction
Machine learning plant leaf recognition
Database basics exercise part 2
How to reconstruct the class explosion caused by m*n strategies?
Biomedical localization translation services
Day 239/300 注册密码长度为8~14个字母数字以及标点符号至少包含2种校验
Basic commands of MySQL
L'Ia dans les nuages rend la recherche géoscientifique plus facile
Chapter 7 - thread pool of shared model
Simple query cost estimation
Day 245/300 JS foreach data cannot be updated to the object after multi-layer nesting