<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <HTML ><HEAD ><TITLE >iconv_strrpos</TITLE ><META NAME="GENERATOR" CONTENT="Modular DocBook HTML Stylesheet Version 1.79"><LINK REL="HOME" TITLE="Manual do PHP" HREF="index.html"><LINK REL="UP" TITLE="iconv Functions" HREF="ref.iconv.html"><LINK REL="PREVIOUS" TITLE="iconv_strpos" HREF="function.iconv-strpos.html"><LINK REL="NEXT" TITLE="iconv_substr" HREF="function.iconv-substr.html"><META HTTP-EQUIV="Content-type" CONTENT="text/html; charset=UTF-8"></HEAD ><BODY CLASS="refentry" BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#840084" ALINK="#0000FF" ><DIV CLASS="NAVHEADER" ><TABLE SUMMARY="Header navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TH COLSPAN="3" ALIGN="center" >Manual do PHP</TH ></TR ><TR ><TD WIDTH="10%" ALIGN="left" VALIGN="bottom" ><A HREF="function.iconv-strpos.html" ACCESSKEY="P" >Anterior</A ></TD ><TD WIDTH="80%" ALIGN="center" VALIGN="bottom" ></TD ><TD WIDTH="10%" ALIGN="right" VALIGN="bottom" ><A HREF="function.iconv-substr.html" ACCESSKEY="N" >Próxima</A ></TD ></TR ></TABLE ><HR ALIGN="LEFT" WIDTH="100%"></DIV ><H1 ><A NAME="function.iconv-strrpos" ></A >iconv_strrpos</H1 ><DIV CLASS="refnamediv" ><A NAME="AEN80699" ></A ><P > (PHP 5)</P >iconv_strrpos -- Finds the last occurrence of a needle within a haystack</DIV ><DIV CLASS="refsect1" ><A NAME="AEN80702" ></A ><H2 >Descrição</H2 >int <B CLASS="methodname" >iconv_strrpos</B > ( string haystack, string needle [, string charset] )<BR ></BR ><P > In contrast to <A HREF="function.strpos.html" ><B CLASS="function" >strpos()</B ></A >, the return value of <B CLASS="function" >iconv_strrpos()</B > is the number of characters that appear before the needle, rather than the offset in bytes to the position where the needle has been found. </P ></DIV ><DIV CLASS="refsect1" ><A NAME="AEN80719" ></A ><H2 >Parâmetros</H2 ><P > <P ></P ><DIV CLASS="variablelist" ><DL ><DT ><CODE CLASS="parameter" >haystack</CODE ></DT ><DD ><P > The entire string. </P ></DD ><DT ><CODE CLASS="parameter" >needle</CODE ></DT ><DD ><P > The searched substring. </P ></DD ><DT ><CODE CLASS="parameter" >charset</CODE ></DT ><DD ><P > If <CODE CLASS="parameter" >charset</CODE > parameter is omitted, <CODE CLASS="parameter" >string</CODE > are assumed to be encoded in <A HREF="ref.iconv.html#iconv.configuration" >iconv.internal_encoding</A >. </P ></DD ></DL ></DIV > </P ><P > If <CODE CLASS="parameter" >haystack</CODE > or <CODE CLASS="parameter" >needle</CODE > is not a string, it is converted to a string and applied as the ordinal value of a character. </P ></DIV ><DIV CLASS="refsect1" ><A NAME="AEN80744" ></A ><H2 >Valores de retornado</H2 ><P > Returns the numeric position of the last occurrence of <CODE CLASS="parameter" >needle</CODE > in <CODE CLASS="parameter" >haystack</CODE >. The characters are counted on the basis of the specified character set <CODE CLASS="parameter" >charset</CODE >. </P ><P > If <CODE CLASS="parameter" >needle</CODE > is not found, <B CLASS="function" >iconv_strrpos()</B > will return <TT CLASS="constant" ><B >FALSE</B ></TT >. </P ><DIV CLASS="warning" ><P ></P ><TABLE CLASS="warning" BORDER="1" WIDTH="100%" ><TR ><TD ALIGN="CENTER" ><B >Atenção</B ></TD ></TR ><TR ><TD ALIGN="LEFT" ><P >Esta função pode retornar o booleano <TT CLASS="constant" ><B >FALSE</B ></TT >, mas também pode retornar um valor não-booleano que pode ser avaliado como <TT CLASS="constant" ><B >FALSE</B ></TT >, como <TT CLASS="literal" >0</TT > ou "". Leia a seção em <A HREF="language.types.boolean.html" >Booleanos</A > para maiores informações. Utilize o <A HREF="language.operators.comparison.html" >operador === </A > para testar o valor retornado por esta função.</P ></TD ></TR ></TABLE ></DIV ></DIV ><DIV CLASS="refsect1" ><A NAME="AEN80761" ></A ><H2 >Veja também</H2 ><P > <P ></P ><TABLE BORDER="0" ><TBODY ><TR ><TD ><A HREF="function.strrpos.html" ><B CLASS="function" >strrpos()</B ></A ></TD ></TR ><TR ><TD ><A HREF="function.iconv-strpos.html" ><B CLASS="function" >iconv_strpos()</B ></A ></TD ></TR ><TR ><TD ><A HREF="function.mb-strrpos.html" ><B CLASS="function" >mb_strrpos()</B ></A ></TD ></TR ></TBODY ></TABLE ><P ></P > </P ></DIV ><DIV CLASS="NAVFOOTER" ><HR ALIGN="LEFT" WIDTH="100%"><TABLE SUMMARY="Footer navigation table" WIDTH="100%" BORDER="0" CELLPADDING="0" CELLSPACING="0" ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" ><A HREF="function.iconv-strpos.html" ACCESSKEY="P" >Anterior</A ></TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="index.html" ACCESSKEY="H" >Principal</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" ><A HREF="function.iconv-substr.html" ACCESSKEY="N" >Próxima</A ></TD ></TR ><TR ><TD WIDTH="33%" ALIGN="left" VALIGN="top" >iconv_strpos</TD ><TD WIDTH="34%" ALIGN="center" VALIGN="top" ><A HREF="ref.iconv.html" ACCESSKEY="U" >Acima</A ></TD ><TD WIDTH="33%" ALIGN="right" VALIGN="top" >iconv_substr</TD ></TR ></TABLE ></DIV ></BODY ></HTML >