Join Up!
104886 members and counting!

 
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links 
search for in the  
previousstrspnstrtoknext
Last updated: Tue, 29 Oct 2002
view the printer friendly version or the printer friendly version with notes or change language to Czech | German

strstr

(PHP 3, PHP 4 )

strstr -- Encuentra la primera aparición de una cadena

Descripción

string strstr ( string pajar, string aguja)

Devuelve todo el pajar desde la primera aparición de la aguja hasta el final.

Si la aguja no es hayada, devuelve FALSE.

Si la aguja no es una cadena, se convierte a entero y se aplica como el valor ordinal de un caracter.

Nota: Nótese que esta función es sensible a mayúsculas y minúsculas. Para búsquedas no sensibles, utilice stristr().

Ejemplo 1. Ejemplo de strstr()

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

Vea también stristr(), strrchr(), substr(), y ereg().

User Contributed Notes
strstr
add a note about notes
There are no user contributed notes for this page.
previousstrspnstrtoknext
Last updated: Tue, 29 Oct 2002
Copyright © 2001, 2002 The PHP Group
All rights reserved.
This mirror generously provided by: http://phpbuilder.com/
Last updated: Thu Oct 31 18:34:28 2002 EST