|
Posted by Rik Wasmus on 01/11/08 23:14
On Fri, 11 Jan 2008 23:33:19 +0100, j1mb0jay <none@none.com> wrote:
> Is there a function in PHP that will return a boolean if a String
> contains another given String. As what I am trying to do is disallow
> input that contains ../ or something else that would allow directory
> traversal.
strpos()/regex etc. could be used for this, however, I'd use realpath() on
the results to check wether it's still 'safe'.
--
Rik Wasmus
Navigation:
[Reply to this message]
|