Is it possible to persist viewstate information between HTTP and HTTPS
(on the same page obviously)? Trying to get around writing some messy
state transfer code... it doesn't seem to work if I use
response.redire ct. 4 1850
What about using Server.Transfer which has the ability to preserve the
context of the pevious page ? Or have I misunderstood you ??
Mr N.
"Chris Ashley" <ch***********@ gmail.com> wrote in message
news:11******** *************@f 14g2000cwb.goog legroups.com... Is it possible to persist viewstate information between HTTP and HTTPS (on the same page obviously)? Trying to get around writing some messy state transfer code... it doesn't seem to work if I use response.redire ct.
Mr Newbie wrote: What about using Server.Transfer which has the ability to preserve the context of the pevious page ? Or have I misunderstood you ??
Mr N.
Sorry, I don't think I explained myself well enough.
Basically I have a webform which is wizard style with a number of
'pages'. The last step needs to use HTTPS but submit to the same form.
I know I can do this using client side script to override the form
action but that's not ideal.
EG:
switch (wizardStep)
{
case 1:
// Needs to be http
infoPanel.Visib le = true;
break;
case 2:
// Needs to be http
declarationPane l.Visible = true;
case 3:
// Needs to be https
paymentPanel.Vi sible = true;
}
I know I can do this by just making a separate form, or adding some
code to pass values across, but just wondered if there was a neater way
that I'm missing?
Thanks,
Chris
Why not use HTTPS for all the stages, will this not work ?
"Chris Ashley" <ch***********@ gmail.com> wrote in message
news:11******** *************@o 13g2000cwo.goog legroups.com... Mr Newbie wrote: What about using Server.Transfer which has the ability to preserve the context of the pevious page ? Or have I misunderstood you ??
Mr N.
Sorry, I don't think I explained myself well enough.
Basically I have a webform which is wizard style with a number of 'pages'. The last step needs to use HTTPS but submit to the same form. I know I can do this using client side script to override the form action but that's not ideal.
EG:
switch (wizardStep) { case 1: // Needs to be http infoPanel.Visib le = true; break; case 2: // Needs to be http declarationPane l.Visible = true; case 3: // Needs to be https paymentPanel.Vi sible = true; }
I know I can do this by just making a separate form, or adding some code to pass values across, but just wondered if there was a neater way that I'm missing?
Thanks,
Chris
This may help
If you need to use absolute URLs, resort to a little trick and manually add
the session ID to the URL. You use the ApplyAppPathMod ifier method on the
HttpResponse class.
<a runat="server"
href=<% =Response.Apply AppPathModifier ("/code/page.aspx")%> >Click</a>
The ApplyAppPathMod ifier method takes a string representing a URL and
returns an absolute URL, which embeds session information. For example, this
trick is especially useful in situations in which you need to redirect from
a HTTP page to an HTTPS page.
"Chris Ashley" <ch***********@ gmail.com> wrote in message
news:11******** *************@o 13g2000cwo.goog legroups.com... Mr Newbie wrote: What about using Server.Transfer which has the ability to preserve the context of the pevious page ? Or have I misunderstood you ??
Mr N.
Sorry, I don't think I explained myself well enough.
Basically I have a webform which is wizard style with a number of 'pages'. The last step needs to use HTTPS but submit to the same form. I know I can do this using client side script to override the form action but that's not ideal.
EG:
switch (wizardStep) { case 1: // Needs to be http infoPanel.Visib le = true; break; case 2: // Needs to be http declarationPane l.Visible = true; case 3: // Needs to be https paymentPanel.Vi sible = true; }
I know I can do this by just making a separate form, or adding some code to pass values across, but just wondered if there was a neater way that I'm missing?
Thanks,
Chris This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Citoyen du Monde |
last post by:
Trying to get some ideas on a simple javascript project (to teach myself the
language).
I want to develop a client-side vocabulary practice application that would
allow users to
enter their own words, their own definitions plus an example of how the word
is
used in practice. It'll be all client side with - cookies? to get
persistence so that the words won't
disappear on me each time the page is closed (which is what happened when I
|
by: David Anderson |
last post by:
I'm having trouble persisting viewstate information for webcontrols I've
disabled via javascript. I have a group of textboxes that I enable/disable
via a checkbox control that invokes a javascript method in its onclick
attribute. When the page does a postsback, the textboxes that are enabled
have their viewstate persisted; however, the ones that are disabled (but
still have text in them) do not have their viewstate persisted. I have...
|
by: Tomas Vera |
last post by:
Here's another goofy thing.
I need to persist the state of items added dynamically to a Panel control
between round-trips to the server.
I have a web form that contains a TreeView and a DropDownList
My web form reads the value of the drop down list, runs a query against a
database, then presents the results of the query to the user with a TreeView (IE
WebControls version). When the user checks an item's checkbox, the item is
|
by: Charlie |
last post by:
Hi,
Is there a way of persisting state information for a server control
without using ViewState? I'm currently using Page.Session() but I
don't think this is the best way. What's the preferred method?
Thanks
Charlie
|
by: lim |
last post by:
What is the possible error that occurs when the Page_load event is not triggered during execution.
In my page there's some basic server control. Is there any loops holes?
| |
by: Stu |
last post by:
Hi,
I am creating a control in a PlaceHolder like so:
Private Sub btnDelete_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnDelete.Click
Dim ctrl As AcceptOrCancel =
CType(Page.LoadControl("controls/AcceptOrCancel.ascx"), AcceptOrCancel)
PlaceHolder1.Controls.Add(ctrl)
|
by: =?Utf-8?B?SmltRg==?= |
last post by:
We are building some new sites using .NET 2.0. We are trying to implement
persisting ViewState site wide to SQL (as opposed to on a per application
basis). I have successfully got the ViewState to persist for a given
application, but I was then trying to compile a DLL that contains the custom
code, add it to the GAC and use the .browser file to “enable it”. When I do,
I get the following error. “Server could not create...
|
by: cfps.Christian |
last post by:
I have a web usercontrol on the form that dynamically builds itself
and then when an item has been clicked it will allow me to get the
object at the selected index. The problem I'm having is that I need
the items to persist in viewstate so I can pull them out but when a
button on the main form is clicked all the information stored in the
viewstate is lost.
I've tried session too and it won't let me do anything with it at all
(object is...
|
by: =?Utf-8?B?VmlqYXkgQ2hpa3Rl?= |
last post by:
Hi Experts,
With Session Affinity and Web Server Farm on ISA Server 2006 accessing 2
backend IIS servers, I’m getting error “Validation of ViewState MAC failed.
If this application is hosted by a Web Farm or cluster, ensure that
<machineKeyconfiguration specifies the same validationKey and validation
algorithm. AutoGenerate cannot be used in a cluster”.
Here is the scenario when I got the error.
|
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,...
|
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...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
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...
|
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...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |