472,955 Members | 2,437 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,955 software developers and data experts.

session lost

hi there,

When I did the following steps the session in window A lost.

1.) authenticate user in window A and set $_SESSION['userId']="joe".
2.) open a new window B by clicking a button (in window A) which calls
window.open(..).
3.) I can get the $_SESSION['userId'] in window B (which is what I
want)
4.) When I close window B (manualy or programmaticaly), window A can
not know $_SESSION['userId'] any more.

5.) If I do NOT close window B, window A knows $_SESSION['userId']
without any problem.

This looks like window A passes session info to window B and shares it
with window B. But when window B is closed window A thinks the shared
session is killed.

How can I let window A keep the session even window B is closed?

I am using PHP 4.21 on windows 2000 server SP2.
Thanks in advance!
Jul 16 '05 #1
2 5956
After step 2 try to add the session_start()

on the top of page B....

point
"Nick" <zh*******@hotmail.com> wrote in message
news:ee**************************@posting.google.c om...
hi there,

When I did the following steps the session in window A lost.

1.) authenticate user in window A and set $_SESSION['userId']="joe".
2.) open a new window B by clicking a button (in window A) which calls
window.open(..).
3.) I can get the $_SESSION['userId'] in window B (which is what I
want)
4.) When I close window B (manualy or programmaticaly), window A can
not know $_SESSION['userId'] any more.

5.) If I do NOT close window B, window A knows $_SESSION['userId']
without any problem.

This looks like window A passes session info to window B and shares it
with window B. But when window B is closed window A thinks the shared
session is killed.

How can I let window A keep the session even window B is closed?

I am using PHP 4.21 on windows 2000 server SP2.
Thanks in advance!

Jul 16 '05 #2
Hi point,

Thank you for your reply.

Something really strange happened.
I tried your idea ( add session_start() at the beginning of the B
window) this morning before I went shopping and it sovled the problem!
Great!!
But when I came back and opened the app this afternoon, all the sudden
it did not work any more ( I mean I lost the session again in window A
). I am confused because I did not change any code.

Any idea about it?

Thanks.

"point" <in**@caanproduction.com> wrote in message news:<be********@enews2.newsguy.com>...
After step 2 try to add the session_start()

on the top of page B....

point
"Nick" <zh*******@hotmail.com> wrote in message
news:ee**************************@posting.google.c om...
hi there,

When I did the following steps the session in window A lost.

1.) authenticate user in window A and set $_SESSION['userId']="joe".
2.) open a new window B by clicking a button (in window A) which calls
window.open(..).
3.) I can get the $_SESSION['userId'] in window B (which is what I
want)
4.) When I close window B (manualy or programmaticaly), window A can
not know $_SESSION['userId'] any more.

5.) If I do NOT close window B, window A knows $_SESSION['userId']
without any problem.

This looks like window A passes session info to window B and shares it
with window B. But when window B is closed window A thinks the shared
session is killed.

How can I let window A keep the session even window B is closed?

I am using PHP 4.21 on windows 2000 server SP2.
Thanks in advance!

Jul 16 '05 #3

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

Similar topics

3
by: Microsoft | last post by:
I am using Session variables in my ASP application. I have tested the application on a Win2k professional and it works fine. When the same web app is installed on a win2k advanced server from the...
7
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...
0
by: CJ | last post by:
Hi We have Session Data lost randomly and Session State expired early. Our Intranet Application uses Window Server 2003 and .Net Framework 1.1. We set Session Time out to 60 minutes. but user...
6
by: Tony G. | last post by:
Hi there, I have an APS 3 application, running on a Windows 2003 Web edition server - it is a very busy website, and when users are click on certain links (membership info), a new window i...
9
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"...
3
by: William | last post by:
Hi I have an ASP.NET application that connects to an Access database. Everything works fine except for the Session object. Data in the session object is lost after I've made a call to the...
7
by: Erik | last post by:
I have an application that uses sessions variables a lot but one I publish the application on the prod server these variables are lost. The application is written i c# 2.0 and I've set the...
2
by: maxkumar | last post by:
Hi, I am running a ASP.NET 1.1 site on Win Server 2003 with IIS 6.0. The website has been running for about 1.5 years now. In the past, we used to have random cases of session variables getting...
43
by: davidkoree | last post by:
I mean not about cookie. Does it have something to do with operating system or browser plugin? I appreciate any help.
22
by: K. A. | last post by:
I have two servers at work, 'A' for testing and development, and server 'B' for production. On server A, I wrote a PHP test code to login users then direct them to a personalized page. This is...
0
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 4 Oct 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...
1
by: GKJR | last post by:
Does anyone have a recommendation to build a standalone application to replace an Access database? I have my bookkeeping software I developed in Access that I would like to make available to other...

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.