Ok, function:

```
function session_login_name($username) {
                global $myDB;
                global $config;
                $query = "SELECT /* page == login, functions.php */id, username FROM members WHERE username = '".$username."' LIMIT 1";
                $result = $myDB->Execute($query) or die(GetDbError($myDB->ErrorMsg()));
                $nick_show = $result->Fields("username");
                $nick_id = $result->Fields("id");
                $arr = array($nick_show, $nick_id);
                return $arr;
}

```

In next file i need describe:

```
$_SESSION['userid'] = ;   //user id
$_SESSION['username'] = ; //user name

```

How do I do that?
If question unclear, just say it...
Oh, and print\_r ($arr) gives: Array ( [0] => zero [1] => 4 )

I have tried (guessed), but that of course isn't correct :/

```
echo session_login_name($username[0]);
die();

```