cvs: phpdoc-kr /reference/strings/functions echo.xml html-entity-decode.xml ltrim.xml rtrim.xml similar-text.xml str-ireplace.xml strripos.xml
strrpos.xml

From: Date: Sun, 30 Nov 2008 23:06:30 +0000
Subject: cvs: phpdoc-kr /reference/strings/functions echo.xml html-entity-decode.xml ltrim.xml rtrim.xml similar-text.xml str-ireplace.xml strripos.xml
strrpos.xml
Groups: php.doc.kr 
Request: Send a blank email to doc-kr+get-798@lists.php.net to get a copy of this message
progcom Sun Nov 30 23:06:30 2008 UTC Modified files: /phpdoc-kr/reference/strings/functions echo.xml html-entity-decode.xml ltrim.xml rtrim.xml similar-text.xml str-ireplace.xml strripos.xml strrpos.xml Log: sync

http://cvs.php.net/viewvc.cgi/phpdoc-kr/reference/strings/functions/echo.xml?r1=1.6&r2=1.7&diff_format=u Index: phpdoc-kr/reference/strings/functions/echo.xml diff -u phpdoc-kr/reference/strings/functions/echo.xml:1.6 phpdoc-kr/reference/strings/functions/echo.xml:1.7 --- phpdoc-kr/reference/strings/functions/echo.xml:1.6 Sun Nov 9 18:31:48 2008 +++ phpdoc-kr/reference/strings/functions/echo.xml Sun Nov 30 23:06:30 2008 @@ -1,40 +1,90 @@ <?xml version="1.0" encoding="utf-8"?> -<!-- EN-Revision: 1.14 Maintainer: progcom Status: ready --> - <refentry xml:id="function.echo" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> - <refnamediv> - <refname>echo</refname> - <refpurpose>하나 이상의 문자열을 출력합니다.</refpurpose> - </refnamediv> - <refsect1> - <title>설명</title> - <methodsynopsis> - <type>void</type><methodname>echo</methodname> - <methodparam><type>string</type><parameter>arg1</parameter></methodparam> - <methodparam choice="opt"><type>string</type><parameter>argn...</parameter></methodparam> - </methodsynopsis> - <simpara> - 모든 인수를 출력합니다. - </simpara> - <para> - <function>echo</function>은 실제 함수가 아니기에 (언어 구조입니다) 괄호를 - 사용할 필요가 없습니다. 실제로, 둘 이상의 인수를 사용할 때는 괄호를 - 사용해서는 안됩니다. - </para> - <para> - <example> - <title><function>echo</function> 예제</title> - <programlisting role="php"> +<!-- EN-Revision: 1.21 Maintainer: progcom Status: ready --> +<refentry xml:id="function.echo" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink"> + <refnamediv> + <refname>echo</refname> + <refpurpose>하나 이상의 문자열을 출력</refpurpose> + </refnamediv> + + <refsect1 role="description"> + &reftitle.description; + <methodsynopsis> + <type>void</type><methodname>echo</methodname> + <methodparam><type>string</type><parameter>arg1</parameter></methodparam> + <methodparam choice="opt"><type>string</type><parameter>...</parameter></methodparam> + </methodsynopsis> + <simpara> + 모든 인수를 출력합니다. + </simpara> + <para> + <function>echo</function>은 실제 함수가 아니기에 (언어 구조입니다) 괄호를 + 사용할 필요가 없습니다. <function>echo</function>는 (다른 언어 구조와 달리) + 함수처럼 작동하지 않으므로, 함수 문맥으로 사용할 수 없습니다. 추가로, + <function>echo</function>에 둘 이상의 인수를 사용할 때 괄호를 사용해서는 + 안됩니다. + </para> + <para> + <function>echo</function>는 열기 태그에 이어지는 등호를 사용한 짧은 + 구문을 가지고 있습니다. 이 짧은 구문은 <link + linkend="ini.short-open-tag">short_open_tag</link> 설정을 활성화 했을 + 때만 작동합니다. + <informalexample> + <programlisting role="php"> +<![CDATA[ +I have <?=$foo?> foo. +]]> + </programlisting> + </informalexample> + </para> + </refsect1> + + <refsect1 role="parameters"> + &reftitle.parameters; + <para> + <variablelist> + <varlistentry> + <term><parameter>arg1</parameter></term> + <listitem> + <para> + 출력할 인수. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>...</parameter></term> + <listitem> + <para> + </para> + </listitem> + </varlistentry> + </variablelist> + </para> + </refsect1> + + <refsect1 role="returnvalues"> + &reftitle.returnvalues; + <para> + &return.void; + </para> + </refsect1> + + <refsect1 role="examples"> + &reftitle.examples; + <para> + <example> + <title><function>echo</function> 예제</title> + <programlisting role="php"> <![CDATA[ <?php echo "Hello World"; -echo "이는 여러 -줄을 표현합니다. 물론 뉴라인도 +echo "이것은 여러 +줄을 표현합니다. 물론 줄바꿈도 출력합니다."; -echo "이는 여러\n줄을 표현합니다. 물론 뉴라인도\n출력합니다."; +echo "이것은 여러\n줄을 표현합니다. 물론 줄바꿈도\n출력합니다."; -echo "문자 이스케이핑은 \"이렇게\" 합니다."; +echo "문자 이스케이프는 \"이렇게\" 합니다."; // echo 구문 안에 변수를 사용할 수 있습니다. $foo = "foobar"; @@ -43,9 +93,9 @@ echo "foo는 $foo"; // foo는 foobar // 배열을 사용할 수도 있습니다. -$bar = array("value" => "foo"); +$baz = array("value" => "foo"); -echo "이것은 {$bar['value']} !"; // 이것은 foo ! +echo "이것은 {$baz['value']} !"; // 이것은 foo ! // 작은 따옴표는 변수값이 아닌, 변수명을 출력합니다. echo 'foo는 $foo'; // foo는 $foo @@ -59,52 +109,49 @@ echo 'This ' . 'string ' . 'was ' . 'made ' . 'with concatenation.' . "\n"; echo <<<END -이는 $variable 인터폴레이션을 가지는 여러 줄을 +이는 $variable 삽입을 가지는 여러 줄을 출력하는 "here document" 구문을 사용합니다. here document 종료어는 줄에 세미콜론만을 가지고 있어야 하며, 어떠한 공백도 없어야하는 점에 주의하십시오! END; -// echo는 함수가 아니기에, 다음 코드는 유효하지 않습니다. +// echo는 함수처럼 작동하지 않기에, 다음 코드는 유효하지 않습니다. ($some_var) ? echo 'true' : echo 'false'; // 그러나, 다음 예제는 작동합니다. -($some_var) ? print('true'): print('false'); // print는 함수입니다. +($some_var) ? print 'true' : print 'false'; // print도 구조이지만, 함수처럼 + // 작동합니다. 그러므로 + // 이 문맥에서 사용할 수 있습니다. echo $some_var ? 'true': 'false'; // 구문을 변경하여 처리 ?> ]]> - </programlisting> - </example> - </para> - <para> - <function>echo</function>는 오프닝 태그에 이어지는 등호를 사용하는 짧은 - 구문을 가지고 있습니다. 이 짧은 구문은 <link - linkend="ini.short-open-tag">short_open_tag</link> 설정을 활성화 했을 - 때만 작동합니다. - <informalexample> - <programlisting role="php"> -<![CDATA[ -I have <?=$foo?> foo. -]]> - </programlisting> - </informalexample> - </para> - <simpara> - <function>print</function>와 <function>echo</function>의 차이에 대해서는, - FAQT의 Knowledge Base Article을 읽어보십시오: <link - xlink:href="&url.echo-print;">&url.echo-print;</link> - </simpara> - - &note.language-construct; - - <simpara> - 참고: - <function>print</function>, - <function>printf</function>, - <function>flush</function>. - </simpara> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + </refsect1> + + <refsect1 role="notes"> + &reftitle.notes; + <simpara> + <function>print</function>와 <function>echo</function>의 차이에 대해서는, + FAQT의 Knowledge Base Article을 읽어보십시오: <link + xlink:href="&url.echo-print;">&url.echo-print;</link> + </simpara> + &note.language-construct; + </refsect1> + + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>print</function></member> + <member><function>printf</function></member> + <member><function>flush</function></member> + </simplelist> + </para> + </refsect1> + +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc-kr/reference/strings/functions/html-entity-decode.xml?r1=1.6&r2=1.7&diff_format=u Index: phpdoc-kr/reference/strings/functions/html-entity-decode.xml diff -u phpdoc-kr/reference/strings/functions/html-entity-decode.xml:1.6 phpdoc-kr/reference/strings/functions/html-entity-decode.xml:1.7 --- phpdoc-kr/reference/strings/functions/html-entity-decode.xml:1.6 Mon Nov 10 07:09:24 2008 +++ phpdoc-kr/reference/strings/functions/html-entity-decode.xml Sun Nov 30 23:06:30 2008 @@ -1,64 +1,124 @@ <?xml version="1.0" encoding="utf-8"?> -<!-- EN-Revision: 1.9 Maintainer: progcom Status: ready --> - <refentry xml:id="function.html-entity-decode" xmlns="http://docbook.org/ns/docbook"> - <refnamediv> - <refname>html_entity_decode</refname> - <refpurpose> - 모든 HTML 엔티티를 해당하는 문자로 변환합니다. - </refpurpose> - </refnamediv> - <refsect1> - <title>설명</title> - <methodsynopsis> - <type>string</type><methodname>html_entity_decode</methodname> - <methodparam><type>string</type><parameter>string</parameter></methodparam> - <methodparam choice="opt"><type>int</type><parameter>quote_style</parameter></methodparam> - <methodparam choice="opt"><type>string</type><parameter>charset</parameter></methodparam> - </methodsynopsis> - <para> - <function>html_entity_decode</function>는 <parameter>string</parameter>의 - 모든 HTML 엔티티를 해당하는 문자로 변환합니다. - <function>htmlentities</function>의 역함수입니다. - </para> - <para> - 두번째에 위치하는 선택적인 <parameter>quote_style</parameter> 인수는 - '작은 따옴표'와 "큰 따옴표"를 어떻게 처리할지 정의합니다. 아래의 상수들을 - 사용할 수 있으며, 기본값은 <constant>ENT_COMPAT</constant>입니다: - <table> - <title>사용할 수 있는 <parameter>quote_style</parameter> 상수</title> - <tgroup cols="2"> - <thead> - <row> - <entry>상수명</entry> - <entry>설명</entry> - </row> - </thead> - <tbody> - <row> - <entry><constant>ENT_COMPAT</constant></entry> - <entry>큰 따옴표만 변환합니다.</entry> - </row> - <row> - <entry><constant>ENT_QUOTES</constant></entry> - <entry>작은 따옴표와 큰 따옴표 둘 다 변환합니다.</entry> - </row> - <row> - <entry><constant>ENT_NOQUOTES</constant></entry> - <entry>작은 따옴표와 큰 따옴표 둘 다 변환하지 않습니다.</entry> - </row> - </tbody> - </tgroup> - </table> - </para> - <para> - 세번째에 위치하는 선택적인 <parameter>charset</parameter>의 기본값은 - ISO-8859-1 문자셋입니다. 이는 변환에 사용할 문자셋을 정의합니다. - </para> - &reference.strings.charsets; - <para> - <example> - <title>HTML 엔티티 디코딩</title> - <programlisting role="php"> +<!-- EN-Revision: 1.15 Maintainer: progcom Status: ready --> +<refentry xml:id="function.html-entity-decode" xmlns="http://docbook.org/ns/docbook"> + <refnamediv> + <refname>html_entity_decode</refname> + <refpurpose>모든 HTML 엔티티를 해당하는 문자로 변환</refpurpose> + </refnamediv> + + <refsect1 role="description"> + &reftitle.description; + <methodsynopsis> + <type>string</type><methodname>html_entity_decode</methodname> + <methodparam><type>string</type><parameter>string</parameter></methodparam> + <methodparam choice="opt"><type>int</type><parameter>quote_style</parameter></methodparam> + <methodparam choice="opt"><type>string</type><parameter>charset</parameter></methodparam> + </methodsynopsis> + <para> + <function>html_entity_decode</function>는 <parameter>string</parameter>의 + 모든 HTML 엔티티를 해당하는 문자로 변환합니다. + <function>htmlentities</function>의 역함수입니다. + </para> + </refsect1> + + <refsect1 role="parameters"> + &reftitle.parameters; + <para> + <variablelist> + <varlistentry> + <term><parameter>string</parameter></term> + <listitem> + <para> + 입력 문자열. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>quote_style</parameter></term> + <listitem> + <para> + 선택적인 두번째 인수 <parameter>quote_style</parameter>은 + '홑따옴표'와 "겹따옴표"를 어떻게 처리할지 정의합니다. 아래의 상수들을 + 사용할 수 있으며, 기본값은 <constant>ENT_COMPAT</constant>입니다: + <table> + <title>사용할 수 있는 <parameter>quote_style</parameter> 상수</title> + <tgroup cols="2"> + <thead> + <row> + <entry>상수명</entry> + <entry>설명</entry> + </row> + </thead> + <tbody> + <row> + <entry><constant>ENT_COMPAT</constant></entry> + <entry>겹따옴표만 변환합니다.</entry> + </row> + <row> + <entry><constant>ENT_QUOTES</constant></entry> + <entry>홑따옴표와 겹따옴표 모두 변환합니다.</entry> + </row> + <row> + <entry><constant>ENT_NOQUOTES</constant></entry> + <entry>홑따옴표와 겹따옴표 모두 변환하지 않습니다.</entry> + </row> + </tbody> + </tgroup> + </table> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>charset</parameter></term> + <listitem> + <para> + 선택적인 세번째 인수 <parameter>charset</parameter>의 기본값은 + ISO-8859-1 문자셋입니다. 변환에 사용할 문자셋을 정의합니다. + </para> + &reference.strings.charsets; + </listitem> + </varlistentry> + </variablelist> + </para> + </refsect1> + + <refsect1 role="returnvalues"> + &reftitle.returnvalues; + <para> + 디코드한 문자열을 반환합니다. + </para> + </refsect1> + + <refsect1 role="changelog"> + &reftitle.changelog; + <para> + <informaltable> + <tgroup cols="2"> + <thead> + <row> + <entry>&Version;</entry> + <entry>&Description;</entry> + </row> + </thead> + <tbody> + <row> + <entry>5.0.0</entry> + <entry> + 멀티바이트 문자셋 지원 추가. + </entry> + </row> + </tbody> + </tgroup> + </informaltable> + </para> + </refsect1> + + <refsect1 role="examples"> + &reftitle.examples; + <para> + <example> + <title>HTML 엔티티 디코딩</title> + <programlisting role="php"> <![CDATA[ <?php $orig = "I'll \"walk\" the <b>dog</b> now"; @@ -75,6 +135,9 @@ // PHP 4.3.0 이전 사용자는 이렇게 할 수 있습니다: function unhtmlentities($string) { + // 숫자 엔티티 치환 + $string = preg_replace('~&#x([0-9a-f]+);~ei', 'chr(hexdec("\\1"))', $string); + // 문자 엔티티 치환 $trans_tbl = get_html_translation_table(HTML_ENTITIES); $trans_tbl = array_flip($trans_tbl); return strtr($string, $trans_tbl); @@ -86,27 +149,36 @@ ?> ]]> - </programlisting> - </example> - </para> - <para> - <note> - <para> - trim(html_entity_decode('&amp;nbsp;'));는 문자열을 빈 문자열로 변환하지 - 않습니다. 이는 기본값인 ISO-8859-1 문자셋에서 '&amp;nbsp;' 엔티티가 - 아스키 코드 32(<function>trim</function>에서 잘라냄)가 아닌 아스키 코드 - 160(0xa0)이기 때문입니다. - </para> - </note> - </para> - <para> - 참고: <function>htmlentities</function>, - <function>htmlspecialchars</function>, - <function>get_html_translation_table</function>, - <function>urldecode</function>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + </refsect1> + + <refsect1 role="notes"> + &reftitle.notes; + <note> + <para> + trim(html_entity_decode('&amp;nbsp;'));는 문자열을 빈 문자열로 변환하지 + 않습니다. 이는 기본값인 ISO-8859-1 문자셋에서 '&amp;nbsp;' 엔티티가 + (<function>trim</function>에서 잘라내는) 아스키 코드 32가 아닌, 아스키 코드 + 160(0xa0)이기 때문입니다. + </para> + </note> + </refsect1> + + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>htmlentities</function></member> + <member><function>htmlspecialchars</function></member> + <member><function>get_html_translation_table</function></member> + <member><function>urldecode</function></member> + </simplelist> + </para> + </refsect1> + +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc-kr/reference/strings/functions/ltrim.xml?r1=1.4&r2=1.5&diff_format=u Index: phpdoc-kr/reference/strings/functions/ltrim.xml diff -u phpdoc-kr/reference/strings/functions/ltrim.xml:1.4 phpdoc-kr/reference/strings/functions/ltrim.xml:1.5 --- phpdoc-kr/reference/strings/functions/ltrim.xml:1.4 Sun Nov 9 18:31:48 2008 +++ phpdoc-kr/reference/strings/functions/ltrim.xml Sun Nov 30 23:06:30 2008 @@ -1,99 +1,184 @@ <?xml version="1.0" encoding="utf-8"?> -<!-- EN-Revision: 1.3 Maintainer: progcom Status: ready --> - <refentry xml:id="function.ltrim" xmlns="http://docbook.org/ns/docbook"> - <refnamediv> - <refname>ltrim</refname> - <refpurpose> - 문자열 시작 부분의 공백을 제거합니다. - </refpurpose> - </refnamediv> - <refsect1> - <title>설명</title> - <methodsynopsis> - <type>string</type><methodname>ltrim</methodname> - <methodparam><type>string</type><parameter>str</parameter></methodparam> - <methodparam choice="opt"><type>string</type><parameter>charlist</parameter></methodparam> - </methodsynopsis> - <note> +<!-- EN-Revision: 1.10 Maintainer: progcom Status: ready --> +<refentry xmlns="http://docbook.org/ns/docbook" xml:id="function.ltrim"> + <refnamediv> + <refname>ltrim</refname> + <refpurpose>문자열 시작에서 공백(이나 다른 문자)를 제거</refpurpose> + </refnamediv> + + <refsect1 role="description"> + &reftitle.description; + <methodsynopsis> + <type>string</type><methodname>ltrim</methodname> + <methodparam><type>string</type><parameter>str</parameter></methodparam> + <methodparam choice="opt"><type>string</type><parameter>charlist</parameter></methodparam> + </methodsynopsis> + <para> + 문자열 시작에서 공백(이나 다른 문자)를 제거합니다. + </para> + </refsect1> + + <refsect1 role="parameters"> + &reftitle.parameters; + <para> + <variablelist> + <varlistentry> + <term><parameter>str</parameter></term> + <listitem> + <para> + 입력 문자열. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>charlist</parameter></term> + <listitem> + <para> + <parameter>charlist</parameter> 인수로 제거하길 원하는 문자를 지정할 수 + 있습니다. 간단히 제거하길 원하는 모든 문자를 나열합니다. + <literal>..</literal>으로 문자 범위를 지정할 수 있습니다. + </para> + </listitem> + </varlistentry> + </variablelist> + </para> + </refsect1> + + <refsect1 role="returnvalues"> + &reftitle.returnvalues; + <para> + <parameter>str</parameter> 시작에서 공백을 제거한 문자열을 반환합니다. + 두번째 인수가 없으면, <function>ltrim</function>은 다음 문자를 제거합니다: + <!-- sorted by importance. Printed 3 times: trim, ltrim, rtrim --> + <itemizedlist> + <listitem> + <simpara> + " " (<acronym>ASCII</acronym> <literal>32</literal> + (<literal>0x20</literal>)), 보통의 공백. + </simpara> + </listitem> + <listitem> + <simpara> + "\t" (<acronym>ASCII</acronym> <literal>9</literal> + (<literal>0x09</literal>)), 탭. + </simpara> + </listitem> + <listitem> <simpara> - 두번째 인수는 PHP 4.1.0에서 추가되었습니다. + "\n" (<acronym>ASCII</acronym> <literal>10</literal> + (<literal>0x0A</literal>)), 새 줄(줄바꿈). </simpara> - </note> - <para> - <parameter>str</parameter>의 시작 부분에서 공백을 제거한 문자열을 - 반환합니다. 두번째 인수를 주지 않으면 <function>ltrim</function>은 다음의 - 문자들을 제거합니다: - <!-- sorted by importance. Printed 3 times: trim, ltrim, rtrim --> - <itemizedlist> - <listitem> - <simpara> - " " (<acronym>ASCII</acronym> <literal>32</literal> - (<literal>0x20</literal>)), 일반적인 공백. - </simpara> - </listitem> - <listitem> - <simpara> - "\t" (<acronym>ASCII</acronym> <literal>9</literal> - (<literal>0x09</literal>)), 탭. - </simpara> - </listitem> - <listitem> - <simpara> - "\n" (<acronym>ASCII</acronym> <literal>10</literal> - (<literal>0x0A</literal>)), 뉴 라인 (줄 바꿈). - </simpara> - </listitem> - <listitem> - <simpara> - "\r" (<acronym>ASCII</acronym> <literal>13</literal> - (<literal>0x0D</literal>)), 캐리지 리턴. - </simpara> - </listitem> - <listitem> - <simpara> - "\0" (<acronym>ASCII</acronym> <literal>0</literal> - (<literal>0x00</literal>)), <literal>NUL</literal>-바이트. - </simpara> - </listitem> - <listitem> - <simpara> <!-- not \v, since not supported by PHP --> - "\x0B" (<acronym>ASCII</acronym> <literal>11</literal> - (<literal>0x0B</literal>)), 수직 탭. - </simpara> - </listitem> - </itemizedlist> - </para> - <para> - 제거하고 싶은 문자들을 <parameter>charlist</parameter> 인수로 지정할 - 수 있습니다. 단순히 제거하고 싶은 모든 문자를 쓰면 됩니다. - <literal>..</literal>로 문자의 범위를 지정할 수 있습니다. - </para> - <example> - <title><function>ltrim</function> 사용 예제</title> - <para> - <programlisting role="php"> + </listitem> + <listitem> + <simpara> + "\r" (<acronym>ASCII</acronym> <literal>13</literal> + (<literal>0x0D</literal>)), 캐리지 리턴. + </simpara> + </listitem> + <listitem> + <simpara> + "\0" (<acronym>ASCII</acronym> <literal>0</literal> + (<literal>0x00</literal>)), <literal>NUL</literal> 바이트. + </simpara> + </listitem> + <listitem> + <simpara> <!-- not \v, since not supported by PHP --> + "\x0B" (<acronym>ASCII</acronym> <literal>11</literal> + (<literal>0x0B</literal>)), 수직 탭. + </simpara> + </listitem> + </itemizedlist> + </para> + </refsect1> + + <refsect1 role="changelog"> + &reftitle.changelog; + <para> + <informaltable> + <tgroup cols="2"> + <thead> + <row> + <entry>&Version;</entry> + <entry>&Description;</entry> + </row> + </thead> + <tbody> + <row> + <entry>4.1.0</entry> + <entry> + <parameter>charlist</parameter> 인수 추가. + </entry> + </row> + </tbody> + </tgroup> + </informaltable> + </para> + </refsect1> + + <refsect1 role="examples"> + &reftitle.examples; + <para> + <example> + <title><function>ltrim</function> 용례</title> + <programlisting role="php"> <![CDATA[ <?php $text = "\t\tThese are a few words :) ... "; +$binary = "\x09Example string\x0A"; +$hello = "Hello World"; +var_dump($text, $binary, $hello); + +print "\n"; + + $trimmed = ltrim($text); -// $trimmed = "These are a few words :) ... " +var_dump($trimmed); + $trimmed = ltrim($text, " \t."); -// $trimmed = "These are a few words :) ... " -$clean = ltrim($binary, "\0x00..\0x1F"); -// $binary의 시작 부분에서 아스키 제어 문자를 제거합니다. +var_dump($trimmed); + +$trimmed = ltrim($hello, "Hdle"); +var_dump($trimmed); + +// $binary 시작에서 ASCII 제어 문자를 제거 // (0부터 31까지) +$clean = ltrim($binary, "\x00..\x1F"); +var_dump($clean); ?> ]]> - </programlisting> - </para> - </example> - <para> - 참고: <function>trim</function>, <function>rtrim</function>. - </para> - </refsect1> - </refentry> + </programlisting> + &example.outputs; + <screen> +<![CDATA[ +string(32) " These are a few words :) ... " +string(16) " Example string +" +string(11) "Hello World" + +string(30) "These are a few words :) ... " +string(30) "These are a few words :) ... " +string(7) "o World" +string(15) "Example string +" +]]> + </screen> + </example> + </para> + </refsect1> + + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>trim</function></member> + <member><function>rtrim</function></member> + </simplelist> + </para> + </refsect1> + +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc-kr/reference/strings/functions/rtrim.xml?r1=1.5&r2=1.6&diff_format=u Index: phpdoc-kr/reference/strings/functions/rtrim.xml diff -u phpdoc-kr/reference/strings/functions/rtrim.xml:1.5 phpdoc-kr/reference/strings/functions/rtrim.xml:1.6 --- phpdoc-kr/reference/strings/functions/rtrim.xml:1.5 Sat Nov 29 08:22:15 2008 +++ phpdoc-kr/reference/strings/functions/rtrim.xml Sun Nov 30 23:06:30 2008 @@ -38,7 +38,7 @@ <listitem> <simpara> "\n" (<acronym>ASCII</acronym> <literal>10</literal> - (<literal>0x0A</literal>)), 줄바꿈. + (<literal>0x0A</literal>)), 새 줄(줄바꿈). </simpara> </listitem> <listitem> http://cvs.php.net/viewvc.cgi/phpdoc-kr/reference/strings/functions/similar-text.xml?r1=1.4&r2=1.5&diff_format=u Index: phpdoc-kr/reference/strings/functions/similar-text.xml diff -u phpdoc-kr/reference/strings/functions/similar-text.xml:1.4 phpdoc-kr/reference/strings/functions/similar-text.xml:1.5 --- phpdoc-kr/reference/strings/functions/similar-text.xml:1.4 Sun Nov 9 18:31:48 2008 +++ phpdoc-kr/reference/strings/functions/similar-text.xml Sun Nov 30 23:06:30 2008 @@ -1,34 +1,78 @@ <?xml version="1.0" encoding="utf-8"?> -<!-- EN-Revision: 1.2 Maintainer: progcom Status: ready --> -<!-- CREDITS: cycle98 --> - <refentry xml:id="function.similar-text" xmlns="http://docbook.org/ns/docbook"> - <refnamediv> - <refname>similar_text</refname> - <refpurpose> - 두 문자열 간의 유사성을 계산합니다. - </refpurpose> - </refnamediv> - <refsect1> - <title>설명</title> - <methodsynopsis> - <type>int</type><methodname>similar_text</methodname> - <methodparam><type>string</type><parameter>first</parameter></methodparam> - <methodparam><type>string</type><parameter>second</parameter></methodparam> - <methodparam choice="opt"><type>float</type><parameter>percent</parameter></methodparam> - </methodsynopsis> - <para> - Oliver [1993]에서 설명한 방법으로 두 문자열 간의 유사성을 계산합니다. 이 - 수행은 Oliver's 표현 코드처럼 스택을 사용하지 않고, 전체 프로세스 속도를 - 향상하거나 저하할 수 있는 재귀 호출을 사용하는 점에 주의하십시오. 이 - 알고리즘의 복잡도는 O(N**3)이고, N은 가장 긴 문자열의 길이를 나타냅니다. - </para> - <para> - 세번째 인수를 참조로 전달하면, <function>similar_text</function>가 - 유사성을 백분율로 계산해줍니다. 이 함수는 두 문자열에서 매치하는 문자 - 수를 반환합니다. - </para> - </refsect1> - </refentry> +<!-- EN-Revision: 1.9 Maintainer: progcom Status: ready --> +<refentry xmlns="http://docbook.org/ns/docbook" xml:id="function.similar-text"> + <refnamediv> + <refname>similar_text</refname> + <refpurpose>두 문자열 사이의 유사성을 계산</refpurpose> + </refnamediv> + + <refsect1 role="description"> + &reftitle.description; + <methodsynopsis> + <type>int</type><methodname>similar_text</methodname> + <methodparam><type>string</type><parameter>first</parameter></methodparam> + <methodparam><type>string</type><parameter>second</parameter></methodparam> + <methodparam choice="opt"><type>float</type><parameter role="reference">percent</parameter></methodparam> + </methodsynopsis> + <para> + Oliver[1993]에 설명된 대로 두 문자열의 유사성을 계산합니다. 이 구현은 + Oliver의 모의 코드처럼 스택은 아니지만, 재귀 호출이므로 처리의 전체 + 속도에 영향을 줄 수 있습니다. 이 알고리즘의 복잡도는, N이 가장 긴 문자열일 + 때 O(N**3)입니다. + </para> + </refsect1> + + <refsect1 role="parameters"> + &reftitle.parameters; + <para> + <variablelist> + <varlistentry> + <term><parameter>first</parameter></term> + <listitem> + <para> + 첫번째 문자열. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>second</parameter></term> + <listitem> + <para> + 두번째 문자열. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>percent</parameter></term> + <listitem> + <para> + 세번째 인수를 참조로 전달하면, <function>similar_text</function>는 + 유사성 퍼센트를 계산합니다. + </para> + </listitem> + </varlistentry> + </variablelist> + </para> + </refsect1> + + <refsect1 role="returnvalues"> + &reftitle.returnvalues; + <para> + 두 문자열에서 매치한 문자 수를 반환합니다. + </para> + </refsect1> + + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>levenshtein</function></member> + <member><function>soundex</function></member> + </simplelist> + </para> + </refsect1> + +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc-kr/reference/strings/functions/str-ireplace.xml?r1=1.3&r2=1.4&diff_format=u Index: phpdoc-kr/reference/strings/functions/str-ireplace.xml diff -u phpdoc-kr/reference/strings/functions/str-ireplace.xml:1.3 phpdoc-kr/reference/strings/functions/str-ireplace.xml:1.4 --- phpdoc-kr/reference/strings/functions/str-ireplace.xml:1.3 Sun Nov 9 18:31:48 2008 +++ phpdoc-kr/reference/strings/functions/str-ireplace.xml Sun Nov 30 23:06:30 2008 @@ -1,76 +1,152 @@ <?xml version="1.0" encoding="utf-8"?> -<!-- EN-Revision: 1.6 Maintainer: progcom Status: ready --> - <refentry xml:id="function.str-ireplace" xmlns="http://docbook.org/ns/docbook"> - <refnamediv> - <refname>str_ireplace</refname> - <refpurpose> - 대소문자를 구별하지 않는 <function>str_replace</function>. - </refpurpose> - </refnamediv> - <refsect1> - <title>설명</title> - <methodsynopsis> - <type>mixed</type><methodname>str_ireplace</methodname> - <methodparam><type>mixed</type><parameter>search</parameter></methodparam> - <methodparam><type>mixed</type><parameter>replace</parameter></methodparam> - <methodparam><type>mixed</type><parameter>subject</parameter></methodparam> - <methodparam choice="opt"><type>int</type><parameter>&amp;count</parameter></methodparam> - </methodsynopsis> - <para> - <parameter>subject</parameter>에서 (대소문자 구별 없이) 모든 - <parameter>search</parameter>를 주어진 <parameter>replace</parameter>로 - 치환합니다. 복잡한 치환 규칙이 필요하지 않다면, - <function>eregi_replace</function>이나 - <function>preg_replace</function>에 <literal>i</literal> 변경자를 - 사용하는 대신, 이 함수를 사용하십시오. - </para> - <para> - <parameter>subject</parameter>가 배열이면, 검색 및 치환을 - <parameter>subject</parameter>의 모든 원소에서 수행하고, 배열을 - 반환합니다. - </para> - <para> - <parameter>search</parameter>와 <parameter>replace</parameter>가 - 배열이면, <function>str_ireplace</function>는 각각의 배열값을 - <parameter>subject</parameter>에서 검색하고 치환하는 데에 사용합니다. - <parameter>replace</parameter>가 <parameter>search</parameter>보다 적은 - 값을 가지고 있으면, 나머지 치환값은 빈 문자열을 사용합니다. - <parameter>search</parameter>가 배열이고 <parameter>replace</parameter>가 - 문자열이면; 치환 문자열을 <parameter>search</parameter>의 모든 값에 - 사용합니다. - </para> - <para> - <example> - <title><function>str_ireplace</function> 예제</title> - <programlisting role="php"> +<!-- EN-Revision: 1.13 Maintainer: progcom Status: ready --> +<refentry xml:id="function.str-ireplace" xmlns="http://docbook.org/ns/docbook"> + <refnamediv> + <refname>str_ireplace</refname> + <refpurpose>대소문자를 구분 없는 <function>str_replace</function>.</refpurpose> + </refnamediv> + + <refsect1 role="description"> + &reftitle.description; + <methodsynopsis> + <type>mixed</type><methodname>str_ireplace</methodname> + <methodparam><type>mixed</type><parameter>search</parameter></methodparam> + <methodparam><type>mixed</type><parameter>replace</parameter></methodparam> + <methodparam><type>mixed</type><parameter>subject</parameter></methodparam> + <methodparam choice="opt"><type>int</type><parameter role="reference">count</parameter></methodparam> + </methodsynopsis> + <para> + <parameter>subject</parameter>에서 (대소문자 구별 없이) 모든 + <parameter>search</parameter>를 주어진 <parameter>replace</parameter>로 + 치환합니다. 복잡한 치환 규칙이 필요하지 않다면, + <function>preg_replace</function>에 <literal>i</literal> 변경자를 + 사용하는 대신, 이 함수를 사용하십시오. + </para> + </refsect1> + + <refsect1 role="parameters"> + &reftitle.parameters; + <para> + <variablelist> + <varlistentry> + <term><parameter>search</parameter></term> + <listitem> + <note> + <para> + <parameter>search</parameter> 배열의 모든 치환은 이전 치환의 결과로 + 수행합니다. + </para> + </note> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>replace</parameter></term> + <listitem> + <para> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>subject</parameter></term> + <listitem> + <para> + <parameter>subject</parameter>가 배열이면, 검색 및 치환을 + <parameter>subject</parameter>의 모든 원소에서 수행하고, 배열을 + 반환합니다. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>count</parameter></term> + <listitem> + <para> + 매치하여 치환한 <parameter>needles</parameter>의 수를 참조로 전달한 + <parameter>count</parameter>로 반환합니다. + </para> + </listitem> + </varlistentry> + </variablelist> + </para> + <para> + <parameter>search</parameter>와 <parameter>replace</parameter>가 + 배열이면, <function>str_ireplace</function>는 각각의 배열값을 + <parameter>subject</parameter>에서 검색하고 치환하는 데에 사용합니다. + <parameter>replace</parameter>가 <parameter>search</parameter>보다 적은 + 값을 가지고 있으면, 나머지 치환값은 빈 문자열을 사용합니다. + <parameter>search</parameter>가 배열이고 <parameter>replace</parameter>가 + 문자열이면; 치환 문자열을 <parameter>search</parameter>의 모든 값에 + 사용합니다. + </para> + </refsect1> + + <refsect1 role="returnvalues"> + &reftitle.returnvalues; + <para> + 치환한 문자열이나 배열을 반환합니다. + </para> + </refsect1> + + <refsect1 role="changelog"> + &reftitle.changelog; + <para> + <informaltable> + <tgroup cols="2"> + <thead> + <row> + <entry>&Version;</entry> + <entry>&Description;</entry> + </row> + </thead> + <tbody> + <row> + <entry>5.0.0</entry> + <entry> + <parameter>count</parameter> 인수 추가. + </entry> + </row> + </tbody> + </tgroup> + </informaltable> + </para> + </refsect1> + + <refsect1 role="examples"> + &reftitle.examples; + <para> + <example> + <title><function>str_ireplace</function> 예제</title> + <programlisting role="php"> <![CDATA[ <?php $bodytag = str_ireplace("%body%", "black", "<body text=%BODY%>"); ?> ]]> - </programlisting> - </example> - </para> - <para> - 이 함수는 바이너리 안전입니다. - </para> - <note> - <simpara> - <literal>PHP 5.0.0</literal>부터 매치하여 교체한 - <parameter>needles</parameter>의 수를 참조로 전달한 - <parameter>count</parameter>로 반환합니다. <literal>PHP 5.0.0</literal> - 이전에 이 인수는 사용할 수 없습니다. - </simpara> - </note> - <para> - 참고: - <function>str_replace</function>, - <function>ereg_replace</function>, - <function>preg_replace</function>, - <function>strtr</function>. - </para> - </refsect1> - </refentry> + </programlisting> + </example> + </para> + </refsect1> + + <refsect1 role="notes"> + &reftitle.notes; + <note> + <para> + 이 함수는 바이너리 안전입니다. + </para> + </note> + </refsect1> + + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>str_replace</function></member> + <member><function>preg_replace</function></member> + <member><function>strtr</function></member> + </simplelist> + </para> + </refsect1> + +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc-kr/reference/strings/functions/strripos.xml?r1=1.4&r2=1.5&diff_format=u Index: phpdoc-kr/reference/strings/functions/strripos.xml diff -u phpdoc-kr/reference/strings/functions/strripos.xml:1.4 phpdoc-kr/reference/strings/functions/strripos.xml:1.5 --- phpdoc-kr/reference/strings/functions/strripos.xml:1.4 Mon Nov 10 07:09:24 2008 +++ phpdoc-kr/reference/strings/functions/strripos.xml Sun Nov 30 23:06:30 2008 @@ -1,41 +1,82 @@ <?xml version="1.0" encoding="utf-8"?> -<!-- EN-Revision: 1.5 Maintainer: progcom Status: ready --> - <refentry xml:id="function.strripos" xmlns="http://docbook.org/ns/docbook"> - <refnamediv> - <refname>strripos</refname> - <refpurpose> - 문자열에서 대소문자 구별 없이 문자열이 나타나는 마지막 위치를 찾습니다. - </refpurpose> - </refnamediv> - <refsect1> - <title>설명</title> - <methodsynopsis> - <type>int</type><methodname>strripos</methodname> - <methodparam><type>string</type><parameter>haystack</parameter></methodparam> - <methodparam><type>string</type><parameter>needle</parameter></methodparam> - <methodparam choice="opt"><type>int</type><parameter>offset</parameter></methodparam> - </methodsynopsis> - <para> - <parameter>haystack</parameter> 문자열에서 마지막으로 - <parameter>needle</parameter>가 나타나는 숫자 위치를 반환합니다. - <function>strrpos</function>와는 달리, <function>strripos</function>는 - 대소문자를 구별하지 않습니다. 문자열 위치는 1이 아닌, 0에서 시작하는 점에 - 주의하십시오. - </para> - <para> - <parameter>needle</parameter>은 하나 이상의 문자를 가지는 문자열이여야 - 합니다. - </para> - <para> - <parameter>needle</parameter>이 발견되지 않으면, &false;를 반환합니다. - </para> - - &return.falseproblem; - - <para> - <example> - <title>간단한 <function>strripos</function> 예제</title> - <programlisting role="php"> +<!-- EN-Revision: 1.13 Maintainer: progcom Status: ready --> +<refentry xmlns="http://docbook.org/ns/docbook" xml:id="function.strripos"> + <refnamediv> + <refname>strripos</refname> + <refpurpose>문자열에서 대소문자 구분 없는 문자열의 마지막 위치를 찾습니다</refpurpose> + </refnamediv> + + <refsect1 role="description"> + &reftitle.description; + <methodsynopsis> + <type>int</type><methodname>strripos</methodname> + <methodparam><type>string</type><parameter>haystack</parameter></methodparam> + <methodparam><type>string</type><parameter>needle</parameter></methodparam> + <methodparam choice="opt"><type>int</type><parameter>offset</parameter></methodparam> + </methodsynopsis> + <para> + 문자열에서 대소문자 구분 없는 문자열의 마지막 위치를 찾습니다. + <function>strrpos</function>와는 달리, <function>strripos</function>는 + 대소문자를 구분하지 않습니다. + </para> + </refsect1> + + <refsect1 role="parameters"> + &reftitle.parameters; + <para> + <variablelist> + <varlistentry> + <term><parameter>haystack</parameter></term> + <listitem> + <para> + 탐색할 문자열 + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>needle</parameter></term> + <listitem> + <para> + <parameter>needle</parameter>은 문자열이나 하나 이상의 문자이여야 + 합니다. + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>offset</parameter></term> + <listitem> + <para> + <parameter>offset</parameter> 인수를 지정하면 문자열의 해당 + 위치에서부터 탐색을 시작합니다. + </para> + <para> + 음의 offset 값은 문자열 <emphasis>시작</emphasis>부터 + <parameter>offset</parameter> 문자에서 탐색을 시작합니다. + </para> + </listitem> + </varlistentry> + </variablelist> + </para> + </refsect1> + + <refsect1 role="returnvalues"> + &reftitle.returnvalues; + <para> + <parameter>needle</parameter>의 마지막 위치를 반환합니다. 문자열 위치는 + 1이 아닌, 0에서 시작합니다. + </para> + <para> + <parameter>needle</parameter>을 발견하지 못하면, &false;를 반환합니다. + </para> + &return.falseproblem; + </refsect1> + + <refsect1 role="examples"> + &reftitle.examples; + <para> + <example> + <title>간단한 <function>strripos</function> 예제</title> + <programlisting role="php"> <![CDATA[ <?php $haystack = 'ababcd'; @@ -44,38 +85,40 @@ $pos = strripos($haystack, $needle); if ($pos === false) { - echo "($haystack)에서 ($needle)를 찾지 못했습니다."; + echo "Sorry, we did not find ($needle) in ($haystack)"; } else { - echo "축하합니다!\n"; - echo "($haystack)의 위치 ($pos)에서 마지막 ($needle)를 찾았습니다."; + echo "Congratulations!\n"; + echo "We found the last ($needle) in ($haystack) at position ($pos)"; } ?> ]]> - </programlisting> - <para> - 출력: - </para> - <screen> + </programlisting> + &example.outputs; + <screen> <![CDATA[ - 축하합니다! - (ababcd)의 위치 (2)에서 마지막 (aB)를 찾았습니다. + Congratulations! + We found the last (aB) in (ababcd) at position (2) ]]> - </screen> - </example> - </para> - <simpara> - <parameter>offset</parameter> 인수는 문자열에서 찾기 시작할 위치를 - 지정합니다. 음수는 문자열의 마지막으로부터 해당 위치에서 검색을 - 중단합니다. - </simpara> - <para> - 참고: <function>strrpos</function>, - <function>strrchr</function>, - <function>substr</function>, <function>stripos</function>, - <function>stristr</function>. - </para> - </refsect1> - </refentry> + </screen> + </example> + </para> + </refsect1> + + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>strpos</function></member> + <member><function>stripos</function></member> + <member><function>strrchr</function></member> + <member><function>substr</function></member> + <member><function>stristr</function></member> + <member><function>strstr</function></member> + </simplelist> + </para> + </refsect1> + +</refentry> <!-- Keep this comment at the end of the file Local variables: http://cvs.php.net/viewvc.cgi/phpdoc-kr/reference/strings/functions/strrpos.xml?r1=1.4&r2=1.5&diff_format=u Index: phpdoc-kr/reference/strings/functions/strrpos.xml diff -u phpdoc-kr/reference/strings/functions/strrpos.xml:1.4 phpdoc-kr/reference/strings/functions/strrpos.xml:1.5 --- phpdoc-kr/reference/strings/functions/strrpos.xml:1.4 Mon Nov 10 07:09:24 2008 +++ phpdoc-kr/reference/strings/functions/strrpos.xml Sun Nov 30 23:06:30 2008 @@ -1,80 +1,122 @@ <?xml version="1.0" encoding="utf-8"?> -<!-- EN-Revision: 1.9 Maintainer: progcom Status: ready --> - <refentry xml:id="function.strrpos" xmlns="http://docbook.org/ns/docbook"> - <refnamediv> - <refname>strrpos</refname> - <refpurpose> - 문자열에서 마지막 문자의 위치를 찾습니다. - </refpurpose> - </refnamediv> - <refsect1> - <title>설명</title> - <methodsynopsis> - <type>int</type><methodname>strrpos</methodname> - <methodparam><type>string</type><parameter>haystack</parameter></methodparam> - <methodparam><type>string</type><parameter>needle</parameter></methodparam> - <methodparam choice="opt"><type>int</type><parameter>offset</parameter></methodparam> - </methodsynopsis> - <para> - <parameter>haystack</parameter> 문자열에서 마지막으로 나오는 - <parameter>needle</parameter>의 위치를 수로 반환합니다. PHP 4에서 - needle은 하나의 문자만 사용할 수 있습니다. 문자열을 needle로 전달하면, - 문자열의 첫번째 문자만을 사용합니다. - </para> - <para> - <parameter>needle</parameter>이 발견되지 않으면, &false;를 반환합니다. - </para> - <para> - "문자를 위치 0에서 찾았습니다"와 "문자를 존재하지 않습니다"의 반환값을 - 혼동하기 쉽습니다. 두개의 차이를 확인하는 방법입니다: - <informalexample> - <programlisting role="php"> +<!-- EN-Revision: 1.16 Maintainer: progcom Status: ready --> +<refentry xml:id="function.strrpos" xmlns="http://docbook.org/ns/docbook"> + <refnamediv> + <refname>strrpos</refname> + <refpurpose>문자열에서 마지막 문자의 위치를 찾습니다</refpurpose> + </refnamediv> + + <refsect1 role="description"> + &reftitle.description; + <methodsynopsis> + <type>int</type><methodname>strrpos</methodname> + <methodparam><type>string</type><parameter>haystack</parameter></methodparam> + <methodparam><type>string</type><parameter>needle</parameter></methodparam> + <methodparam choice="opt"><type>int</type><parameter>offset</parameter></methodparam> + </methodsynopsis> + <para> + <parameter>haystack</parameter> 문자열에서 마지막으로 나오는 + <parameter>needle</parameter>의 위치를 수로 반환합니다. PHP 4에서 + needle은 하나의 문자만 사용할 수 있습니다. 문자열을 needle로 전달하면, + 문자열의 첫번째 문자만을 사용합니다. + </para> + <para> + <parameter>needle</parameter>이 발견되지 않으면, &false;를 반환합니다. + </para> + <para> + "문자를 위치 0에서 찾았습니다"와 "문자를 존재하지 않습니다"의 반환값을 + 혼동하기 쉽습니다. 두개의 차이를 확인하는 방법입니다: + <informalexample> + <programlisting role="php"> <![CDATA[ <?php -// PHP 4.0b3 이상: +// PHP 4.0.0 이상: $pos = strrpos($mystring, "b"); if ($pos === false) { // 주의: 등호 3개 // 발견되지 않았습니다... } -// 4.0b3 미만: +// 4.0.0 미만: $pos = strrpos($mystring, "b"); if (is_bool($pos) && !$pos) { // 발견되지 않았습니다... } ?> ]]> - </programlisting> - </informalexample> - </para> - <para> - <parameter>needle</parameter>가 문자열이 아니면, 정수형으로 변환하여 - 해당하는 코드의 문자를 적용합니다. - </para> - <note> - <simpara> - <literal>PHP 5.0.0</literal>부터 <parameter>offset</parameter>으로 - 문자열에서 찾기 시작할 위치를 지정할 수 있습니다. 음수는 문자열 - 마지막으로부터 해당 위치에서 찾기를 멈춥니다. - </simpara> - </note> - <note> - <simpara> - <literal>PHP 5.0.0</literal>부터 <parameter>needle</parameter>은 하나의 - 문자 이상을 다룹니다. - </simpara> - </note> - <para> - 참고: <function>strpos</function>, - <function>strripos</function>, - <function>strrchr</function>, - <function>substr</function>, - <function>stristr</function>, - <function>strstr</function>. - </para> - </refsect1> - </refentry> + </programlisting> + </informalexample> + </para> + <para> + <parameter>needle</parameter>가 문자열이 아니면, 정수형으로 변환하여 + 해당하는 코드의 문자를 적용합니다. + </para> + <note> + <simpara> + PHP 5.0.0부터 <parameter>offset</parameter>으로 + 문자열에서 찾기 시작할 위치를 지정할 수 있습니다. 음수는 문자열 + 마지막으로부터 해당 위치에서 찾기를 멈춥니다. + </simpara> + </note> + <note> + <simpara> + PHP 5.0.0부터 <parameter>needle</parameter>은 하나의 + 문자 이상을 다룹니다. + </simpara> + </note> + </refsect1> + + <refsect1 role="parameters"> + &reftitle.parameters; + <para> + <variablelist> + <varlistentry> + <term><parameter>haystack</parameter></term> + <listitem> + <para> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>needle</parameter></term> + <listitem> + <para> + </para> + </listitem> + </varlistentry> + <varlistentry> + <term><parameter>offset</parameter></term> + <listitem> + <para> + </para> + </listitem> + </varlistentry> + </variablelist> + </para> + </refsect1> + + <refsect1 role="returnvalues"> + &reftitle.returnvalues; + <para> + + </para> + </refsect1> + + <refsect1 role="seealso"> + &reftitle.seealso; + <para> + <simplelist> + <member><function>strpos</function></member> + <member><function>strripos</function></member> + <member><function>strrchr</function></member> + <member><function>substr</function></member> + <member><function>stristr</function></member> + <member><function>strstr</function></member> + </simplelist> + </para> + </refsect1> + +</refentry> <!-- Keep this comment at the end of the file Local variables:
« previous php.doc.kr (#798) next »