Jump to content

Jessica

Staff Alumni
  • Posts

    8,968
  • Joined

  • Last visited

  • Days Won

    41

Everything posted by Jessica

  1. You shouldn't use the PASSWORD function in MySQL, it's not for that. You should use the php crypt() function, or something like PHPass. (Which I see you did in your second post, so that's good). Your salt function could be simplified by using an array, which you can build using array_merge(range('A', 'Z'), range('a', 'z'), range(0,9)). I would trim everything EXCEPT the password, but not just email. Names too. Edit: Also you need to work out your logic here: $fullname = $_POST['firstname']; if($firstname == '') { $errors[] = 'Please enter your firstname.'; } if($lastname == '') { $errors[] = 'Please enter your lastname.'; }
  2. Also if you only want one result limit the query to 1.
  3. First thing id do is make sure There is an index on the column. Sounds like its text, not the primary key.
  4. 1. Don't put variables in strings. $host, not "$host". 2. check for errors. See my signature on debugging SQL. 3. print_r($row) will show you what's in the row. You will not have an array key of "First Name" when you selected "first_name" (And you should never have an array key or column name with spaces.)
  5. Also, this has absolutely nothing to do with PhpMyAdmin...
  6. What the heck is a one-time recurring payment? One-time and recurring are literally opposites.
  7. Remove the entire section you've shown us...And put in your text.
  8. Sounds like $fileparts only has one value in it, since, 1-2 = -1.
  9. You don't need a tutorial for something that simple.
  10. Arrays start at 0. A 20 long array has keys 0-19
  11. tmp=tiles; tiles=tiles[swap]; tiles[swap]=tmp; You have two variables you want to swap. You need a third to hold one while you move the other. If I have two bowls filled with two soups, how do I get each soup into the other bowl? Soup A into bowl C Soup B into bowl A Soup C into bowl B
  12. Your original post had the score as 10. Post the actual query, and the actual tables?
  13. If you run that query in mysql (not PHP) with a left join you WILL get all the rows.
  14. Change your RIGHT to LEFT.
  15. Sounds fairly simple. Take a look at jQuery.
  16. Agreed, which is why I specified to capture and handle them. The way the OP is doing it sounds right. And no, you can't check the entire script for errors.
  17. If you're talking about MySQL errors, you should have discovered any syntax errors or other problems during development, and then prevent them from happening in the first place.
  18. It depends on the type of error, but you should be capturing and handling them all within your code.
  19. I think you need to tell it what column to fetch. Give you count an alias (like count_words) then you can fetch that column.
  20. How corny. Might be rice to learn it. $pdo is not defined. The error tells you. Look at your code carefully, what is $pdo?
  21. What's the actual output of the query? Do menuitem2 and 3 have the right customer name?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.