try this:
PHP Code:
include("header.php");
global $db, $module_name, $prefix, $cookie, $user;
cookiedecode($user);
$username = $cookie[1];
$usercrew = $db->sql_query("SELECT user_crew FROM nuke_users WHERE username = '$username'");
$row = $db->sql_fetchrow($usercrew);
$user_crew = $row['user_crew'];
OpenTable();
$result = $db->sql_query("SELECT * FROM nuke_users WHERE username = '$username' and where user_crew = '$user_crew'");
$row = $db->sql_fetchrow($result);
echo ("$user_crew");
CloseTable();
edit: it seems a bit odd to have 2 queries thast are pretty much doing the same thing. what are you trying to do? lemme know, maybe we can combine the 2 queries in one.
Bookmarks