473,382 Members | 1,396 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

How can I get this url?

In IE browser, if you type in http://www.microsoft.com/MyTestPage.asp,
definitely it is an invalid url, I noticed that I will come to this url
instead:
http://www.microsoft.com/info/smart4...osoft.com/MyTe
stPage.asp.

My question is: how can the iis get the wrong url
(http://www.microsoft.com/MyTestPage.asp) and pass it to another url as a
parameter?

Thanks!

Jason
Nov 18 '05 #1
6 1039
On Mon, 28 Jun 2004 16:04:12 -0700, "Jason Zhou" <jz***@apx.com>
wrote:
In IE browser, if you type in http://www.microsoft.com/MyTestPage.asp,
definitely it is an invalid url, I noticed that I will come to this url
instead:
http://www.microsoft.com/info/smart4...osoft.com/MyTe
stPage.asp.

My question is: how can the iis get the wrong url
(http://www.microsoft.com/MyTestPage.asp) and pass it to another url as a
parameter?

Thanks!

Jason


a custom error page. if you look at your web site properties see the
custom errors section. Write your own error page to do what u want.

capture page urls / send out emails / update logs

whatever u want

-Adam
Nov 18 '05 #2
I did my own error page, but how can I capature that wrong url then?

Thanks!

Jason

<as******@inlandkwpp.com> wrote in message
news:sj********************************@4ax.com...
On Mon, 28 Jun 2004 16:04:12 -0700, "Jason Zhou" <jz***@apx.com>
wrote:
In IE browser, if you type in http://www.microsoft.com/MyTestPage.asp,
definitely it is an invalid url, I noticed that I will come to this url
instead:


http://www.microsoft.com/info/smart4...rosoft.com/MyT

e
stPage.asp.

My question is: how can the iis get the wrong url
(http://www.microsoft.com/MyTestPage.asp) and pass it to another url as a
parameter?

Thanks!

Jason


a custom error page. if you look at your web site properties see the
custom errors section. Write your own error page to do what u want.

capture page urls / send out emails / update logs

whatever u want

-Adam

Nov 18 '05 #3
On Mon, 28 Jun 2004 16:27:55 -0700, "Jason Zhou" <jz***@apx.com>
wrote:
I did my own error page, but how can I capature that wrong url then?

Thanks!

Jason


Hello,

I gave it a try myself and I found that

HttpContext.Current.Request.RawUrl in the error page returns this:
"/errormessagre/webform1.aspx?404;http://localhost/blah"

I assume that if u take everything right fo the 404; you should get
u're url.

-Adam
Nov 18 '05 #4
Really? I tried this before but seems did not work. I will try it again
then.

Thank you very much for the help!

Jason

<as******@inlandkwpp.com> wrote in message
news:7e********************************@4ax.com...
On Mon, 28 Jun 2004 16:27:55 -0700, "Jason Zhou" <jz***@apx.com>
wrote:
I did my own error page, but how can I capature that wrong url then?

Thanks!

Jason


Hello,

I gave it a try myself and I found that

HttpContext.Current.Request.RawUrl in the error page returns this:
"/errormessagre/webform1.aspx?404;http://localhost/blah"

I assume that if u take everything right fo the 404; you should get
u're url.

-Adam

Nov 18 '05 #5
Adam,

Sorry, one more question.

From your sample, looks like in your one aspx page, you tried to call
http://localhost/blah, and this error was caught by webform1.aspx, and you
got this error message in your original aspx page. I am wondering in this
webform1.aspx instead of your original aspx page, can you get
http://localhost/blah this information?

Thanks!

Jason

<as******@inlandkwpp.com> wrote in message
news:7e********************************@4ax.com...
On Mon, 28 Jun 2004 16:27:55 -0700, "Jason Zhou" <jz***@apx.com>
wrote:
I did my own error page, but how can I capature that wrong url then?

Thanks!

Jason


Hello,

I gave it a try myself and I found that

HttpContext.Current.Request.RawUrl in the error page returns this:
"/errormessagre/webform1.aspx?404;http://localhost/blah"

I assume that if u take everything right fo the 404; you should get
u're url.

-Adam

Nov 18 '05 #6
On Tue, 29 Jun 2004 10:32:52 -0700, "Jason Zhou" <jz***@apx.com>
wrote:

From your sample, looks like in your one aspx page, you tried to call
http://localhost/blah, and this error was caught by webform1.aspx, and you
got this error message in your original aspx page.


I setup the webform1.aspx as the handler for error 404's within IIS.
The original web page does not exist and therefore can't handle
anything. If the error happens inside the scope of a configured
application then you will be able to handle it with its own 404
handler.

The problem is that if a 404 happens it is because the page doesn't
exist. You can do anything you want with this information.

-Adam

Nov 18 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: James | last post by:
I have a from with 2 fields: Company & Name Depening which is completed, one of the following queries will be run: if($Company){ $query = "Select C* From tblsample Where ID = $Company...
5
by: Scott D | last post by:
I am trying to check and see if a field is posted or not, if not posted then assign $location which is a session variable to $location_other. If it is posted then just assign it to...
2
by: Nick | last post by:
Can someone please tell me how to access elements from a multiple selection list? From what ive read on other posts, this is correct. I keep getting an "Undefined variable" error though... Form...
2
by: Alexander Ross | last post by:
I have a variable ($x) that can have 50 different (string) values. I want to check for 7 of those values and do something based on it ... as I see it I have 2 options: 1) if (($x=="one") ||...
0
by: Dan Foley | last post by:
This script runs fine, but I'd like to know why it's so slow.. Thanks for any help out there on how i can make it faster (it might take up to 5 min to write these 3 export files whith 15 records...
5
by: Lee Redeem | last post by:
Hi there I've created abd uploaded this basic PHP script: <html> <head> <title>PHP Test</title> </head> <body> <H1 align="center">
5
by: christopher vogt | last post by:
Hi, i'm wondering if there is something like $this-> to call a method inside another method of the same class without using the classname in front. I actually use class TEST { function...
6
by: Phil Powell | last post by:
Ok guys, here we go again! SELECT s.nnet_produkt_storrelse_navn FROM nnet_produkt_storrelse s, nnet_produkt_varegruppe v, nnet_storrelse_varegruppe_assoc sv, nnet_produkt p WHERE...
1
by: Michel | last post by:
a site like this http://www.dvdzone2.com/dvd Can you make it in PHP and MySQL within 6 weeks? If so, send me your price 2 a r a (at) p a n d o r a . b e
11
by: Maciej Nadolski | last post by:
Hi! I can`t understand what php wants from me:( So: Cannot send session cache limiter - headers already sent (output started at /home/krecik/public_html/silnik.php:208) in...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.