tags:

views:

16

answers:

1

Hi, I have a simple code to check counter.

     session_start();

if(!isset($_SESSION['footerimg']) || empty($_SESSION['footerimg']) ){
         $_SESSION['footerimg']='sunset.jpg';
        echo $_SESSION['footerimg'];
      }

But all time this is printing "sinsut.jpg" when is page is loading my session is being destroy. This is running well in FF but problem happeninig with IE and chrome.

+2  A: 

This is most definitely because IE8 doesn't accept cookies from localhost. Check this question.

Igor Zinov'yev
I m not working on localhost. I m working on live server.
Ajay
Well, otherwise I don't know what could be the cause. Maybe you should update the question and post some details about how your development environment is set up?
Igor Zinov'yev