I am building a site where the users are allowed to have one account per IP.
I am looking for a way to display users with the same IP using PDO mysql…
Here is what I got…
$q = $dbc -> prepare ("SELECT login_ip FROM accounts");
$q -> execute();
$duplicate = $q -> fetch(PDO::FETCH_ASSOC);
This will fetch everyones’ IP addresses. How can I then see if there is any exact matches and show them??
This will list you all possible duplicate IPs.