|
Yeah and to do it affectively use MYSQL_NUM instead of MYSQL_ASSOC. MYSQL_ASSOC is marginally faster and more precise, but MYSQL_NUM is still the best choice. Also, that script SHOULD have worked if your session carried over from when he logged in..maybe you should use cookies. And that include syntax is wrong I think..it should be include ("./filename"). But too make it more secure, you should do (instead of resuming the session)
if (isset($_SESSION['username'])) { //Do REST
i think thats your problem, man. I can spot a lot of errors. On the line where it wont let you in:
die("<b>You do not have access to this file!.</b>")
Use an ob_start at the top, so you can call a header function anywhere in the script, and then add a header below the die, leading back to the main page (redirection). After the header use ob_end_clean and then ob_end_flush to send the data to the web. Okay?
|