Rommeo Posted April 16, 2011 Share Posted April 16, 2011 <?php $string = "aStringwith SomeSpecialChars+^$%"; // want to check if there is "+" in it if( ????? ($string,'+') { echo "yes string has plus sign"; } ?> Which function should I use to search in a string ? Quote Link to comment https://forums.phpfreaks.com/topic/233872-searching-in-a-string/ Share on other sites More sharing options...
cyberRobot Posted April 16, 2011 Share Posted April 16, 2011 You could try out strpos() http://php.net/manual/en/function.strpos.php Quote Link to comment https://forums.phpfreaks.com/topic/233872-searching-in-a-string/#findComment-1202242 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.