I think your problem is in your doLogin.php
In this routine you select all the distinct name from the users table
[php]//Get currently in use usernames based on latest posts
$names = array();
if($query = $con->query(“SELECT DISTINCT name FROM users”)){
while($result = $query->fetch_assoc()){
$names[$result[‘poster’]] = $result[‘poster’];
}
}[/php]
But you don’t reference the name column, you reference “poster” that’s not part of your query.
It should most likely be this…
[php]//Get currently in use usernames based on latest posts
$names = array();
if($query = $con->query(“SELECT DISTINCT name FROM users”)){
while($result = $query->fetch_assoc()){
$names[$result[‘name’]] = $result[‘name’];
}
}[/php]