473,320 Members | 2,117 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,320 software developers and data experts.

Redirecting to another site with a large querystring

joe
Hello,
I have a website set up on our server that is especially for errors.
When another website encounters an error, it will redirect to this
site with error details in the querystring. The error website process
the querystring and displays a nicely formatted error message with
details.

The problem I am having is that the querystrings are getting too long
and I am unable to successfully redirect to the error site. What are
my options other than using querystrings? The error website is a
separate project from all of my other websites, so I think that cuts
down on my options. I would prefer not to have to do anything
database-wise.

Thanks!
Jun 27 '08 #1
9 1918
"joe" <co*******@gmail.comwrote in message
news:8a**********************************@m36g2000 hse.googlegroups.com...
The error website is a separate project from all of my other websites, so
I
think that cuts down on my options.
It does, but I'm really curious as to why you would have a completely
separate website *just* for displaying errors...

Standard exception handling and user notification are excellent candidates
for a library project which you just add in to your "real" (for want of a
better term) websites so that the code is maintained in one place but
deployed everywhere it's needed. Then you wouldn't need to worry about query
strings or anything like that...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Jun 27 '08 #2
joe
On Apr 16, 10:15*am, "Mark Rae [MVP]" <m...@markNOSPAMrae.netwrote:
"joe" <cole.m...@gmail.comwrote in message

news:8a**********************************@m36g2000 hse.googlegroups.com...
The error website is a separate project from all of my other websites, so
I
think that cuts down on my options.

It does, but I'm really curious as to why you would have a completely
separate website *just* for displaying errors...

Standard exception handling and user notification are excellent candidates
for a library project which you just add in to your "real" (for want of a
better term) websites so that the code is maintained in one place but
deployed everywhere it's needed. Then you wouldn't need to worry about query
strings or anything like that...

--
Mark Rae
ASP.NET MVPhttp://www.markrae.net
I have a seperate website so errors are displayed in a conistent way.
The processing is done in a class library, notification is sent, and
then the last step is redirecting to this page.

Can you give an example of how I could modify my class library to
display an error page that looked consistant across applications? I
think maybe our lines of thinking are on a different page.
Jun 27 '08 #3

"joe" <co*******@gmail.comwrote in message
news:8a**********************************@m36g2000 hse.googlegroups.com...
Hello,
I have a website set up on our server that is especially for errors.
When another website encounters an error, it will redirect to this
site with error details in the querystring. The error website process
the querystring and displays a nicely formatted error message with
details.

The problem I am having is that the querystrings are getting too long
and I am unable to successfully redirect to the error site. What are
my options other than using querystrings? The error website is a
separate project from all of my other websites, so I think that cuts
down on my options. I would prefer not to have to do anything
database-wise.

Thanks!
You might look into HttpWebRequest and HttpWebResponse to handle this.
Mike
Jun 27 '08 #4
Seeing that the reason for a separate site is for consistency tells me that
the majority of your code that does work is in your ASP.NET pages, which is
an issue.

The easiest way to set up consistency is to use the same controls to display
the errors. This will consist of a processing library (in most cases) and a
control. The control can be a user control, which you copy to each site, or
you can create a server control. A user control is faster, but you have to
remember to include it. If you use a server control, you can place the bits
in the GAC and force all apps to use the latest. This will make it so you do
not have to update multiple sites when you change the error methodology,
which is why I assume you are doing a separate site.

As for continuing the way you are doing it, consider sending the information
in a form collection that you build. It is a bit more consuming, but you can
send as much FUD as you need. I would consider this an interim step, at
best.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://gregorybeamer.spaces.live.com/lists/feed.rss

or just read it:
http://gregorybeamer.spaces.live.com/

*************************************************
| Think outside the box!
|
*************************************************
"joe" <co*******@gmail.comwrote in message
news:8a**********************************@m36g2000 hse.googlegroups.com...
Hello,
I have a website set up on our server that is especially for errors.
When another website encounters an error, it will redirect to this
site with error details in the querystring. The error website process
the querystring and displays a nicely formatted error message with
details.

The problem I am having is that the querystrings are getting too long
and I am unable to successfully redirect to the error site. What are
my options other than using querystrings? The error website is a
separate project from all of my other websites, so I think that cuts
down on my options. I would prefer not to have to do anything
database-wise.

Thanks!

Jun 27 '08 #5
"joe" <co*******@gmail.comwrote in message
news:1c**********************************@e39g2000 hsf.googlegroups.com...
I have a seperate website so errors are displayed in a conistent way.
The processing is done in a class library, notification is sent, and
then the last step is redirecting to this page.
I realise *what* you're doing - I just don't understand *why*... :-) N.B.
I'm not saying that you are wrong or that your method is bad...
Can you give an example of how I could modify my class library to
display an error page that looked consistant across applications? I
think maybe our lines of thinking are on a different page.
1) Create a new project called e.g. errors

2) Add a web page (e.g. error.aspx) which will display the error to the
user.

3) Add a public class which will handle your processing logic - include a
public method called e.g. ProcessError

4) Add the project to any solution which needs it - this is even easier if
you're using a source control solution e.g. Visual SourceSafe 2005...

5) In your code-behind, include standard try...catch and/or
try...catch...finally exception handling which will call the ProcessError
method and, finally, Response.Redirect to error.aspx which will display the
error to the user.

6) Add code in the "main" sites' Application_Error method in Global.asax to
catch any unhandled exceptions.
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Jun 27 '08 #6
joe
On Apr 16, 11:43*am, "Mark Rae [MVP]" <m...@markNOSPAMrae.netwrote:
"joe" <cole.m...@gmail.comwrote in message

news:1c**********************************@e39g2000 hsf.googlegroups.com...
I have a seperate website so errors are displayed in a conistent way.
The processing is done in a class library, notification is sent, and
then the last step is redirecting to this page.

I realise *what* you're doing - I just don't understand *why*... :-) N.B.
I'm not saying that you are wrong or that your method is bad...
Can you give an example of how I could modify my class library to
display an error page that looked consistant across applications? *I
think maybe our lines of thinking are on a different page.

1) Create a new project called e.g. errors

2) Add a web page (e.g. error.aspx) which will display the error to the
user.

3) Add a public class which will handle your processing logic - include a
public method called e.g. ProcessError

4) Add the project to any solution which needs it - this is even easier if
you're using a source control solution e.g. Visual SourceSafe 2005...

5) In your code-behind, include standard try...catch and/or
try...catch...finally exception handling which will call the ProcessError
method and, finally, Response.Redirect to error.aspx which will display the
error to the user.

6) Add code in the "main" sites' Application_Error method in Global.asax to
catch any unhandled exceptions.

--
Mark Rae
ASP.NET MVPhttp://www.markrae.net

Thanks for the input. My setup is similar to how you mention, except
I didn't realize I could include entire web forms in a class library.
I am a going to dabble with that now. Thanks!
Jun 27 '08 #7
joe
On Apr 16, 11:43*am, "Mark Rae [MVP]" <m...@markNOSPAMrae.netwrote:
"joe" <cole.m...@gmail.comwrote in message

news:1c**********************************@e39g2000 hsf.googlegroups.com...
I have a seperate website so errors are displayed in a conistent way.
The processing is done in a class library, notification is sent, and
then the last step is redirecting to this page.

I realise *what* you're doing - I just don't understand *why*... :-) N.B.
I'm not saying that you are wrong or that your method is bad...
Can you give an example of how I could modify my class library to
display an error page that looked consistant across applications? *I
think maybe our lines of thinking are on a different page.

1) Create a new project called e.g. errors

2) Add a web page (e.g. error.aspx) which will display the error to the
user.

3) Add a public class which will handle your processing logic - include a
public method called e.g. ProcessError

4) Add the project to any solution which needs it - this is even easier if
you're using a source control solution e.g. Visual SourceSafe 2005...

5) In your code-behind, include standard try...catch and/or
try...catch...finally exception handling which will call the ProcessError
method and, finally, Response.Redirect to error.aspx which will display the
error to the user.

6) Add code in the "main" sites' Application_Error method in Global.asax to
catch any unhandled exceptions.

--
Mark Rae
ASP.NET MVPhttp://www.markrae.net
Maybe I'm not understanding correctly - it sounds like you are
advising me to have two web projects in the same solution - one that
contains my error.aspx and ProcessError method, and another which is
my "main" project. Is this correct? If so, how am I supposed to
redirect from a form in one project to the error.aspx form in another?
Jun 27 '08 #8
"joe" <co*******@gmail.comwrote in message
news:56**********************************@t12g2000 prg.googlegroups.com...
Maybe I'm not understanding correctly - it sounds like you are
advising me to have two web projects in the same solution - one that
contains my error.aspx and ProcessError method, and another which is
my "main" project. Is this correct? If so, how am I supposed to
redirect from a form in one project to the error.aspx form in another?
The second project is really just somewhere to store the error files...

With a source control such as Visual SourceSafe you simply drag the "shared"
files into whichever project needs them. That way, you can edit the shared
files in any of the projects in which they are used, and that will
automatically update them in all other projects in which they are used...
--
Mark Rae
ASP.NET MVP
http://www.markrae.net

Jun 27 '08 #9
joe
On Apr 16, 5:54*pm, "Mark Rae [MVP]" <m...@markNOSPAMrae.netwrote:
"joe" <cole.m...@gmail.comwrote in message

news:56**********************************@t12g2000 prg.googlegroups.com...
Maybe I'm not understanding correctly - it sounds like you are
advising me to have two web projects in the same solution - one that
contains my error.aspx and ProcessError method, and another which is
my "main" project. *Is this correct? *If so, how am I supposed to
redirect from a form in one project to the error.aspx form in another?

The second project is really just somewhere to store the error files...

With a source control such as Visual SourceSafe you simply drag the "shared"
files into whichever project needs them. That way, you can edit the shared
files in any of the projects in which they are used, and that will
automatically update them in all other projects in which they are used...

--
Mark Rae
ASP.NET MVPhttp://www.markrae.net
I see. Thank you for your advice!
Jun 27 '08 #10

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

Similar topics

6
by: Robert Cohen | last post by:
Hi All, I have what is an easy question for you all, but I have not idea (this is in vbscript). I have this script below that works great. It figures out the user logged in and gives the AD...
7
by: Fawke101 | last post by:
Hi there, I have a ASP/SQL 7.0 Application and i have a page (page1.asp) that has 2 ways of accessing it. 1 is through a hyperlink on another page (page2.asp), that inserts a value into a...
5
by: Vanessa | last post by:
I have a question, is that any other way to retrieve data from another webpage besides using XML object? Because I am using XML object now but give me so much problems. If I used...
3
by: Cantekin Guneser | last post by:
in my project i ahave frame sets i want to main frame to direct a url with query string when press a button that is at left frame vit java script code thanks in advance for ayn hepl or idea
2
by: Simon Harvey | last post by:
Hi, This is a very typical requirement so I'm sure the answer is very straightforward. If a user tries to get to a secure directory, they can be a sent to a login page automatically. Once the...
3
by: Marlon | last post by:
I have a site that is now SSL secured. User not still using the http:// to get to the site. How can I redirect the user the the visited page using https:// ?
3
by: DonnyW | last post by:
I am working on an application that displays a list of items (biglist.aspx). With each item, there is a link that takes the user to another aspx page for updating the specific details of that item...
4
by: Greg Smalter | last post by:
Redirecting from page to page within a web project is pretty easy. However, all Redirect methods take strings as arguments, as if you mistype the string, you don't find out until run time that you...
3
by: James Robertson | last post by:
I am new to the ASP and VB thing so be kind. Question I have is that I have created an ASPX web site to use as an E-Mail page. But I want to use this for a lot of users. Can I create the link on...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
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...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
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...

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.