change $_SESSION single quotation mark problem and optimize mysql.php