473,776 Members | 1,557 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Response.Redire ct() and absolute URL links and User Control questi

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
Nov 19 '05 #1
1 2532
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.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

"Andre Ranieri" <An**********@d iscussions.micr osoft.com> wrote in message
news:03******** *************** ***********@mic rosoft.com...
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

Nov 19 '05 #2

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

Similar topics

3
9628
by: Peter Bassett | last post by:
I have a recruiter website listing jobs. Some postings having email links directly to the employer (instead of the usual email link to the recruiter owner). The owner wishes to track when people reply directly to employers. So I have an ASP script (it looks like an email link but fires of an ASP) that has to do 2 things - insert an entry in the database noting this reply, and open the email client for the user to send directly to the...
2
4702
by: Kostas kousinovalis | last post by:
Hello I have a asp page which it post some values to an external web page (not mine) with the method response.redirect (www.website.com/page.asp?username=user&password=mypass) The external web page response OK if the user exist and Error if the user not exists. How can I take this data to send it to my own pages somewhere? After the response.redirect I lost control Thanks
6
4325
by: Sam | last post by:
I have some issues with HTTP Headers and I was hoping for some pointers or references to good articles. Here is the problem. I have 6 .aspx pages, each page contains a common .ascx. This ascx serves two purposes, 1. it contains a tab strip with response.redirects to navigate to the other pages; 2. I authenticate the user by check to see if a cookie exists, if it doesn't I redirect to a login screen.
2
4357
by: RAJ | last post by:
In our multi-tier application, we have several ASP.NET user controls which will update the same data source provided by middle tier logic. In this particular scenario we have one user control displaying the contents of the data source, whilst another control updates the datasource via a command buttons implementation of 'Click', an event raised in the 'Handle Postback Events' stage of the control execution life cycle (via the...
4
5392
by: Marty U. | last post by:
I have a Session variable I need to check the value of. If it is value a then redirect to some page. I need to implement this in a user control that is on all the relevent pages. I placed the if and redirect statement within the page_load of the user control. However, when you try to access any page that has the user control it simply loads for minutes and never actually redirects. What am I missing with executing the response.redirect...
2
6014
by: news://news.microsoft.com/microsoft.public.de.germ | last post by:
Hallo! Ich habe ein Frameset mit 3 Frames. Im 1. Frame wird eine ASPX-Seite geöffnet. In dieser werden einige Steuerelemente angezeigt. Nun soll bei bestimmten Benutzeraktivitäten eine andere ASPX-Seite geöffnet werden, und zwar in einem der beiden anderen Frames. Mein Problem ist, dass die Seite, die geöffnet werden soll, manchmal im 2. und manchmal im 3. Frame angezeigt werden soll (je nach Benutzeraktivität).
2
2550
by: Nathan Sokalski | last post by:
I am using the Response.Redirect method in a User Control to allow visitors to click an ImageButton to take them to another page. However, when I click the ImageButton I recieve the following error: Response is not available in this context. I am assuming this is due to the fact that I am calling the method from the User Control rather than the Page. If I use context.Response.Redirect I am
4
2399
by: Bart op de grote markt | last post by:
Hello I have a website in php in which I have some kind of portal to external links that come from a database. When a user clicks on a link, "link.php" is called, does some stuff (e.g. adds 1 to the visit-count of that certain page) and then forwards the user with a location-header to the asked page. Now my question: is it possible to get the response-code of that asked page? E.g. when code 404 is returned, I can put that in the...
12
1491
by: gigi | last post by:
How to send more than one value using response redirect? For example i can send one like this response.Redirect "pregled.asp?ime=" & strUserName but how to send two or more values? I tried response.Redirect("pregled.asp?ime=" & strUserName & " & prezime = " & strUserLastName) but it didn't work.
0
9628
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9464
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10289
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10061
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8952
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7471
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5367
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5493
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3622
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.