redirect - Custom classic ASP 404 page, error reading first variable of querystring -



redirect - Custom classic ASP 404 page, error reading first variable of querystring -

i found unusual situation request.querystring() seems not work correctly. have configured web.config redirect of missing pages.

<system.webserver> <httperrors errormode="custom" existingresponse="replace"> <remove statuscode="404" substatuscode="-1" /> <error statuscode="404" substatuscode="-1" responsemode="executeurl" path="/404.asp" /> </httperrors> </system.webserver>

it works page 404.asp cannot read variables in querystring. more specific, first variable has messy name.

let's seek explain better.

i open http://localhost/it/?fname=john&lname=blake webserver correctly redirect 404.asp.

now weird. page 404.asp has access messy querystring.

response.write(request.querystring()) prints 404;http://localhost:80/it/?fname=john&lname=blake

that not original querystring , cannot find way managed correctly. why not? because request.querystring("fname") doesn't homecoming right value.

where error? :)

the 404 page receives url querystring seems

i split result stands @ 404;http://localhost:80/it/?fname=john&lname=blake using:

dim newquerystringarray newquerystringarray= split(request.querystring(),"?")

this mean newquerystringarray(1) equal fname=john&lname=blake

you can manipulate how want i'd utilize similar approach above, using & delimiter , = sign value

try http://classicaspreference.com/aspexamples/custom404.asp

redirect vbscript asp-classic http-status-code-404 request.querystring

Comments

Popular posts from this blog

php - Android app custom user registration and login with cookie using facebook sdk -

c# - Create a Notification Object (Email or Page) At Run Time -- Dependency Injection or Factory -

Set Up Of Common Name Of SSL Certificate To Protect Plesk Panel -