Currently, all iis sites can customize the 404 error page, open the local IIS website, View Properties-custom error, find Error 404, and double-click to modify its message type to URL, the Url is set to the absolute path of the file under the root directory of the website.
For example, if you set the url of 404.asp to/404.aspunder the website directory, you can modify the url of 404.asp.
The principle is as follows:
For example, the homepage http: // www. **********. com/index. asp: the url format of the article is as follows: http: // www. **********. com/Class/show. asp? ID = 12345. When writing a program, you only need to intentionally set http: // www. ************. com/Class/show. asp? ID = 12345 is written as http: // www. ***********. com/show/12345.html
Http: // www. **********. com/show/12345.html. if you want to click this hyper-connection, the 404 error page will be automatically called as long as the 404 error page is defined as an asp page.
Add it to get show. asp? ID = 12345 page Id 12345 and then use the thief program to obtain the modified page content displayed at http: // www. **********. com/show/12345.html page. the http: // www. **********. com/show/12345.html http: // www. **********. com/Class/show. asp? ID = 12345 the two pages are the same. the following is the code of the 404 error page. You can write other applications by yourself. The following is a brief introduction: the code of the 404 error page is used to obtain the current URL value. For example:
Original Dynamic address: http: // www. *****. com/post. asp? Id = * enter a random address: http: // www. *****. com/post-id -*. the html page returns the following values: 404; http: // www. *****. com: 80/post-id -*. html
We can use replace to put 404; http: // www. *****. com: 80/post-id-filter, only the URL value is left *. html, and split it. mainly,
Finally, sURL (0) is equal to the value of *, and sURL (1) is equal to the value of html. the asp file code changes the obtained id value to sURL (0), and then saves the code on the 404 error page, which enables the website pseudo-static function.
In the end, if the vps and host you are using are correct, and if it is space, you need a custom 404 feature. Otherwise, you will not be able to use it. The article from Hefei anorectal Hospital: http://www.ylwltg.com, reproduced please indicate the source.