Loading ...
Sorry, an error occurred while loading the content.
 

Re: [bang-phpug] session destroy problem

Expand Messages
  • kumar gaurav singh Sonu
    yes I do.....thanx for your concern..... Regards Kumar Gaurav Singh ________________________________ From: janakiraman To:
    Message 1 of 7 , Mar 10, 2010
      yes I do.....thanx for your concern.....

      Regards
      Kumar Gaurav Singh


      ________________________________
      From: janakiraman <jhon_311983@...>
      To: bang-phpug@yahoogroups.com
      Sent: Wed, March 10, 2010 8:43:46 AM
      Subject: Re: [bang-phpug] session destroy problem


      Hi Kumar,

      Do you have started session_start( ) in your logout page. Before calling session_destroy( ) for destroying the current session. The session_destroy( ) will delete the data associated with the current session only. Use session_unset( ) to delete all the global and session varaibles.

      Regards,
      Janakiraman.

      --- On Tue, 9/3/10, kumar gaurav singh Sonu <kr_gaurav651@ yahoo.com> wrote:

      From: kumar gaurav singh Sonu <kr_gaurav651@ yahoo.com>
      Subject: Re: [bang-phpug] session destroy problem
      To: bang-phpug@yahoogro ups.com
      Date: Tuesday, 9 March, 2010, 7:54 PM



      Make sure that you have set the following in php.ini

      session.save_ path = "<drive>:/<folder> "

      ; Whether to use cookies.

      session.use_ cookies = 1

      Then try this code....I think after that you can easily solve your problem by yourself..

      best of luck..

      http://www.w3. org/TR/xhtml1/ DTD/xhtml1- transitional. dtd">

      <head>

      <meta http-equiv=" Content-Type" content="text/ html; charset=utf- 8" />

      <title>Session Test</title>

      </head>

      <body>

      <?php

      session_start( );

      if(isset($_SESSION[ 'views']) )

      $_SESSION['views' ] = $_SESSION['views' ]+ 1;

      else

      $_SESSION['views' ] = 1;

      echo "views = ". $_SESSION['views' ];

      // if($_SESSION[ 'views'] == 5)

      //unset($_SESSION[ 'views']) ; -->

      if($_SESSION[ 'views'] == 10)

      session_destroy( );

      ?>

      </body>

      </html>

      ____________ _________ _________ __

      From: Amardeep <amardeep.sarkar@ gmail.com>

      To: bang-phpug@yahoogro ups.com

      Sent: Tue, March 9, 2010 4:45:58 PM

      Subject: Re: [bang-phpug] session destroy problem

      Do you have session_start( ); called in the logout page ?

      On Tue, Mar 9, 2010 at 1:18 PM, bhatavanti <bhatavanti@ yahoo. com> wrote:

      >

      >

      > Hi,

      > I have started a session in login page and trying to destroy it on logout

      > page but I am getting foll warnings:

      >

      > Warning: session_destroy( ) [function.session- destroy]: Trying to destroy

      > uninitialized session in

      > /home/content/ a/g/a/agani/ html/G/Mithaiwal e/testing/ logout.php on line 2

      >

      > Warning: Cannot modify header information - headers already sent by (output

      > started at /home/content/ a/g/a/agani/ html/G/Mithaiwal e/testing/ logout.php: 2)

      > in /home/content/ a/g/a/agani/ html/G/Mithaiwal e/testing/ logout.php on line 3

      >

      > Please help

      >

      >

      >

      --

      Amardeep Sarkar

      [Non-text portions of this message have been removed]

      [Non-text portions of this message have been removed]

      Your Mail works best with the New Yahoo Optimized IE8. Get it NOW! http://downloads. yahoo.com/ in/internetexplo rer/

      [Non-text portions of this message have been removed]







      [Non-text portions of this message have been removed]
    Your message has been successfully submitted and would be delivered to recipients shortly.