473,625 Members | 2,717 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

session & browser

>> When I open a second browser window from the first, it uses the same session with first!!!
This is not true. session_id is unique for each combination of browser/url.


I believe this too, but you can see:
1. try http://tassadar.physics.auth.gr/~chameleon/Books/
2. right-click in one menu link and "open in new window".
3. in 2nd browser window click greek flag
4. in 1st browser window click "Programmin g"
everything in 1st browser window are in greeks!!! (we activate greeks only in 2nd browser window)
I try Mozilla & IE6 too.

In the code, I have this for language:
language is changing with GET (eg index.php?lang= english)
if $lang is not set (GET) try SESSION
if $_SESSION['session_lang'] is not set try COOKIE
if $_COOKIE['cookie_lang'] is not set try language for domain (eg gr=greek it=italian fr=francais default=english )

What is error?

thanks
Jul 17 '05 #1
2 3930

"<- Chameleon ->" <ch******@hotma il.NOSPAM.com> a écrit dans le message de
news: bn**********@ni c.grnet.gr...
When I open a second browser window from the first, it uses the same
session with first!!! This is not true. session_id is unique for each combination of
browser/url. I believe this too, but you can see:
1. try http://tassadar.physics.auth.gr/~chameleon/Books/
2. right-click in one menu link and "open in new window".
3. in 2nd browser window click greek flag
4. in 1st browser window click "Programmin g"
everything in 1st browser window are in greeks!!! (we activate greeks only in 2nd browser window) I try Mozilla & IE6 too.

In the code, I have this for language:
language is changing with GET (eg index.php?lang= english)
if $lang is not set (GET) try SESSION
if $_SESSION['session_lang'] is not set try COOKIE
if $_COOKIE['cookie_lang'] is not set try language for domain (eg gr=greek it=italian fr=francais default=english )
What is error?
thanks
Hello,

Where do you store the $lang var ?? in session or cookies ??? if yes, that's
the reason why :)

<<<session_id is unique for each combination of browser/url.>>>>
i don't think so.... that's true if you start 2 different IE .... (StartExecute > iexplore 2 times)

But when you open a new window in IE, it still the same process.... so
session vars are shared between all window included in the IE process.

Regards,
Julien.

Jul 17 '05 #2
> > >> When I open a second browser window from the first, it uses the same
session with first!!!
This is not true. session_id is unique for each combination of
browser/url.
I believe this too, but you can see:
1. try http://tassadar.physics.auth.gr/~chameleon/Books/
2. right-click in one menu link and "open in new window".
3. in 2nd browser window click greek flag
4. in 1st browser window click "Programmin g"
everything in 1st browser window are in greeks!!! (we activate greeks only

in 2nd browser window)
I try Mozilla & IE6 too.

In the code, I have this for language:
language is changing with GET (eg index.php?lang= english)
if $lang is not set (GET) try SESSION
if $_SESSION['session_lang'] is not set try COOKIE
if $_COOKIE['cookie_lang'] is not set try language for domain (eg

gr=greek it=italian fr=francais default=english )

Where do you store the $lang var ?? in session or cookies ??? if yes, that's
the reason why :)


I store the (GET) $lang in both session & cookies but I check first if exists in session and if yes I dont check cookies. So,
different browsers have different sessions...
If I open twice the browser from the "start menu" in windows, all are great!
The problem appears when I duplicate a browser window with both IE6 and Mozilla
<<<session_id is unique for each combination of browser/url.>>>>
i don't think so.... that's true if you start 2 different IE .... (Start
Execute > iexplore 2 times)

But when you open a new window in IE, it still the same process.... so
session vars are shared between all window included in the IE process.


Yes I saw it but I believe this is wrongful. isn't it?
Jul 17 '05 #3

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

Similar topics

6
2212
by: | last post by:
I ask something relative later but the answer make me cry ;-) If we duplicate the browser window (both in IE / Mozilla), both of 2 browser windows use the same session!!! This produces many problems... My program is this: I have html format books inside zip files. If I choose a book from my main page, php sets $_SESSION = "a_book.zip"; and loads the index.html from a_book.zip. if we click a link inside index.html like:
14
1783
by: windandwaves | last post by:
Hi Folk Forgive me for asking such a basic question... I have a site where I want to track the user from start till end... To do this, I have setup the following structure for each page, referring to startup.php, where the session is managed. Can anyone check that I am doing it right. I thought I was doing it right, but then the site started doing really, really funny stuff, basically loosing track of sessions ... I want my...
1
1387
by: - Steve - | last post by:
I use forms based authentication and I've been putting the username in Session State (Session). Then when a user posts I check that Session != null else I Session.Abandon() and Response.Redirect("logon.aspx") since that seems like a graceful way to handle timeouts, session state losses (bin directory was updated for example). This doesn't seem like a reliable way to do it though. I get weird things happening like SOMETIMES if I close...
5
2483
by: Raghu Raman | last post by:
HI, am using a simple project in asp.net using c#. if i put the break point in the application start & session start event , they are firing good .BUT WHEN i close my project while running on IE, the session end & application end event are not firing even though i put the break point there. Could u give me the solution for this how i could trace those.
10
12192
by: GreggTB | last post by:
I've got an page (LOGIN.ASPX) that receives the user's login information. During the page load, it checks the credentials against a database and, if validation is successful, creates an instance of an object that stores the user's basic profile data (username, user type, associated sales region, etc.). I've been taking this user info and placing it in the Session object like so... Session = user;
14
5919
by: Arne | last post by:
A lot of Firefox users I know, says they have problems with validation where the ampersand sign has to be written as &amp; to be valid. I don't have Firefox my self and don't wont to install it only because of this, so I hope some of you gurus can enlighten me with this :) In what circumstances can the "&amp;" in the source code be involuntary changed to "&" by a browser when or other software, when editing and uploading the file to the web...
10
29895
by: Steve Cook | last post by:
Hi, I have an upload application written in PHP and Flash. The PHP page gets the file information via $_POST. Moreover, the user never actually visits the PHP page, rather Flash sends the information to the PHP page and then loads the result, all in the background. Right now, the php page cannot access the $_SESSION. Is there anyway that I can conitnue the PHP session when doing this or does the user have to visit the PHP page?
2
2634
by: Gordon Burditt | last post by:
I had this idea about preventing session fixation, and I'm wondering what anyone else thinks about it. The idea is, essentially, don't allow session ids that YOUR PHP didn't generate (and aren't yet expired) to log in. That way if someone sticks a made-up session ID on a URL, it won't matter, unless it happens to correspond to an active session (guessing a user password is probably easier). Is this already standard practice, new, or is...
11
3640
by: Glenn | last post by:
Hi I've been experimenting with managing state using the Session object. I've created a simple WS with a couple of methods, one which sets a string value, another that retrieves it. Each method has the WebMethodAttribute.EnableSession set to true. When I run the test page the session is maintained. However, using a console application, in between setting the string value and attempting to
0
8253
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
8692
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
8354
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
8497
tracyyun
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...
0
7182
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
6116
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
5570
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4192
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1499
bsmnconsultancy
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...

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.