logout user

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    logout user

    hi good coders has any one got or now how to do this please

    when a member is logged in and some one else logs in using there info it logs the person what was online first so

    eg: jo_blogs: online list

    then when some one else logs in as jo_blogs

    eg jo_blogs: loggin on

    it logs the first one out so

    eg jo_blogs: sorry u have been logged out as someone else has signed in with ur name

    hope u understand what i mean

    and whats to any one that can help i am using wapdesire v_2 script
    HELP THEM WHO HELPS YOU



    i only work on wapdesire v_2 coding only

    #2
    do a check online


    $check = mysql_fetch_array(mysql_query("SELECT * FROM ibf_online WHERE userid='$_REQUEST[user]' "));
    if($check[0])
    {
    echo "You May enter";
    }else{
    echo "You Cant enter";
    }
    Visit: Chat4u.mobi - The New Lay Of being a site of your dreams!
    Visit: WapMasterz Coming Back Soon!
    _______
    SCRIPTS FOR SALE BY SUBZERO
    Chat4u Script : coding-talk.com/f28/chat4u-mobi-script-only-150-a-17677/ - > Best Script for your site no other can be hacked by sql or uploaders.
    FileShare Script : coding-talk.com/f28/file-wap-share-6596/ -> Uploader you will never regret buying yeah it mite be old now but it still seems to own others...
    _______
    Info & Tips
    php.net
    w3schools.com

    Comment


      #3
      This is what i coded in my login.php
      ..We delete the old session first and then create a new one.,so this time, the one who is online in your acct. will be logged out or session expire while you just logged in..This is also to prevent multiple logins..
      PHP Code:
      if(isonline(getuid_nick($uid)))
      {
      $deloldses mysql_query("DELETE FROM ibwf_ses WHERE uid='".getuid_nick($uid)."'");
      }
      $tm time();
      $xtm $tm + (getsxtm()*60);
      $sid session_id();
      $res mysql_query("INSERT INTO ibwf_ses SET id='".$sid."', uid='".getuid_nick($uid)."', expiretm='".$xtm."'");
      if(
      $res)
      {
      $tolog true;
      $idn getuid_nick($uid);
      $lact mysql_fetch_array(mysql_query("SELECT lastact FROM ibwf_users WHERE id='".$idn."'"));
      mysql_query("UPDATE ibwf_users SET lastvst='".$lact[0]."' WHERE id='".$idn."'");
      mysql_query("UPDATE ibwf_users SET lastact='".time()."' WHERE id='".$idn."'");
      }else{
      echo 
      title($mime,"Error");
      echo 
      startalign($mime,"center");
      echo 
      "<img src=\"images/notok.gif\" alt=\"x\"/>\n<br/>\nDatabase Error!!!\n";

      Last edited by kiLLeR-eyEd_14; 01.12.09, 04:25.
      My Blog: http://jhommark.blogspot.com
      My Facebook: http://www.facebook.com/jhommark
      My Official Site: http://www.undergroundweb.tk
      My Community Site: http://undergroundwap.xtreemhost.com

      Comment


        #4
        Originally posted by kiLLeR-eyEd_14 View Post
        This is what i coded in my login.php
        ..We delete the old session first and then create a new one.,so this time, the one who is online in your acct. will be logged out or session expire while you just logged in..This is also to prevent multiple logins..
        PHP Code:
        if(isonline(getuid_nick($uid)))
        {
        $deloldses mysql_query("DELETE FROM ibwf_ses WHERE uid='".getuid_nick($uid)."'");
        }
        $tm time();
        $xtm $tm + (getsxtm()*60);
        $sid session_id();
        $res mysql_query("INSERT INTO ibwf_ses SET id='".$sid."', uid='".getuid_nick($uid)."', expiretm='".$xtm."'");
        if(
        $res)
        {
        $tolog true;
        $idn getuid_nick($uid);
        $lact mysql_fetch_array(mysql_query("SELECT lastact FROM ibwf_users WHERE id='".$idn."'"));
        mysql_query("UPDATE ibwf_users SET lastvst='".$lact[0]."' WHERE id='".$idn."'");
        mysql_query("UPDATE ibwf_users SET lastact='".time()."' WHERE id='".$idn."'");
        }else{
        echo 
        title($mime,"Error");
        echo 
        startalign($mime,"center");
        echo 
        "<img src=\"images/notok.gif\" alt=\"x\"/>\n<br/>\nDatabase Error!!!\n";

        i am after the code for wapdesire v_2 script its the only script i use
        HELP THEM WHO HELPS YOU



        i only work on wapdesire v_2 coding only

        Comment


          #5
          Originally posted by brand View Post
          i am after the code for wapdesire v_2 script its the only script i use
          just edit it accdg. to ur script..just follow the idea of checking if an acct. is online, delete its session and create new session..No one can do multiple logins in one acct.
          My Blog: http://jhommark.blogspot.com
          My Facebook: http://www.facebook.com/jhommark
          My Official Site: http://www.undergroundweb.tk
          My Community Site: http://undergroundwap.xtreemhost.com

          Comment


            #6
            aint the $main.= a spinoff of echo " dont ya just change $main and echo around dnt no never used the wapdesire_v2 but il give it ago

            Comment

            Working...
            X