Announcement

Collapse
No announcement yet.

User name variable

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

  • User name variable

    I have the default global variable [usr_login] for user login. What is the global variable for User full name?

    Thanks.

  • #2
    Easy to find out, look into you sec_logon application in the onvalidate event.
    Albert Drent
    aducom software netherlands
    scriptcase partner, reseller, support and (turn-key) development
    www.scriptcase.eu / www.scriptcase.nl

    Comment


    • #3
      I have this code on ONVALIDATEEVENT:

      $slogin = sc_sql_injection({login});
      $spswd = sc_sql_injection(({pswd}));

      $sql = "SELECT
      priv_admin,
      active,
      name,
      email
      FROM seg_users
      WHERE login = $slogin
      AND pswd = ".$spswd."";

      sc_lookup(rs, $sql);

      if(count({rs}) == 0)
      {
      sc_log_add('login Fail', {lang_login_fail} . {login});
      sc_error_message({lang_error_login});
      sc_error_exit();
      }
      else if({rs[0][1]} == 'Y')
      {
      $usr_login = {login};
      $usr_priv_admin = ({rs[0][0]} == 'Y') ? TRUE : FALSE;
      $usr_name = {rs[0][2]};
      $usr_email = {rs[0][3]};
      sc_set_global($usr_login);
      sc_set_global($usr_priv_admin);
      sc_set_global($usr_name);
      sc_set_global($usr_email);
      }
      else
      {
      sc_error_message({lang_error_not_active});
      sc_error_exit();
      }

      What is my user full name variable?

      Thanks!!!

      Comment


      • #4
        Hi,

        You must use [usr_name]

        Comment

        Working...
        X