Jump to content

Maq

Administrators
  • Posts

    9,363
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by Maq

  1. Sure, if you post in Beta Test Your Stuff section.
  2. Firstly, that method has been deprecated as of PHP 5.3 and shouldn't be used or relied upon. Second, I recommend reading a basic tutorial on SELECT statements, so you can properly rewrite your code: http://www.w3schools.com/PHP/php_mysql_select.asp
  3. Sorry, the second terminating curly brace is in the wrong place. It should be: ('$timestamp','{$_server['remote_addr']}','{$_server['php_self']}'"); The reason is in my previous post.
  4. You can escape the array single quotes by placing curly braces around the associative array: ('$timestamp','{$_server['remote_addr']}','{$_server['php_self']'}");
  5. nerd is around.
  6. Could you post some of the relevant code?
  7. You can use array_unique but it's much more efficient to do it in MySQL whenever possible.
  8. As far as ease and understandability, I like writing it this way: echo "{$row['cname']}"; Some may argue on behalf of inefficiency but it only produces a minuscule amount of overhead to interpolate variables and arrays in strings.
  9. It would be a good idea to post the error.
  10. test.php?val=15&val2=guppt awonga The first variable is prefixed with the question mark, every variable after that is prefixed with the ampersand. You're also going to have a problem with that href link because there is a space, which needs urlencode invoked on it.
  11. hey listen you started it with your insult, i dont come here to be insulted , you can clearly see my physique in the picture Relax, it's a metaphor. And no it did not start with my insult, because I didn't insult you. Everything I said was and is true.
  12. I agree, Maq does appear to be an Actual Programmer, unlike some others. kevinkhan, have you come up with a solution?
  13. You're a manchild. 1) Why would he try that when we already have a proper working solution? 2) I think you meant to say, "the good old inefficient way". 3) Why in the world would you use an array when they made the DOM class and XPath for this specific reason? Come on Nadeem, that's just silly. dont be so narrow minded he could probably find it more interesting, manchild lol Coming from someone of your caliber, lack of skill and grammar, I could care less what you think. freal
  14. You're a manchild. 1) Why would he try that when we already have a proper working solution? 2) I think you meant to say, "the good old inefficient way". 3) Why in the world would you use an array when they made the DOM class and XPath for this specific reason? Come on Nadeem, that's just silly.
  15. freal ? Sorry, I don't understand what you're saying, I only speak English.
  16. does this class require any installastion reconfiguration ? importation linking ? or is it freely available in the environment It's "freely in the environment".
  17. I believe the normalize-space() method will also replace 2 or more spaces (even inside the string) and replace them with a single space. At least this is true in XSLT.
  18. That makes all the difference in the world. Finding a good book, finding a good tutorial, finding solid threads from forums etc... that are specific to what you are trying to learn or implement, is one of the toughest issues for people that are new to either the language or the concept in general.
  19. You can use the same concept as pagination. There is an excellent tutorial on phpfreaks that illustrates this: http://www.phpfreaks.com/tutorial/basic-pagination MatthewJ's code will grab 12 records, starting at the 12th, which will essentially grab 12-24 in a descending manner. This works once, but if you want something dynamic then I suggest you read the tutorial, specifically the MySQL of how CV keeps track of the pages and records.
  20. Maq

    Salathe

    Hi salathe, welcome to the forums.
  21. I think a better solution would be to use the DOMDocument class. With this approach you can extract what you need and use XPath to specify the exact nodes you want to filter out.
  22. What is the column in your table called (id, user_id)? You referred to two different ones so far. Anyway, it would be something similar to (assuming you want to specify an id): WHERE id = $user;
  23. Can you show us the table structures?
  24. Why can't you just cast it? Integer.parseInt(); Integer.toString();
×
×
  • 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.