Jump to content

stevevan

Members
  • Posts

    3,521
  • Joined

  • Last visited

Everything posted by stevevan

  1. power
  2. lion
  3. needle
  4. PARTY!!! Kick Me
  5. ball
  6. assistant
  7. boy
  8. Anyone know of any that work on various flavors of Unix?
  9. small
  10. space
  11. In case any ex-military are reading this, when we had bases in the Philippines, July 4th used to be Phil-Am Friendship day. It was celebrated by consuming lots of food and adult beverages with our host country. Quite the blast! woooot
  12. stuck
  13. rodent
  14. white
  15. penicillin
  16. fun Naughty
  17. science
  18. I don't know if it's the caffine kicking in or what, but I'm making headway. I've determined that for some reason, the password() server function was causing the problem. I solved this problem by setting my field type in my table to varchar(16) (it was set to a length of 15) and set the attributes to BINARY. I'm assuming that the field type needed to be a length of 16 because of the BINARY attribute, but I really don't understand the PASSWORD() function all that well. Can anyone explain a little better than the book(s) I have so I can understand the why's and wherefore's? Is it really THAT secure or is it just a "warm fuzzy"?
  19. slice
  20. ok...answered my own question. The SELECT query was selecting a column name that wasn't in the table. That problem solved. Now, trying to figure out WHY no data was returned. I verified that there is data in the table and I was entering the correct information. Any PHP guru's think you can help by looking at the code? (All part of the fun of learning PHP!)
  21. cover
  22. (do I dare say it? Ok...I will!) sex
  23. view
  24. Given the proactive attitude of TCH, I wouldn't worry too much. But this is just another reason why one makes regular backups!
  25. Received the following error on the webpage: Here's the code in question: >// define function auth_user() function auth_user($username, $userpassword) { // Set up global variables to connect to the database and "Referee" table global $default_dbname, $user_tablename; $link_id = db_connect($default_dbname); /* Now that we're connected, create a query for a record whose "username" and "userpassword" entries correspond to the user-provided arguments, then select the Tempusername value for that record. Note that $userpassword is encrypted BEFORE it is compared with the value in the Referee table. This compares two encrypted values which have been derived by exactly the same process and will therefore (in theory anyway!) be identical. */ $query = "SELECT Tempusername FROM $user_tablename WHERE username = '$username' AND userpassword = password('$userpassword')"; $result = mysql_query($query); /* If no records match both criteria, we should return "False". Otherwise, we fetch and return the "Tempusername" value for that record. */ if(!mysql_num_rows($result)) return 0; else { $query_data = mysql_fetch_row($result); return $query_data[0]; } } I know I'm missing something with the mysql_num_rows function, but my mind is fried from looking at this all night last night and most of today. Any thot's or helpful words would be MOST helpful!
×
×
  • Create New...