keep a user logged

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • mahmoudsehsah
    New Member
    • Nov 2018
    • 7
    • 4.2.x

    keep a user logged

    how can make login and keep user inline when login on mobile android
    i make code with php

    define('CSRF_PROTECTION', false);
    require_once($vbpath.'includes/vb5/autoloader.php');
    vB5_Autoloader::register($vbpath);
    vB5_Frontend_Application::init('config.php');
    $api = Api_InterfaceAbstract::instance();

    $password = array(
    'password' => $_GET['password'],
    'md5password' => md5($_GET['password']),
    'md5password_utf' => '',
    );
    $extraAuthInfo = array();

    $response = $api->callApi('user', 'login2', array($_GET['username'], $password ,$extraAuthInfo,''));
    if (empty($response['errors'])){
    vB5_Auth::setLoginCookies($response, '', true);
    $responseData = array($response);
    $responsee = $api->callApi('user', 'fetchProfileInfo', array($response['userid']));
    $responseee = array($responsee);
    $responseeee = array('success'=>'1' , 'message'=>"تم تسجيل الدخول بنجاح", 'data2'=> $responseData , 'data'=> $responseee);
    echo json_encode($responseeee ,true);

    }else{

    $responseـ1 = array($response);
    $responseData = array('success'=>'0', 'message'=>"اسم المستخدم او كلمه المرور غير صحيحة" , 'data'=> $responseـ1);
    echo json_encode($responseData,true);

    }

    but user not onilne and show this user not logged why ?
  • Mark.B
    vBulletin Support
    • Feb 2004
    • 24286
    • 6.0.X

    #2
    We cannot provide assistance with custom coding.

    You should engage the services of a third party cider such as at https://vbmods.rocks or by asking at www.vbulletin.org

    MARK.B
    vBulletin Support
    ------------
    My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
    My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

    Comment

    • mahmoudsehsah
      New Member
      • Nov 2018
      • 7
      • 4.2.x

      #3
      hi ,
      it's api not custom code
      how can login with api

      Comment

      • Mark.B
        vBulletin Support
        • Feb 2004
        • 24286
        • 6.0.X

        #4
        Please stick to your other thread. Having two threads asking the same question is confusing and won't lead to any better answers.
        MARK.B
        vBulletin Support
        ------------
        My Unofficial vBulletin 6.0.0 Demo: https://www.talknewsuk.com
        My Unofficial vBulletin Cloud Demo: https://www.adminammo.com

        Comment

        Related Topics

        Collapse

        Working...