Quote:
Originally Posted by Glad2BeHere
I can use which mysql functions i feel free to use because its what i am comfortable using
|
Are you aware that the MySQL extension you are using has been deprecated from PHP? You should definitely use MySQLi or PDO.
What I am mostly concerned is the vulnerability to MySQL injections. That's something you should fix ASAP.
Quote:
Originally Posted by Glad2BeHere
Not necessary to start @ the top as its where i want to start the session
|
PHP starts a session by sending a cookie containing an unique session ID to the browser. Cookies must be sent at the same time as the rest of the headers are (i.e. the very first thing the page sends). Otherwise it does not work (depends on the server configuration, but usually it doesn't). You could use output buffers to overcome the issue, or just move the start_session to the beginning of the source.
And I agree with R@f about this:
Code:
echo"<html><head>header('Content-type:image/jpg');</head></html>";
What on earth is that? It's unnecessary and wrong. You are basically making another page, and echoing, not executing PHP's header function. Also, that header should be only sent, if your page contains nothing but the image, and should be treated like an image. if you're setting a background image, you shouldn't use it. Remove the line and everyone is happy.