Jump to content

Maq

Administrators
  • Posts

    9,363
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by Maq

  1. You need a JOIN and a WHERE clause. That's about the extent of the help I can give without more information, such as table and field names, what you want to extract, etc...
  2. Depending on the site you can use file_get_contents or, if the site requires posts (i.e. login), you would have to use cURL. The first option would look something similar to: $url= "http://www.blah.com"; $conn = fopen($url, "r"); $html = file_get_contents($url); fclose($conn); echo $html; ?>
  3. Assuming that's on another page you need to include session_start before you can access the sessions just like when you assigned the value.
  4. Why don't you use the MySQL date functions instead?
  5. I thought the same thing.. turns out, it's simply recursive, so while the first P represents PHP, it is not a representation of Personal Home Page - if that's what you meant). I was trying to dig up a thread that delved into this topic once... (oh, found it). That's all revisionist BS. It was indeed named for Personal Home Page. I was working in the web dev business at the time, and knew some of the early PHP contributors. I'm not sure why they're ashamed of the name these days -- guess they think it went out of fashion. It's probably because PHP is geared towards bigger and better things now. There are plenty of solid frameworks, CMS's, enterprise applications, etc... It's not just for adding some dynamic content to your "personal home page" anymore. Besides, I think that name makes it sound so, amateurish.
  6. That will only go up to 9. Change it to $i johnsmith, A little googling and you could have easily gotten the answer to this. Please make an attempt yourself first.
  7. The print_r($ip); prints out an array right? Try changing these last lines. $input = implode("\n", $ip); file_put_contents("out.txt", $input);
  8. I am using a firefox addon web developers.. It gets all the form elements. And by using these elements i can do posting.. i.e. URL?title=something&subject=something etc etc... Ok, so you can do posting, where do you want to post? What do you want to do with posting? Sorry, I'm still confused, maybe an example?
  9. That should work, can I see the current code?
  10. What exactly are you trying to accomplish? Where is this element list coming from? I'm pretty confused right now.
  11. If you put them both into arrays you can use - array_diff.
  12. Please tell us your definition of "doesn't work". Put them in or the '#' sign.
  13. Please properly format and indent your code, it makes debugging much easier.
  14. Did I really not see that? wow... In my defense the OP didn't state that was the problem. Do you still need to show that 'admin' posted the message?
  15. Can we see your relevant current code?
  16. Nice, so does that do exactly what you want?
  17. That's exactly what you're doing here: Where does the value of '$username' come from?
  18. I guess I'm confused here. Check the database to see what group the '$username' is in?
  19. There are a multitude of tools that you can get via plug-in for your browser (i.e. - SQL Inject ME), to test your applications with.
  20. Have you read about this function in the manual - mysql_real_escape_string?
  21. Just like you did in your second code excerpt, except in your query use '$username' rather than the POST variable.
  22. Picks it up for me. How are you displaying the matches? print_r($match3); Also, if you put your pattern in double quotes you won't need to escape all the inner single quotes.
  23. You can read more in the manual - foreach.
  24. It's all rendered as HTML by the browser in the end, it doesn't matter if you just put in raw HTML or echo it out.
×
×
  • 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.