Response.Redirect() and absolute URL links and User Control questi

G

Guest

I have a quick question - I'd just like to have confirmation to be sure.

I'm building an ASP.NET corporate site for my employer, some of the pages
have e-commerce capability and will need to be SSL-encrypted. Thus, I assume
I'll need to use absolute links to specifiy the https protocol (correct me if
I'm wrong on that)

Does ASP.NET handle an absolute link any different than a relative one?
Will I have any problems maintaining session variables, etc or does the
ASP.NET engine recognize the redirect url as part of the project anyway?

On a slightly different topic, I'm using User Controls extensively for page
elements like the header, left bar, etc which repeat from page to page. Is
there any standard way for accessing User Control functions from the parent
page? I also notice in developing that, when a user clicks on a Web Form
button and a postback is automatically fired, the all the user controls run
their Load() function, even if the web form button is running code that will
redirect them to a new page. This seems a like a wasted trip to the www
server, is there any way of suppressing the user controls from reloading?

Thanks in advance,

Andre Ranieri
andre<>senske<>c.m
 
S

Steve C. Orr [MVP, MCSD]

You can redirect to an absolute HTTPS path within your application without
having an Session issues. Session will remain in tact as you'd expect.

You can declare the user control at the top of your code behind file and
interact with any of its public members.

After every postback, the entire page (including all controls) are entirely
re-created. That's how ASP.NET works. You're correct that it's not always
the most efficient solution, which is why any great ASP.NET developer must
be familiar with client side scripting techniques, which can help to
minimize postbacks.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,995
Messages
2,570,228
Members
46,817
Latest member
AdalbertoT

Latest Threads

Top