Something like this, just change the code for your cookie number. Note the '.' in the cookie name is translated to a '_' with PHP.
If the cookie is present, it extracts a couple of values from it and then uses a large if/else construct around the HTML. It means that you can still use your HTML editing software to format all your HTML correctly and have the logged-in and not-logged-in parts on the same page. Just add this into the body of your HTML page and change the extension to PHP.
<?
if (isset($ubber2452191_1937)) {
$ubbinfo = split("&",$ubber2452191_1937);
$ubbdisplayname = $ubbinfo[2];
$ubbmemberid = $ubbinfo[4];
?>
Hi <?=$ubbdisplayname?>, you're logged in, here's some HTML.
<?
} else {
?>
Sorry, you're not logged in.
<?
}
?>