★ wanayoo — archive 1999 http://www.php.net/manual/fr/function.strstr.phpNouvelle recherche | Portail wanayoo

PHP Home Page

Manual Table of Contents
Up to Chaînes
Quick Reference
English version of this pageGerman version of this pageJapanese version of this pageItalian version of this pageHungarian version of this page
Chaînes
* AddCSlashes
* AddSlashes
* bin2hex
* Chop
* Chr
* chunk_split
* convert_cyr_string
* count_chars
* crypt
* echo
* explode
* flush
* get_html_translation_table
* get_meta_tags
* htmlentities
* htmlspecialchars
* implode
* join
* ltrim
* md5
* Metaphone
* nl2br
* Ord
* parse_str
* print
* printf
* quoted_printable_decode
* QuoteMeta
* rawurldecode
* rawurlencode
* setlocale
* similar_text
* soundex
* sprintf
* strcasecmp
* strchr
* strcmp
* strcspn
* strip_tags
* StripCSlashes
* StripSlashes
* stristr
* strlen
* strpos
* strrchr
* str_repeat
* strrev
* strrpos
* strspn
* strstr
* strtok
* strtolower
* strtoupper
* str_replace
* strtr
* substr
* substr_replace
* trim
* ucfirst
* ucwords
Manual: strstr
View the source code for this pageSearch the site



Previous page
 strspn
 Updated
Sun, 06 Aug 2000
strtok 
Next page


strstr

(PHP3 , PHP4 )

strstr -- Trouve la première occurence d'une chaîne.

Description

string strstr (string haystack, string needle)

Retourne toute la chaîne haystack à partir de la première occurrence de needle, jusqu'à la fin.

Si needle n'est pas trouvé, retourne FALSE.

Si needle n'est pas une chaîne, elle est convertie en entier, et utilisée comme valeur ordinale d'un caractère.

Exemple 1. Exemple avec Strstr()


$email = 'sterling@designmultimedia.com';
$domain = strstr ($email, '@');
print $domain; // affiche designmultimedia.com
      

Voir aussi stristr(), strrchr(), substr(), et ereg().


 About Notes


Previous page
 strspn
 Updated
Sun, 06 Aug 2000
strtok 
Next page





Who's responsible for this?
Top of this page

Site
Hosting:



Located in
United States
Elements of this website are subject to copyright.
Questions about installing or using PHP should be directed to one of the mailing lists.
Only questions about the website should be directed to webmaster@php.net.