If you add the vbulletin userid to the user table, it's a simple matter to check to see the userid of the user on the page. You just check for $vbulletin->userinfo[userid]
Once you know that, you can do several things. You can check to see if that userid is listed in your custom database. If it isn't, show the no permission page.
If it is, send them to an edit form for their profile.
You don't necessarily have to use a login script on your page. You could do this:
Code:
require_once('./global.php');
$userid = $vbulletin->userinfo[userid];
if(!$userid)
{
print_no_permission();
}
else
{
// query the custom database to see if userid is in there
// if it is, show your edit form
// if it's not, throw the user out.
print_no_permission();
}
That's a rough start. If you run into trouble, use print statements to verify that you are seeing the correct userid, etc.