PHP - testing string for a %

Associate
Joined
3 Oct 2004
Posts
68
Location
Biggin Hill
How can I test in PHP to see whether a string set to a variable has a % (percentage sign) in it? I have tried to using preg_match, but this seems to be set to true for all strings.

In perl I can simply use: if $row =~ /$/

Any help would be very greatfully received

Many Thanks
 
Back
Top Bottom