Jump to content

Jessica

Staff Alumni
  • Posts

    8,968
  • Joined

  • Last visited

  • Days Won

    41

Everything posted by Jessica

  1. There's always a better way.
  2. You should always post your actual code, and the entire relevant part. Of course we're going to point out you don't echo it. If you're echo'ing it outside of the loop, that's probably a big part of the problem.
  3. Since the font is not monospaced, you cannot know the numbers of characters per line. You can fit many more "i"s into one line than "m"s.
  4. Normalize your data. You should never store an array of values in one column. You need a separate table for that.
  5. You keep saying the files are "marked". The only one that is actually named php.ini is the one that matters. They can't ALL be named php.ini
  6. You literally cannot have 3 files in the same directory with exactly the same name.
  7. It doesn't load at all.
  8. I did figure that out, I went through and figured what each color was assigned to and moved them around a bit. I like it now.
  9. Since there's no evidence OP is using any third party software, and this is a MySQL question, I'm moving it to the right forum.
  10. Also, it has nothing to do with PHP. There is no such thing as a PHP MySQL Join.
  11. So, another person who doesn't get that it's not about the ls command...
  12. If the server is offline, you need to start it up. ... in your programs menu there should be a big Start Wampserver. Or right click on the w and choose the start/restart/whatever looks right. Then go to http://localhost/helloworld.php The file should be in /wamp/www/
  13. Think about the logic of that. "SELECT COUNT(*) from users WHERE username = '$uname'" - if the count is 0, then the username does NOT exist already. If it's 1 or more, it DOES exist. You're saying the opposite. But still, mysql_num_rows WILL ALWAYS RETURN 1 ROW on a count, unless the query fails completely.
  14. You're selecting the STRING username from the table. Like "SELECT "foo" from bar" It doesn't matter what else comes after that, because "foo" is a string.
  15. You'd need some logic that tells you which form they are filling in. It can be as simple as a hidden input. Then before doing any processing, check which value was sent for that name, and then use the right logic.
  16. I'm pretty sure you can't use bindParam on a column name. Only values.
  17. If the rows == 0, you are alerting that the username exists. Otherwise if the rows == 1 or 2 or anything other than 0, you add the values. Logic... The bigger problem is that the num_rows will ALWAYS be 1, since you're selecting a single row with a count.
  18. is form_error a function native to CI or your own? Either way, it needs to know which form you are working with, and there's no argument passed to it to tell it. You may be able to get around that by changing things like $data = array( 'name' => 'email', 'class' => 'input', 'placeholder' => 'Email'); echo form_input($data, set_value('email')); to $data = array( 'name' => 'email_login', 'class' => 'input', 'placeholder' => 'Email'); echo form_input($data, set_value('email_login')); (or _create, whichever)
  19. http://bit.ly/O2LNyD
  20. Don't run queries inside of loops! You need to use a JOIN.
  21. It's already there, on lines 103-104...
  22. If they're only allowed to SELECT, they can't mess up anything. Give them a user account which does not have any UPDATE or DELETE privileges.
  23. Exactly - remove it from the original place, and only output it when displaying. If you don't like that you can assign the formatted one to a new var, and use that as your display, then have the original value still intact.
×
×
  • 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.