fetchq("SELECT * FROM pmsgs,pmsgs_text WHERE id=$id AND id=pid"); if (!$log) { require_once 'lib/layout.php'; errorpage("Couldn't get the private message. You are not logged in.",'log in (then try again)','login.php'); } elseif (!$msg || (($msg['userto'] != $loguserid && $msg['userfrom'] != $loguserid) && !$isadmin)) { require_once 'lib/layout.php'; errorpage("Couldn't get the private message. It either doesn't exist or was not sent to you.",'your private message inbox','private.php'); } if ($isadmin && $msg['userto'] != $loguserid) $pmlinktext = "".$sql->resultq("SELECT name FROM users WHERE id=$msg[userto]") . '\'s private messages'; else $pmlinktext = "Private messages"; $user = $sql->fetchq("SELECT * FROM users WHERE id=$msg[userfrom]"); $windowtitle = "$boardname -- Private Messages: $msg[title]"; require_once 'lib/layout.php'; $top = "
$fonttag$boardname - $pmlinktext - $msg[title] |