Jump to content

AyKay47

Members
  • Posts

    3,281
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by AyKay47

  1. You can't mix a normal if (/*something*/) { with an endif;
  2. Good catch, OP look at the error, as it will give you clues as to what is wrong. Notice that it states a parse error not a mysql error, this hints that there is an issue with the php syntax. Also, endif; if for an if(): statement, I don't see that syntax in your code.
  3. $range = $rowShowIng['keyno']; $arr = explode(',', $range); print_r($arr);
  4. One thing that is wring is the <body> and <html> tags are ended before you output the table.
  5. Great, what was wrong?
  6. that's terribly inefficient.
  7. If you are using *nix, table and db names are case-sensitive, so watch out for that. That is if you are sure that you have a table `Textiles` in the db `helenowen`
  8. The typical way would be to store the path to the file in the database. Yes that would be a varchar field.
  9. well check the tables, because the one you are trying to query doesn't exist on the server.
  10. is the database structure the same as localhost? As I stated before, if you are trying to use a select statement on a db name, it won't work, it has to be a table name.
  11. post EXACTLY what you receive. It will post an error along the the SQL.
  12. yah, that's an implicit join.
  13. then use the script I posted in reply #6 and post the results.
  14. oh, that's a different ballgame. 1. don't name the variable $table if it's not a table. 2. You can't query a db like that, so this depends on what you want to do?
  15. output the SQL to see what it looks like: $query = mysql_query("SELECT * FROM sub_nav WHERE subNav_ID=" . mysql_real_escape_string((int)$id)); $row = mysql_fetch_assoc($query); $table = $row['subNavName']; if($row['show_hide'] == 1) { $sql = "SELECT * FROM $table"; $query = mysql_query($sql) or die(mysql_error() . '<br />' . $sql); while($row = mysql_fetch_assoc($query)) { ?>
  16. Use a JOIN along with COUNT(). Have you tried anything thus far?
  17. Learn to use JOINS
  18. $query = mysql_query("SELECT * FROM ('$table')"); this is not what you had in your OP, and makes a big difference, as it's invalid syntax. The way you wrote it in your OP is how it should be written, as long as $table is just a table name.
  19. What does $table hold? There is an error in the SQL most likely. Post all of the relevant code, including the mysql_Fetch_assoc() call.
  20. You'll want to create a function that will query the desired results, then setup some ajax to get to that script and put it in a setInterval() call to call the function every x seconds. As to the server, if it's a simple query like that it shouldn't be an issue, just don't call the function every 5 milliseconds.
  21. here to get you started.
  22. The load method is the simplest way to grab data from the server, and it doesn't provide much flexibility. You can use the jquery AJAX API and return an object with the various data that you want to inject, and inject it where you want.
  23. In your query you will compare the timestamp field to NOW()
  24. run these lines: mysqladmin -u root password new_password mysqladmin flush-privileges grant all privileges on *.* to root@localhost identified by 'new_password';
  25. perhaps with a js lib or html5 canvas, google it.
×
×
  • 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.