Jump to content

session problem ( multi users )


mraiur

Recommended Posts

Hi.

  I was developing the site on my PC and when we uploaded on the host server one strange problem occur .

 

I can only log-in on the site from one PC and whit all users .

But if i try to log on from a diferent PC i notised that no sessions where able to be set .

Why is that  ?

 

I used:

session_start();

 

then for an example :

$_SESSION['USER_NAME'] = 'someuser'

Link to comment
Share on other sites

Your question is a bit vauge, but i would guess this is to do with the settings of the browser on the 2nd machine.

 

Whilst you are using sessions, PHP will most likely (i say most likely, because it depends on your php setup) be setting a cookie to track the session ID. Therefore, if your browser on your second machine isn't accepting cookies, then no session will be kept.

Link to comment
Share on other sites

Okey i wil explain more.

2 PC  one is main and one is  a coworker's pc .

 

if i log in the friend will not be able to set any sessions when he tries.

 

if i am logged in whit FireFox i will not be able to log in whit Internet Explorer ( or otherlwise  )

 

 

Link to comment
Share on other sites

The strangest thing is that when i put

session_start();

 

on the first line of index.php

this is shown:

 

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /home/autoserv/public_html/index.php:1) in /home/autoserv/public_html/index.php on line 1

 

 

any idia ?

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.