# Login Form Help as3

**URL:** <https://forum.kirupa.com/t/login-form-help-as3/325552>\
**Category:** flash\
**Created:** [October 22, 2011, 1:22pm UTC](https://forum.kirupa.com/t/login-form-help-as3/325552 "2011-10-22T13:22:59Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![duchman](https://avatars.discourse-cdn.com/v4/letter/d/91b2a8/32.png) [@duchman](https://forum.kirupa.com/u/duchman)\
**Post date:** [October 22, 2011, 1:22pm UTC](https://forum.kirupa.com/t/login-form-help-as3/325552/1 "2011-10-22T13:22:59Z")

</div>

I have two arrays of strings  
containing usernames and passwords for login,

```auto

var uN:Array;
var pW:Array;
uN = ["fla","fli","flu"];
pW = ["adv","advi","advu"];

```

I need to do a function which will compare the positions of certain string from one array  
with position of string from another.And get something like

```auto

if(username.text == uN[0] && password.text == pW[0]){
        logIn();
    }

```

So “fla” is match with “adv”.  
How can I infact mach other usernames with passwords to allow login, without doing a row of “if”  
statements for each string to match appropriate one?  
Thanx
