Jump to content


Photo

Info help.


  • Please log in to reply
2 replies to this topic

#1 Dobakat

Dobakat
  • Members
  • PipPipPip
  • Advanced Member
  • 54 posts

Posted 28 May 2006 - 09:27 PM

Well I have a clan page for a game calleld tibia. For user to register at my site I want them to prove that the y own a character in the real game. I give them a random code so they put in the comment part of their character status..a page that looks like this..
[a href=\"http://www.tibia.com/community/?subtopic=character\" target=\"_blank\"]http://www.tibia.com/community/?subtopic=character[/a]
Then I want to check that they putted the code and allow them to keep going with their registration. The only problem is that I don't know how to amke it look for the code..Can someone please help me..

#2 poirot

poirot
  • Members
  • PipPipPip
  • Advanced Member
  • 646 posts
  • LocationAustin, TX

Posted 28 May 2006 - 11:58 PM

OK, you can use PHP's file handling functions.
[a href=\"http://www.php.net/fopen\" target=\"_blank\"]http://www.php.net/fopen[/a] (if allow_url_fopen is enabled).

But this means you'd need an URL that opens the profile page (directly), or you would have more trouble, coding something that sends POST as well. Actually I coded something like that for you once:

[a href=\"http://www.phpfreaks.com/forums/index.php?showtopic=91480\" target=\"_blank\"]http://www.phpfreaks.com/forums/index.php?showtopic=91480[/a]
~ D Kuang

#3 poirot

poirot
  • Members
  • PipPipPip
  • Advanced Member
  • 646 posts
  • LocationAustin, TX

Posted 29 May 2006 - 07:09 AM

You just need to use strstr() to check if the random code is in the comments:

[a href=\"http://www.php.net/strstr\" target=\"_blank\"]http://www.php.net/strstr[/a]
[ strstr( haystack, needle ) ]
~ D Kuang




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users