<?php if ($_GET['p']) { $p = intval($_GET['p']); $postid = $DB_site->query_first("SELECT postid FROM " . TABLE_PREFIX . "post WHERE import_id = $p"); header("Location: http://www.yoursite.com/forum/showthread.php?" . p=$postid#$postid); } else if ($_GET['t']) { $p = "t=" . intval($_GET['t']); } ?>