php/mysql account activation

前端 未结 3 869
一整个雨季
一整个雨季 2021-01-29 10:43

Everything in my new website is working just fine, except that I can\'t get this piece of code to work:

$query = mysql_query(\"SELECT * FROM members WHERE userem         


        
3条回答
  •  失恋的感觉
    2021-01-29 11:01

    Everything in my new website is working just fine

    ...until something goes wrong.

    You have to learn how to handle errors.

    run all your queries at least this way.

    $query  = "SELECT * FROM members WHERE useremail = '$useremail'"
    $result = mysql_query() or trigger_error(mysql_error()." ".$query);
    

    and you always be notified of any error and it's reason

    or implement any other way of error notifications, employing mysql_error() function which is the only thing in the world that can tell you where the actual problem is.

提交回复
热议问题