Jump to content

scootstah

Staff Alumni
  • Posts

    3,858
  • Joined

  • Last visited

  • Days Won

    29

Everything posted by scootstah

  1. And we've shown you how several times. Where are you stuck?
  2. Yes.
  3. Are you setting additional cookies in your login?
  4. Could be a cache issue.
  5. You cannot "change the form to PHP". PHP outputs HTML, you end up with the same HTML either way.
  6. I showed you how, right here:
  7. well, it's a large scale site, so everything on there can't be incorrect, (close though). However it is inconsistencies in a site like this that would make me question it's integrity. While I will say that some of the charts etc. that are on there can be helpful at times. The inconsistencies cause me to never recommend anything on it. I agree. I would never recommend it as a learning resource.
  8. So where would you put it then?
  9. There's all kinds of snippets and tutorials floating around for this. Here's the first result of a Google: http://snipplr.com/view/753/
  10. This is the best way, I think. Just make a config file and hard code the URL into it. You could always do a check that if the setting isn't set to try to guess the right URL. why would you need to make a config file. Why not? There should be several other things you would need such as database credentials. Why not put them in a common place?
  11. Did you read this?
  12. This is the best way, I think. Just make a config file and hard code the URL into it. You could always do a check that if the setting isn't set to try to guess the right URL.
  13. What is a "session error"?
  14. The difference is that when you call mysql_fetch_row() it advances an internal pointer to the next row. If there isn't another row, it returns false. So basically in the while statement as soon as you have advanced through all of the rows, the statement is false and thus the while loop fails.
  15. Something like... $options = array( '0.00' => '---', '1.00' => '1', '2.00' => '2', '3.00' => '3' ); $selected = '1.00'; foreach($options as $key => $val) { echo '<option value="' . $key . '" ' . ($key == $selected ? 'selected="selected"' : '') . '>' . $val . '</option>'; }
  16. If you are storing floats then you should use one of the float data types (float, double, real).
  17. I believe it is because the WHERE clause has to come after any JOINs.
  18. Indeed, but as a newbie it is also imperative that you test things out yourself and learn how they work.
  19. On the contrary, even though w3schools has misinformation like this, I still use it from time to time as a quick reference. It's pretty much always the top Google result, and usually has what I'm looking for right away. For example, the charts for HTML entities are quite handy.
  20. I think you want a right join instead of a left join. Also, you can't limit the join to less than the overall rows returned. If you return 5 rows but only 1 row matches the join, the rest will just be NULL.
  21. Do you have any code to illustrate what you are talking about? The only information that goes into the database is what you explicitly put in the query. The amount of form fields is irrelevant.
  22. You said you can't get the price because it's not in a form element, but I'm saying in addition to putting the price in the div update the hidden field as well. Then the price is in the form.
  23. Yes. $value = 'blah'; echo '<input type="text" name="something" value="' . $value . '" />';
  24. Why not just change the value of the hidden field as well?
  25. 1. I have no idea what you're talking about. 2. It entirely depends on the layout of your table and what the default values are.
×
×
  • 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.