Justtechjobs.com Find a programming school near you






Online Campus Both


php3-list | 199901

[PHP3] strstr From: ccunning <email protected>
Date: 01/30/99

Maybe I have to use a regexp, but since the str functions are faster, I'm trying
to use this. strstr() is supposed to return the rest of the string if an
occurance is found, or false if it's not found. I did a

if (!strstr("Re:", $string)) {
        $string = "Re: $string";
}

Which should add Re: before the string if it doesn't already contain Re:. But,
when I try it, if string is "Re: some text", then it makes $string = "Re: Re:
some text".

--
PHP 3 Mailing List   http://www.php.net/
To unsubscribe send an empty message to php3-unsubscribe <email protected>
To subscribe to the digest list:  php3-digest-subscribe <email protected>
For help: php3-help <email protected>  Archive:  http://www.php.net/mailsearch.php3
List administrator:  zeev-list-admin <email protected>