Jump to content


Photo

Learning out


  • Please log in to reply
1 reply to this topic

#1 Darkness Soul

Darkness Soul
  • Members
  • PipPipPip
  • Advanced Member
  • 133 posts
  • LocationBrazil; São Paulo.

Posted 27 April 2006 - 01:47 PM

Hi guys,

I'm learning about that preg_replace, but, all tutorials I have found, have no info about how to use it as well.. I mean that mixed pattern field..

Like this exemple.. it was suppose to secury an url from a user or form to call in the require/include..

$url = $_POST['url']
$url = preg_replace ( '@\.\.*@' , '.' , $url );
require ( $url );
So, what the frell is that '@\.\.*@'..? o-o

^^ Thank you..

D.Soul
(If something is wrong, please tell me. I'm learning this language. Thank you)

#2 ober

ober
  • Staff Alumni
  • Advanced Member
  • 5,337 posts
  • LocationEast Coast, USA

Posted 27 April 2006 - 02:07 PM

Spend some time with this website... hopefully it'll help you: [a href=\"http://www.regular-expressions.net/\" target=\"_blank\"]http://www.regular-expressions.net/[/a]

Info: PHP Manual





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users