Jump to content

trq

Staff Alumni
  • Posts

    30,999
  • Joined

  • Last visited

  • Days Won

    26

Everything posted by trq

  1. You should read this: http://www.phpfreaks.com/forums/index.php?topic=323280.0 Seriously, if your not using a framework you have rocks in your head. Your code looks like a mix of jQuery and vanilla JavaScript. If you really are using jQuery, take a look at there Ajax functionality.
  2. if ($result =mysql_query("SELECT id, username FROM users WHERE lastvisit > '$tm' and online='ON'")) { if (mysql_num_rows($result)) { while ($row = mysql_fetch_array($result)){ echo "<tr><td><a href=\"profile.php?id={$row['id']}\">$row['username']</td></tr>"; } } } ?> Then on profile.php have a query that uses the value passed in through $_GET['id'] to that gets a users details.
  3. trq

    PHP PDO

    Did you notice that most other peoples code here is syntax highlighted and easy to read? tags do that.
  4. trq

    Adobe Shadow

    Yeah we've been using this at work since it came out. Awesome tool!
  5. There is some docs in my framework that might help shed some light on the subject: http://proemframework.org/docs/services-component.html, but there are plenty of other resources around as well. Symfony has a good description in there docs too.
  6. I personally don't like the overhead, or the idea of having to learn some other syntax. You can achieve the same goals using php alone.
  7. Your code makes little sense. $this->filename should be set to your template. Anyway, why re-invent the wheel? If you must use a template engine of some sort (which I would recommend against) there are plenty of solutions already out there.
  8. I've not done much testing to be honest, but it seems to be a chrome issue. Iv'e only looked at it in FF and Chrome and the webkit browser on my phone (not chrome). In chrome, sometimes the tree only partially renders. Also, in the webkit browser on my phone (not chrome, I'm not sure what it is, some generic webkit thing that comes with android) the tree in the background (on the doc pages) wont stay in a fixed position. This is less of an issue, but still it bugs me. Everything works as expected in FF.
  9. And this is exactly what ends up happening if you hang out in irc long enough. You don't meet people in real life and say "hey, let's be friends", it's something that happens over time through conversation and just hanging out.
  10. I'm not a code ignitor user, but something like: $this->session->set_userdata('history', array_merge($this->session->get_userdata('history', $history)); should do the trick.
  11. A username and password are part of a User. Authentication and Logging in are completely separate.
  12. It's not really the same output either. Similar.
  13. This topic has been moved to MySQL Help. http://www.phpfreaks.com/forums/index.php?topic=356031.0
  14. Or you could just use var_export. echo '<pre>' . var_export($var, true) . '</pre>';
  15. This topic has been moved to Application Design. http://www.phpfreaks.com/forums/index.php?topic=356029.0
  16. There is no "better way", if your functions require a database connection, you need to pass it to them.
  17. This topic has been moved to JavaScript Help. http://www.phpfreaks.com/forums/index.php?topic=356022.0
  18. Variables are not interpolated within single quotes. You should also receive a parse error because of the missing quotes around id. $id = $emp_det[0]['id'][$t];
  19. No body else got any input? I seem to be having some rendering issue with the tree in the background on occasion on the documentation pages. Would nice to get some help with that.
  20. They come as part of the examination package. Take a look at the details on Zend's site.
  21. if (is_array($vbulletin->GPC['user']['membergroupids']) { foreach ($vbulletin->GPC['user']['membergroupids'] AS $key => $val){ $groups .= "{$val},"; } }
  22. trq

    GET and IF

    I'm not sure what you quite mean.. At the top of your script you define $code: $code = $_GET['code']; Then never use it for anything.
  23. Your question is unrelated to mysql. There are plenty of charting libraries around written in both PHP and JavaScript amongst others. Try Googling.
  24. Without a description of the problem, no.
×
×
  • 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.