<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/ref.strings.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'ja',
  ),
  'this' => 
  array (
    0 => 'function.nl-langinfo.php',
    1 => 'nl_langinfo',
    2 => '言語およびロケール情報を検索する',
  ),
  'up' => 
  array (
    0 => 'ref.strings.php',
    1 => 'String 関数',
  ),
  'prev' => 
  array (
    0 => 'function.money-format.php',
    1 => 'money_format',
  ),
  'next' => 
  array (
    0 => 'function.nl2br.php',
    1 => 'nl2br',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'ja',
    'path' => 'reference/strings/functions/nl-langinfo.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<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, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">nl_langinfo</span> &mdash; <span class="dc-title">言語およびロケール情報を検索する</span></p>

 </div>
 
 <div class="refsect1 description" id="refsect1-function.nl-langinfo-description">
  <h3 class="title">説明</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>nl_langinfo</strong></span>(<span class="methodparam"><span class="type"><a href="language.types.integer.php" class="type int">int</a></span> <code class="parameter">$item</code></span>): <span class="type"><span class="type"><a href="language.types.string.php" class="type string">string</a></span>|<span class="type"><a href="language.types.singleton.php" class="type false">false</a></span></span></div>

  <p class="para rdfs-comment">
   <span class="function"><strong>nl_langinfo()</strong></span>
   はロケールカテゴリの独立した要素にアクセスするために使用されます。
   <span class="function"><a href="function.localeconv.php" class="function">localeconv()</a></span> と異なり、全ての要素を返します。
   <span class="function"><strong>nl_langinfo()</strong></span> はいかなる特定要素も取得可能です。
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.nl-langinfo-parameters">
  <h3 class="title">パラメータ</h3>
  <p class="para">
   <dl>
    
     <dt><code class="parameter">item</code></dt>
     <dd>
      <p class="para">
       <code class="parameter">item</code> は要素の整数値、もしくは要素の定数名です。
       以下は、使用される <code class="parameter">item</code>
       に対する定数名と説明の一覧です。
       これらの定数のいくつかは特定のロケールに対して未定義、
       もしくは値がありません。
       <table class="doctable table">
        <caption><strong>nl_langinfo 定数</strong></caption>
        
         <col />
         <col />
         <thead>
          <tr>
           <th>定数</th>
           <th>説明</th>
          </tr>

         </thead>

         <tbody class="tbody">
          <tr>
           <td colspan="2" style="text-align: center;"><em><strong><code><a href="string.constants.php#constant.lc-time">LC_TIME</a></code></strong> カテゴリの定数</em></td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.abday-1">ABDAY_<span class="replaceable">(1-7)</span></a></code></strong></td>
           <td>一週間中の n 番目の曜日名の略式表記</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.day-1">DAY_<span class="replaceable">(1-7)</span></a></code></strong></td>
           <td>一週間中の n 番目の曜日名 (DAY_1 = 日曜日)</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.abmon-1">ABMON_<span class="replaceable">(1-12)</span></a></code></strong></td>
           <td>n 番目の月の名前の略式表記</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.mon-1">MON_<span class="replaceable">(1-12)</span></a></code></strong></td>
           <td>n 番目の月の名前</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.am-str">AM_STR</a></code></strong></td>
           <td>午前を表す文字列</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.pm-str">PM_STR</a></code></strong></td>
           <td>午後を表す文字列</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.d-t-fmt">D_T_FMT</a></code></strong></td>
           <td><span class="function"><a href="function.strftime.php" class="function">strftime()</a></span> で日時を表すためのフォーマット文字列として使用することが可能な文字列</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.d-fmt">D_FMT</a></code></strong></td>
           <td><span class="function"><a href="function.strftime.php" class="function">strftime()</a></span> で日付を表すためのフォーマット文字列として使用することが可能な文字列</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.t-fmt">T_FMT</a></code></strong></td>
           <td><span class="function"><a href="function.strftime.php" class="function">strftime()</a></span> で時刻を表すためのフォーマット文字列として使用することが可能な文字列</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.t-fmt-ampm">T_FMT_AMPM</a></code></strong></td>
           <td><span class="function"><a href="function.strftime.php" class="function">strftime()</a></span> でAM/PM付き 12 時間表記を表すためのフォーマット文字列として使用することが可能な文字列</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.era">ERA</a></code></strong></td>
           <td>ロケール固有の元号付きフォーマット</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.era-year">ERA_YEAR</a></code></strong></td>
           <td>ロケール固有の元号付きフォーマットでの年</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.era-d-t-fmt">ERA_D_T_FMT</a></code></strong></td>
           <td>ロケール固有の元号付きフォーマットでの日時 (<span class="function"><a href="function.strftime.php" class="function">strftime()</a></span> で使用可能な文字列)</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.era-d-fmt">ERA_D_FMT</a></code></strong></td>
           <td>ロケール固有の元号付きフォーマットでの日付 (<span class="function"><a href="function.strftime.php" class="function">strftime()</a></span> で使用可能な文字列)</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.era-t-fmt">ERA_T_FMT</a></code></strong></td>
           <td>ロケール固有の元号付きフォーマットでの時刻 (<span class="function"><a href="function.strftime.php" class="function">strftime()</a></span> で使用可能な文字列)</td>
          </tr>

          <tr>
           <td colspan="2" style="text-align: center;"><em><strong><code><a href="string.constants.php#constant.lc-monetary">LC_MONETARY</a></code></strong> カテゴリの定数</em></td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.int-curr-symbol">INT_CURR_SYMBOL</a></code></strong></td>
           <td>国際通貨記号</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong></td>
           <td>地域通貨記号</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.crncystr">CRNCYSTR</a></code></strong></td>
           <td><strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> と同じ値</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.mon-decimal-point">MON_DECIMAL_POINT</a></code></strong></td>
           <td>小数点文字</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.mon-thousands-sep">MON_THOUSANDS_SEP</a></code></strong></td>
           <td>1000 単位桁区切り (3 桁ごとのグループ化) の区切り文字</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.mon-grouping">MON_GROUPING</a></code></strong></td>
           <td>&#039;grouping&#039; と同じ</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.positive-sign">POSITIVE_SIGN</a></code></strong></td>
           <td>正値の表示に使用される記号</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.negative-sign">NEGATIVE_SIGN</a></code></strong></td>
           <td>負値の表示に使用される記号</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.int-frac-digits">INT_FRAC_DIGITS</a></code></strong></td>
           <td>国際的な方法で表現する際の小数点以下の桁数</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.frac-digits">FRAC_DIGITS</a></code></strong></td>
           <td>地域的な方法で表現する際の小数点以下の桁数</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.p-cs-precedes">P_CS_PRECEDES</a></code></strong></td>
           <td><strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> の前に正値がある場合 1 を返す</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.p-sep-by-space">P_SEP_BY_SPACE</a></code></strong></td>
           <td><strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> と正値がスペースで区切られる場合 1 を返す</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.n-cs-precedes">N_CS_PRECEDES</a></code></strong></td>
           <td><strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> の前に負値がある場合 1 を返す</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.n-sep-by-space">N_SEP_BY_SPACE</a></code></strong></td>
           <td><strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> と負値がスペースで区切られる場合 1 を返す</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.p-sign-posn">P_SIGN_POSN</a></code></strong></td>
           <td rowspan="2" style="vertical-align: middle;">
            <ul class="itemizedlist">
             <li class="listitem">
              <span class="simpara">
               量および <strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> を括弧で括る場合、0 を返す
              </span>
             </li>
             <li class="listitem">
              <span class="simpara">
               量および <strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> の前に符号文字列を置く場合、1 を返す
              </span>
             </li>
             <li class="listitem">
              <span class="simpara">
               量および <strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> の後に符号文字列を置く場合、2 を返す
              </span>
             </li>
             <li class="listitem">
              <span class="simpara">
               <strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> の直前に符号文字列を置く場合、3 を返す
              </span>
             </li>
             <li class="listitem">
              <span class="simpara">
               <strong><code><a href="string.constants.php#constant.currency-symbol">CURRENCY_SYMBOL</a></code></strong> の直後に符号文字列を置く場合、4 を返す
              </span>
             </li>
            </ul>
           </td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.n-sign-posn">N_SIGN_POSN</a></code></strong></td>
          </tr>

          <tr>
           <td colspan="2" style="text-align: center;"><em><strong><code><a href="string.constants.php#constant.lc-numeric">LC_NUMERIC</a></code></strong> カテゴリの定数</em></td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.decimal-point">DECIMAL_POINT</a></code></strong></td>
           <td>小数点文字</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.radixchar">RADIXCHAR</a></code></strong></td>
           <td><strong><code><a href="string.constants.php#constant.decimal-point">DECIMAL_POINT</a></code></strong> と同じ値</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.thousands-sep">THOUSANDS_SEP</a></code></strong></td>
           <td>1000 単位桁区切り (3 桁ごとのグループ化) の区切り文字</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.thousep">THOUSEP</a></code></strong></td>
           <td><strong><code><a href="string.constants.php#constant.thousands-sep">THOUSANDS_SEP</a></code></strong> と同じ値</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.grouping">GROUPING</a></code></strong></td>
           <td class="empty">&nbsp;</td>
          </tr>

          <tr>
           <td colspan="2" style="text-align: center;"><em><strong><code><a href="string.constants.php#constant.lc-messages">LC_MESSAGES</a></code></strong> カテゴリの定数</em></td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.yesexpr">YESEXPR</a></code></strong></td>
           <td><code class="literal">&quot;はい&quot;</code> の入力にマッチさせるための正規表現</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.noexpr">NOEXPR</a></code></strong></td>
           <td><code class="literal">&quot;いいえ&quot;</code> の入力にマッチさせるための正規表現</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.yesstr">YESSTR</a></code></strong></td>
           <td><code class="literal">&quot;はい&quot;</code> のための出力文字列</td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.nostr">NOSTR</a></code></strong></td>
           <td><code class="literal">&quot;いいえ&quot;</code> のための出力文字列</td>
          </tr>

          <tr>
           <td colspan="2" style="text-align: center;"><em><strong><code><a href="string.constants.php#constant.lc-ctype">LC_CTYPE</a></code></strong> カテゴリの定数</em></td>
          </tr>

          <tr>
           <td><strong><code><a href="string.constants.php#constant.codeset">CODESET</a></code></strong></td>
           <td>文字エンコーディング名の文字列を返す</td>
          </tr>

         </tbody>
        
       </table>

      </p>
     </dd>
    
   </dl>
  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.nl-langinfo-returnvalues">
  <h3 class="title">戻り値</h3>
  <p class="para">
   要素を文字列で返します。<code class="parameter">item</code>
   が有効でない場合は <strong><code><a href="reserved.constants.php#constant.false">false</a></code></strong> を返します。
  </p>
 </div>


 <div class="refsect1 examples" id="refsect1-function.nl-langinfo-examples">
  <h3 class="title">例</h3>
  <p class="para">
   <div class="example" id="example-1">
    <p><strong>例1 <span class="function"><strong>nl_langinfo()</strong></span> の例</strong></p>
    <div class="example-contents">
<div class="annotation-interactive phpcode"><code><span style="color: #000000"><span style="color: #0000BB">&lt;?php<br /><br />var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">nl_langinfo</span><span style="color: #007700">(</span><span style="color: #0000BB">CODESET</span><span style="color: #007700">));<br /></span><span style="color: #0000BB">var_dump</span><span style="color: #007700">(</span><span style="color: #0000BB">nl_langinfo</span><span style="color: #007700">(</span><span style="color: #0000BB">YESEXPR</span><span style="color: #007700">));<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
    </div>

    <div class="example-contents"><p>上の例の出力は、
たとえば以下のようになります。</p></div>
    <div class="example-contents screen">
<div class="annotation-interactive examplescode"><pre class="examplescode">string(14) &quot;ANSI_X3.4-1968&quot;
string(5) &quot;^[yY]&quot;</pre>
</div>
    </div>
   </div>
  </p>
 </div>


 <div class="refsect1 notes" id="refsect1-function.nl-langinfo-notes">
  <h3 class="title">注意</h3>
  <blockquote class="note"><p><strong class="note">注意</strong>: <span class="simpara">この関数は Windows 環境にはまだ実装されていません。
</span></p></blockquote>
 </div>


 <div class="refsect1 seealso" id="refsect1-function.nl-langinfo-seealso">
  <h3 class="title">参考</h3>
  <p class="para">
   <ul class="simplelist">
    <li><span class="function"><a href="function.setlocale.php" class="function" rel="rdfs-seeAlso">setlocale()</a> - ロケール情報を設定する</span></li>
    <li><span class="function"><a href="function.localeconv.php" class="function" rel="rdfs-seeAlso">localeconv()</a> - 数値に関するフォーマット情報を得る</span></li>
   </ul>
  </p>
 </div>


</div><?php manual_footer($setup); ?>