javascript - ajax submit duplication using interface form
大家讲道理
大家讲道理 2017-05-19 10:15:20
0
5
557

Submit data asynchronously through ajax in the form of interface on the PC side. This data is some input and pictures. Here I do not use the form form to submit, but simply obtain the value, and then put the value in the form that needs to be submitted. The corresponding fields of the interface are submitted successfully for the first time without any problem. But each time the next submission is made, the previous data will be submitted repeatedly, and not all of the previous data is resubmitted, but some of it is from the previous time. Some of them are not known or recognized. Just a string of question marks

大家讲道理
大家讲道理

光阴似箭催人老,日月如移越少年。

reply all(5)
大家讲道理

Post code pictures, think about a few questions first

1.是不是使用了什么框架。原生的还是什么
2.提交的数据是不是一个对象,对象是不是没有清空。
3.是不是事件有问题。形成了闭包导致数据异常?
为情所困

I agree with the answerer on the 1st floor, I suggest you post the code;
For jquery’s ajax, you can try the disable cache option, cache:false.

过去多啦不再A梦

Just watch the network

滿天的星座

It is recommended to check the network to see if the data submitted each time meets the requirements, or output the content to be submitted before submitting again

滿天的星座

Before asking questions, check your own code first and debug your own code. I believe you can solve this problem yourself.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template