473,513 Members | 2,409 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Loosing session variables

I have a website with several input forms over a number of pages. The
information that the user gives is following through the pages as session
variables. It has been working good for two years.

Now I am redoing the whole site and have all the different pages put into an
Iframe on the first page. The form pages are the same as before, but now I
seem to loose some of the session variables.

But the strange thing is that if I first go through the the process with the
old website and then switch to the new in the same browser, it all works.

Do you guys have any suggestions where to look for the fault?

/ Rolf
May 16 '06 #1
11 1903
Rolf Rosenquist wrote on 16 mei 2006 in
microsoft.public.inetserver.asp.general:
I have a website with several input forms over a number of pages. The
information that the user gives is following through the pages as
session variables. It has been working good for two years.

Now I am redoing the whole site and have all the different pages put
into an Iframe on the first page. The form pages are the same as
before, but now I seem to loose some of the session variables.

But the strange thing is that if I first go through the the process
with the old website and then switch to the new in the same browser,
it all works.

Do you guys have any suggestions where to look for the fault?


Are you really working on one domain and root?

The session identifying session-cookie is domain specific.
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
May 16 '06 #2
Rolf Rosenquist wrote:
I have a website with several input forms over a number of
pages. The information that the user gives is following
through the pages as session variables. It has been working
good for two years.

Now I am redoing the whole site and have all the different
pages put into an Iframe on the first page. The form pages
are the same as before, but now I seem to loose some of the
session variables.
ASPFAQ has a pretty good list of causes:
http://www.aspfaq.com/show.asp?id=2157
But the strange thing is that if I first go through the the
process with the old website and then switch to the new in
the same browser, it all works.


This suggests that the location of the IFRAME is *always* on the old server.
Check to see if you have a hard-coded location (IFRAME SRC attribute or FORM
ACTION attribute), rather than a relative one.

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms.
May 16 '06 #3
Thanks to both of you for your replies. In a way, I now have got it work (I
think). The aspfaq.com link lead me to a MS page with this information:
1. Run Internet Explorer.
2. Click Tools, and then click Internet Options.
3. Click the Privacy tab, and then click Advanced.
4. Click to select the Override automatic cookie handling check box.
5. To allow ASP and ASP.NET session cookies to be set, click to select the
Always allow session cookies check box.
.... and then it works.

But then I have the problem to make my users to set this in their
machines....

That I did not have to do with the old site, that only was a page by itself.
Now I use the same page, but it is shown in an Iframe. I have also put the
whole bunch of files in the same directory and the reference to the asp page
is written as http://www.blabla.com/bla/bla/bla/

I would hope that it was possible to do without interfering with the users
browser settings....?

/ Rolf

"Dave Anderson" <GT**********@spammotel.com> skrev i meddelandet
news:ew**************@TK2MSFTNGP04.phx.gbl...
Rolf Rosenquist wrote:
I have a website with several input forms over a number of
pages. The information that the user gives is following
through the pages as session variables. It has been working
good for two years.

Now I am redoing the whole site and have all the different
pages put into an Iframe on the first page. The form pages
are the same as before, but now I seem to loose some of the
session variables.
ASPFAQ has a pretty good list of causes:
http://www.aspfaq.com/show.asp?id=2157
But the strange thing is that if I first go through the the
process with the old website and then switch to the new in
the same browser, it all works.


This suggests that the location of the IFRAME is *always* on the old

server. Check to see if you have a hard-coded location (IFRAME SRC attribute or FORM ACTION attribute), rather than a relative one.

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use of this email address implies consent to these terms.

May 16 '06 #4
Rolf Rosenquist wrote:
I would hope that it was possible to do without interfering
with the users browser settings....?


Did you try adding P3P headers?

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms.
May 16 '06 #5
No, haven't done that. It seems to me even more complicated than getting the
user to change his browser. ...but I may be wrong?

/ Rolf

"Dave Anderson" <GT**********@spammotel.com> skrev i meddelandet
news:O$**************@TK2MSFTNGP05.phx.gbl...
Rolf Rosenquist wrote:
I would hope that it was possible to do without interfering
with the users browser settings....?
Did you try adding P3P headers?

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message.

Use of this email address implies consent to these terms.

May 16 '06 #6
What really puzzles me is that I am only losing some of the session
variables. On the second page in the row of pages I lose this one:
Session("var1") = Request.Form("var1")

but on the third page I do get this one:
Session("var2") = Request.Form("var2")

And this is only happening when I use the same webpages to be loaded into an
Iframe. Not when they are shown as normal pages.
Can you get some sense out of that?

/ Rolf

"Dave Anderson" <GT**********@spammotel.com> skrev i meddelandet
news:O$**************@TK2MSFTNGP05.phx.gbl...
Rolf Rosenquist wrote:
I would hope that it was possible to do without interfering
with the users browser settings....?
Did you try adding P3P headers?

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message.

Use of this email address implies consent to these terms.

May 17 '06 #7
Rolf Rosenquist wrote:
Did you try adding P3P headers?

No, haven't done that. It seems to me even more complicated
than getting the user to change his browser. ...but I may
be wrong?


Once you HAVE a privacy policy, there is nothing to it. You just add the
headers to the website configuration in the IIS console and every page gets
them automatically. This can significantly impact cookie behavior on client
machines.

I think it is far simpler than convincing each and every user to configure
his client for your site.
--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms.
May 17 '06 #8
Rolf Rosenquist wrote:
What really puzzles me is that I am only losing some of the session
variables. On the second page in the row of pages I lose this one:
Session("var1") = Request.Form("var1")

but on the third page I do get this one:
Session("var2") = Request.Form("var2")

And this is only happening when I use the same webpages to be loaded
into an Iframe. Not when they are shown as normal pages.
Can you get some sense out of that?


No. I have no idea what you mean by "second page" and "third page". For that
matter, I can't tell if you are indicating equality or assignment.

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms.
May 17 '06 #9

"Dave Anderson" <GT**********@spammotel.com> skrev i meddelandet
news:12*************@corp.supernews.com...
Rolf Rosenquist wrote:
What really puzzles me is that I am only losing some of the session
variables. On the second page in the row of pages I lose this one:
Session("var1") = Request.Form("var1")

but on the third page I do get this one:
Session("var2") = Request.Form("var2")

And this is only happening when I use the same webpages to be loaded
into an Iframe. Not when they are shown as normal pages.
Can you get some sense out of that?
No. I have no idea what you mean by "second page" and "third page". For

that matter, I can't tell if you are indicating equality or assignment.

The site presents several pages after each other when the user has filled
the input fields in one form, the next (second, third, fourth...) page are
presented to him.

Later this evening I will test to put a 'fake' page before the first one.
And let that page link to it, as there must be a reason that only the input
fields on the first page are missing the session variables. I have so far,
never missed any of them on the later pages.

I now have come up with the idea that the reason perhaps could be that when
I already am inside the Iframe and link to the next page works in opposite
to the taget='iframe'. At least would be a thing to test.

/ Rolf
May 17 '06 #10

"Dave Anderson" <GT**********@spammotel.com> skrev i meddelandet
news:12*************@corp.supernews.com...
Rolf Rosenquist wrote:
Did you try adding P3P headers?
No, haven't done that. It seems to me even more complicated
than getting the user to change his browser. ...but I may
be wrong?


Once you HAVE a privacy policy, there is nothing to it. You just add the
headers to the website configuration in the IIS console and every page

gets them automatically. This can significantly impact cookie behavior on client machines.

I think it is far simpler than convincing each and every user to configure
his client for your site.

I think you are right here, but I also don't think I am able to change the
IIS console for the webhotel I am using.

/ Rolf
May 17 '06 #11
Got it working now. But had to use an ugly method. Instead of using session
variables when in an Iframe, I used hidden fields and put all the variables
to the next and the next....and so on... webpage.

Not elegant, I know, but at least it works...

/ Rolf
"Dave Anderson" <GT**********@spammotel.com> skrev i meddelandet
news:12*************@corp.supernews.com...
Rolf Rosenquist wrote:
What really puzzles me is that I am only losing some of the session
variables. On the second page in the row of pages I lose this one:
Session("var1") = Request.Form("var1")

but on the third page I do get this one:
Session("var2") = Request.Form("var2")

And this is only happening when I use the same webpages to be loaded
into an Iframe. Not when they are shown as normal pages.
Can you get some sense out of that?
No. I have no idea what you mean by "second page" and "third page". For

that matter, I can't tell if you are indicating equality or assignment.

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use of this email address implies consent to these terms.

May 17 '06 #12

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

Similar topics

7
7167
by: Billy Jacobs | last post by:
I am having a problem with my session variable being set to Null for no apparent reason. I am declaring it like the following when the user logs in. dim objUserInfo as new clsUserInfo 'Set...
1
1550
by: Jonk Eidersteldvr | last post by:
Hi, I am using a web application -asp, ado, C#, using CodeBehind files etc.. I am using "InProc" session state and find that session variables are loosing their values between one web form and...
8
2281
by: Radu Colceriu | last post by:
HI, I've an asp.net app like this: login.aspx (no frame) :- save in session the user and pass -> framedoc.html :- frameset 2 content 1. menu.aspx...
2
1399
by: Robert Berezka | last post by:
hi! I am working on a ASP.NET project. My problem with the session vaiable is: Localy on my client computer, where I develope my ASP.Net application, Everything runs fine. When I...
9
2088
by: Patrick | last post by:
Hello I'm running two Webservers Using ASP.NET. both are running the same ASP.NET Application, with <sessionState mode="SQLServer" stateConnectionString="tcpip=127.0.0.1:42424"...
6
1365
by: Lars Netzel | last post by:
This is basic Session handling but it's not working. On a Page1.aspx I have this code: ----------------------------------- If TextBox1.Text = "admin" And TextBox2.Text = "Admin01" Then ...
2
1574
by: Aaric | last post by:
I am developing my web apps on a Win XP Pro SP2 laptop and then uploading them to a Windows Server 2003. My current project involves using session state variables to keep track of user after they...
15
1795
by: cyndi_r2000 | last post by:
Hi Everyone: I have a web application running on .NET 2.0 under IIS 6.0 and users of this application seem to be loosing their session randomly - we havent been able to identify any pattern,...
1
4806
by: Dabbler | last post by:
I set some strings and integers in Session but when I get to my redirected page the values are null. I'm running on localhost Windows XP Pro but using remote SQL 2005 database. Not doing...
5
2135
by: Mirovk | last post by:
The onclick action associated to my form´s radio buttons call to a vbscript were the session values are changed, this happens correctly but with the onclick action associated to my continue button...
0
7267
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,...
0
7175
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...
0
7391
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,...
1
7120
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...
0
5697
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,...
0
4754
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3235
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1609
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
809
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.