当前位置:网站首页>记录一个诡异的图片上传问题
记录一个诡异的图片上传问题
2022-06-26 00:15:00 【慕容田雨】
今天我在写表单提交的时候,发现一个奇怪的问题,甚是纳闷。
当前在做一个商城模块,当我要上传身份证正反面和商家的营业执照等图片的时候,会一个上传成功,一个上传不成功,然后一个又成功,一个又失败。我死活想不通,这到底是为啥捏?
然后反复检查我的代码,没发现什么不对的,纠结了半天,后来就再网上找有一个说,加一个随机数参数或者当前时间参数就可以了,然后我就试了下,果然好使了。仔细想想,可能就是多次上传让服务器以为是重复请求,然后就给没有给发请求。
其实在发送请求的时候,在链接后面加一个参数等于随机数或者加一个当前时间的参数就好,为了区分,每一次请求都不一样,这样就可以轻松上传了。下班咯!
边栏推荐
- One stop solution EMQ for hundreds of millions of communication of Internet of things
- cyclegan:unpaired image-to-image translation using cycle-consistent adversarial network
- Xiaomi tablet 5 Pro unlock bootloader
- CS144 环境配置
- Can bus transceiver principle
- memory leak check tools 详解
- GUN make (7) 执行make
- JQ 自定义属性取值
- Sweet cool girl jinshuyi was invited to be the spokesperson for the global finals of the sixth season perfect children's model
- Explication du script correspondant à l'assertion Postman
猜你喜欢

Tengwenze, a hot-blooded boy, was invited to serve as the image ambassador of the global finals of the sixth season perfect children's model

Interpretation of script corresponding to postman assertion

Easy to understand C language keyword static

readv & writev

Can bus transceiver principle

biggan:large scale gan training for high fidelity natural image synthesis

Pixel6 unlock bootloader

Principle of voice wake-up

Sweet girl lisixia was invited to be the little host of the global finals of the sixth season perfect child model

Differences and functions of TOS cos DSCP
随机推荐
Sweet girl lisixia was invited to be the little host of the global finals of the sixth season perfect child model
论文阅读 Exploring Temporal Information for Dynamic Network Embedding
Postman断言对应脚本的解释
PTA class a simulated third bomb: 1140-1143
Summary of xlnet model
Abnova丨抗GBA单克隆抗体解决方案
JQ 自定义属性取值
APP测试与WEB测试的区别
Easyexcel read file
Accumulation of some knowledge points in machine learning
Log4j2 vulnerability
元素定位的八大法则
Eight principles of element positioning
输入3个整数,从大到小输出出来
GUN make (3) Makefile的规则
On the difference between strlen and sizeof
The role of xargs
PTA class a simulated sixth bomb: 1156-1159
甜酷少女金书伊 受邀担任第六季完美童模全球总决赛代言人
Perfdog