Sophie

Sophie

distrib > Mageia > 4 > i586 > by-pkgid > f800694edefe91adea2624f711a41a2d > files > 4773

php-manual-en-5.5.7-1.mga4.noarch.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>Query language and locale information</title>

 </head>
 <body><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="function.money-format.html">money_format</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="function.nl2br.html">nl2br</a></div>
 <div class="up"><a href="ref.strings.html">String Functions</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div><hr /><div id="function.nl-langinfo" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">nl_langinfo</h1>
  <p class="verinfo">(PHP 4 &gt;= 4.1.0, PHP 5)</p><p class="refpurpose"><span class="refname">nl_langinfo</span> &mdash; <span class="dc-title">Query language and locale information</span></p>

 </div>
 
 <div class="refsect1 description" id="refsect1-function.nl-langinfo-description">
  <h3 class="title">Description</h3>
  <div class="methodsynopsis dc-description">
   <span class="type">string</span> <span class="methodname"><strong>nl_langinfo</strong></span>
    ( <span class="methodparam"><span class="type">int</span> <code class="parameter">$item</code></span>
   )</div>

  <p class="para rdfs-comment">
    <span class="function"><strong>nl_langinfo()</strong></span> is used to access individual elements of
   the locale categories.  Unlike  <span class="function"><a href="function.localeconv.html" class="function">localeconv()</a></span>, which
   returns all of the elements,  <span class="function"><strong>nl_langinfo()</strong></span> allows you
   to select any specific element.
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.nl-langinfo-parameters">
  <h3 class="title">Parameters</h3>
  <p class="para">
   <dl>

    <dt>

     <span class="term"><em><code class="parameter">item</code></em></span>
     <dd>

      <p class="para">
       <em><code class="parameter">item</code></em> may be an integer value of the element or the
       constant name of the element. The following is a list of constant names
       for <em><code class="parameter">item</code></em> that may be used and their description.
       Some of these constants may not be defined or hold no value for certain
       locales.
       <table class="doctable table">
        <caption><strong>nl_langinfo Constants</strong></caption>
        
         <col />
         <col />
         <thead>
          <tr>
           <th>Constant</th>
           <th>Description</th>
          </tr>

         </thead>

         <tbody class="tbody">
          <tr>
           <td colspan="2" style="text-align: center;"><em class="emphasis">LC_TIME Category Constants</em></td>
          </tr>

          <tr>
           <td><strong><code>ABDAY_(1-7)</code></strong></td>
           <td>Abbreviated name of n-th day of the week.</td>
          </tr>

          <tr>
           <td><strong><code>DAY_(1-7)</code></strong></td>
           <td>Name of the n-th day of the week (DAY_1 = Sunday).</td>
          </tr>

          <tr>
           <td><strong><code>ABMON_(1-12)</code></strong></td>
           <td>Abbreviated name of the n-th month of the year.</td>
          </tr>

          <tr>
           <td><strong><code>MON_(1-12)</code></strong></td>
           <td>Name of the n-th month of the year.</td>
          </tr>

          <tr>
           <td><strong><code>AM_STR</code></strong></td>
           <td>String for Ante meridian.</td>
          </tr>

          <tr>
           <td><strong><code>PM_STR</code></strong></td>
           <td>String for Post meridian.</td>
          </tr>

          <tr>
           <td><strong><code>D_T_FMT</code></strong></td>
           <td>String that can be used as the format string for  <span class="function"><a href="function.strftime.html" class="function">strftime()</a></span> to represent time and date.</td>
          </tr>

          <tr>
           <td><strong><code>D_FMT</code></strong></td>
           <td>String that can be used as the format string for  <span class="function"><a href="function.strftime.html" class="function">strftime()</a></span> to represent date.</td>
          </tr>

          <tr>
           <td><strong><code>T_FMT</code></strong></td>
           <td>String that can be used as the format string for  <span class="function"><a href="function.strftime.html" class="function">strftime()</a></span> to represent time.</td>
          </tr>

          <tr>
           <td><strong><code>T_FMT_AMPM</code></strong></td>
           <td>String that can be used as the format string for  <span class="function"><a href="function.strftime.html" class="function">strftime()</a></span> to represent time in 12-hour format with ante/post meridian.</td>
          </tr>

          <tr>
           <td><strong><code>ERA</code></strong></td>
           <td>Alternate era.</td>
          </tr>

          <tr>
           <td><strong><code>ERA_YEAR</code></strong></td>
           <td>Year in alternate era format.</td>
          </tr>

          <tr>
           <td><strong><code>ERA_D_T_FMT</code></strong></td>
           <td>Date and time in alternate era format (string can be used in  <span class="function"><a href="function.strftime.html" class="function">strftime()</a></span>).</td>
          </tr>

          <tr>
           <td><strong><code>ERA_D_FMT</code></strong></td>
           <td>Date in alternate era format (string can be used in  <span class="function"><a href="function.strftime.html" class="function">strftime()</a></span>).</td>
          </tr>

          <tr>
           <td><strong><code>ERA_T_FMT</code></strong></td>
           <td>Time in alternate era format (string can be used in  <span class="function"><a href="function.strftime.html" class="function">strftime()</a></span>).</td>
          </tr>

          <tr>
           <td colspan="2" style="text-align: center;"><em class="emphasis">LC_MONETARY Category Constants</em></td>
          </tr>

          <tr>
           <td><strong><code>INT_CURR_SYMBOL</code></strong></td>
           <td>International currency symbol.</td>
          </tr>

          <tr>
           <td><strong><code>CURRENCY_SYMBOL</code></strong></td>
           <td>Local currency symbol.</td>
          </tr>

          <tr>
           <td><strong><code>CRNCYSTR</code></strong></td>
           <td>Same value as <strong><code>CURRENCY_SYMBOL</code></strong>.</td>
          </tr>

          <tr>
           <td><strong><code>MON_DECIMAL_POINT</code></strong></td>
           <td>Decimal point character.</td>
          </tr>

          <tr>
           <td><strong><code>MON_THOUSANDS_SEP</code></strong></td>
           <td>Thousands separator (groups of three digits).</td>
          </tr>

          <tr>
           <td><strong><code>MON_GROUPING</code></strong></td>
           <td>Like <em>&quot;grouping&quot;</em> element.</td>
          </tr>

          <tr>
           <td><strong><code>POSITIVE_SIGN</code></strong></td>
           <td>Sign for positive values.</td>
          </tr>

          <tr>
           <td><strong><code>NEGATIVE_SIGN</code></strong></td>
           <td>Sign for negative values.</td>
          </tr>

          <tr>
           <td><strong><code>INT_FRAC_DIGITS</code></strong></td>
           <td>International fractional digits.</td>
          </tr>

          <tr>
           <td><strong><code>FRAC_DIGITS</code></strong></td>
           <td>Local fractional digits.</td>
          </tr>

          <tr>
           <td><strong><code>P_CS_PRECEDES</code></strong></td>
           <td>Returns 1 if <strong><code>CURRENCY_SYMBOL</code></strong> precedes a positive value.</td>
          </tr>

          <tr>
           <td><strong><code>P_SEP_BY_SPACE</code></strong></td>
           <td>Returns 1 if a space separates <strong><code>CURRENCY_SYMBOL</code></strong> from a positive value.</td>
          </tr>

          <tr>
           <td><strong><code>N_CS_PRECEDES</code></strong></td>
           <td>Returns 1 if <strong><code>CURRENCY_SYMBOL</code></strong> precedes a negative value.</td>
          </tr>

          <tr>
           <td><strong><code>N_SEP_BY_SPACE</code></strong></td>
           <td>Returns 1 if a space separates <strong><code>CURRENCY_SYMBOL</code></strong> from a negative value.</td>
          </tr>

          <tr>
           <td><strong><code>P_SIGN_POSN</code></strong></td>
           <td rowspan="2" style="vertical-align: middle;">
            <ul class="itemizedlist">
             <li class="listitem">
              <span class="simpara">
                Returns 0 if parentheses surround the quantity and <strong><code>CURRENCY_SYMBOL</code></strong>.
              </span>
             </li>
             <li class="listitem">
              <span class="simpara">
               Returns 1 if the sign string precedes the quantity and <strong><code>CURRENCY_SYMBOL</code></strong>.
              </span>
             </li>
             <li class="listitem">
              <span class="simpara">
               Returns 2 if the sign string follows the quantity and <strong><code>CURRENCY_SYMBOL</code></strong>.
              </span>
             </li>
             <li class="listitem">
              <span class="simpara">
               Returns 3 if the sign string immediately precedes the <strong><code>CURRENCY_SYMBOL</code></strong>.
              </span>
             </li>
             <li class="listitem">
              <span class="simpara">
               Returns 4 if the sign string immediately follows the <strong><code>CURRENCY_SYMBOL</code></strong>.
              </span>
             </li>
            </ul>
           </td>
          </tr>

          <tr>
           <td><strong><code>N_SIGN_POSN</code></strong></td>
          </tr>

          <tr>
           <td colspan="2" style="text-align: center;"><em class="emphasis">LC_NUMERIC Category Constants</em></td>
          </tr>

          <tr>
           <td><strong><code>DECIMAL_POINT</code></strong></td>
           <td>Decimal point character.</td>
          </tr>

          <tr>
           <td><strong><code>RADIXCHAR</code></strong></td>
           <td>Same value as <strong><code>DECIMAL_POINT</code></strong>.</td>
          </tr>

          <tr>
           <td><strong><code>THOUSANDS_SEP</code></strong></td>
           <td>Separator character for thousands (groups of three digits).</td>
          </tr>

          <tr>
           <td><strong><code>THOUSEP</code></strong></td>
           <td>Same value as <strong><code>THOUSANDS_SEP</code></strong>.</td>
          </tr>

          <tr>
           <td><strong><code>GROUPING</code></strong></td>
           <td class="empty">&nbsp;</td>
          </tr>

          <tr>
           <td colspan="2" style="text-align: center;"><em class="emphasis">LC_MESSAGES Category Constants</em></td>
          </tr>

          <tr>
           <td><strong><code>YESEXPR</code></strong></td>
           <td>Regex string for matching <em>&quot;yes&quot;</em> input.</td>
          </tr>

          <tr>
           <td><strong><code>NOEXPR</code></strong></td>
           <td>Regex string for matching <em>&quot;no&quot;</em> input.</td>
          </tr>

          <tr>
           <td><strong><code>YESSTR</code></strong></td>
           <td>Output string for <em>&quot;yes&quot;</em>.</td>
          </tr>

          <tr>
           <td><strong><code>NOSTR</code></strong></td>
           <td>Output string for <em>&quot;no&quot;</em>.</td>
          </tr>

          <tr>
           <td colspan="2" style="text-align: center;"><em class="emphasis">LC_CTYPE Category Constants</em></td>
          </tr>

          <tr>
           <td><strong><code>CODESET</code></strong></td>
           <td>Return a string with the name of the character encoding.</td>
          </tr>

         </tbody>
        
       </table>

      </p>
     </dd>

    </dt>

   </dl>

  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.nl-langinfo-returnvalues">
  <h3 class="title">Return Values</h3>
  <p class="para">
   Returns the element as a string, or <strong><code>FALSE</code></strong> if <em><code class="parameter">item</code></em>
   is not valid.
  </p>
 </div>


 <div class="refsect1 notes" id="refsect1-function.nl-langinfo-notes">
  <h3 class="title">Notes</h3>
  <blockquote class="note"><p><strong class="note">Note</strong>: <span class="simpara">This function is not
implemented on Windows platforms.</span></p></blockquote>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.nl-langinfo-seealso">
  <h3 class="title">See Also</h3>
  <p class="para">
   <ul class="simplelist">
    <li class="member"> <span class="function"><a href="function.setlocale.html" class="function" rel="rdfs-seeAlso">setlocale()</a> - Set locale information</span></li>
    <li class="member"> <span class="function"><a href="function.localeconv.html" class="function" rel="rdfs-seeAlso">localeconv()</a> - Get numeric formatting information</span></li>
   </ul>
  </p>
 </div>


</div><hr /><div class="manualnavbar" style="text-align: center;">
 <div class="prev" style="text-align: left; float: left;"><a href="function.money-format.html">money_format</a></div>
 <div class="next" style="text-align: right; float: right;"><a href="function.nl2br.html">nl2br</a></div>
 <div class="up"><a href="ref.strings.html">String Functions</a></div>
 <div class="home"><a href="index.html">PHP Manual</a></div>
</div></body></html>