How to assign every different client a different ID
<p>I want my login page to have like a secure area, like say every time you visit my website the site assigns your IP or client a unique code (something like "A5K3JFSH54" something random) and then if that client say presses F12 and it comes up with a alert box saying "F12 was pressed!" and it bans that clients ID from the website and every time they enter the site it automatically sends them to a page called banned.php or something along the lines.</p>

<p>I already have the code which detects the F12 being pressed...</p>

<pre><code>document.onkeydown = function(evt) {
    evt = evt || window.event;
    if (evt.keyCode == 123) {
        alert('F12 was pressed!');
        window.location.href = "/banned.php";
    }
};
</code></pre>

<p>But I'm pretty much lost on how to assign each client a certain ID and if that ID is banned automatically send them else where and cannot access any other page.</p>