I think you're missing an opening curly brace after the "else". Also, you need to "fetch" query result row data from your result ID which is returned by mysql_query() (see below).
Also, if you are using a tutorial or book that is instructing you to use session_register and $HTTP_SESSION_VARS, the first thing I'd suggest is to stop using that resource and move on to one that is more up to date. All you need to store and read session values is to start each page with session_start(), and to save/read your session values from the $_SESSION super-global array.
Therefore, once you've validated the info from the login form, all you need is:
else
{
session_start();
$row = mysql_fetch_assoc($result); // you must fetch data from query result
$_SESSION['id'] = $row['unique_id'];
$_SESSION['validated'] = 1;
header("Location: console.php");
}
Then on any page that you only want accessed by logged in users:
<?php
session_start();
if(!isset($_SESSION['validated'] or $_SESSION['validated'] != 1)
{
// redirect to login page
}
// ...rest of page...