Write ASP Program All of you know,
Request. servervariables ("script_name ")Returns the relative path of the current page, for example,"
Http: // localhost/BBS/post. asp", The returned result is"
BBS/post. asp". However, I occasionally find
Bug In iis5.1 (XP) and iis6.0 (2003), if the relative path contains more than one
. Asp", The returned value is from the first"
. Asp"End truncation. For example,
Http: // localhost/iweboffice. ocx. asp/documentlist. asp", The expected return is"
Iweboffice. ocx. asp/documentlist. asp", But the actual returned result is"
Iweboffice. ocx. asp".
ASP programs sometimes need to reference
Request. servervariables ("script_name ")To automatically obtain the complete URL path of a file. Because of this problem, I cannot modify the name of my virtual directory so that it does not contain"
. Asp", But I always think this is not a good solution. I accidentally remembered another variable.
Request. servervariables ("path_info ")In any tutorial, it is pointed out that it works the same as the former and is used to return the path information of the current page. But I want to see from the name that the two are at least different in the way of obtaining information? Start to"
Path_info", Sure enough. Expected results are returned! This is the problem.
Positive Solution This story tells us: Yes
Bold assumptions, careful proof ,,,
What will happen to the world when humans lose their associations? ?..
By the way, I have used so many methods to debug ASP programs.
Response. Write ()The best way!
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:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.