How to troubleshoot the refresh button problem in and the SQL injection problem in the URL.

Source: Internet
Author: User
Tags sql injection| Button | solve | refresh | problem

All along, asp,php the processing of submitting data to another page, because it takes a lot of effort to deal with the decision in the page. This makes it possible to implement a small function with a lot of files, while benefiting from repeated submissions when submitting forms or deleting data.
The introduction of makes this issue a reverse change, events and event delegates, the program can easily know that the user is clicked on the button and processed accordingly. That's the problem. The page refresh operation is an operation within the browser because the browser does not issue any external notifications for the event or callback. The program does not know whether the user is a button or a refresh, submits the form or deletes the data when it is submitted repeatedly.
There are also direct one in the, then 1 and 1 are wrong, but to be in the URL of the value, such as after test.aspx?test=2, 1 and 1 will not be an error.

For refresh problem, we can refer to

If you don't use his refresh judgment, just ask your Web page to be able to prevent SQL injection.

You just have to join in your web.config.

<add key= "Sql_banfilename" value= "banfilename.htm"/>//if the URL of the current request? There are SQL keywords after

Jumps to the current page.
<add name= "Module" type= "My.Refresh.RefreshModule, Refresh"/>//http the request to the page's inheritance class processing.

I have not yet found the space to put the program and source code, interested friends can emai to Big this together discuss technology

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.