<?php
include_once $_SERVER['DOCUMENT_ROOT'] . '/include/shared-manual.inc';
$TOC = array();
$TOC_DEPRECATED = array();
$PARENTS = array();
include_once dirname(__FILE__) ."/toc/ref.gettext.inc";
$setup = array (
  'home' => 
  array (
    0 => 'index.php',
    1 => 'PHP Manual',
  ),
  'head' => 
  array (
    0 => 'UTF-8',
    1 => 'pt_BR',
  ),
  'this' => 
  array (
    0 => 'function.textdomain.php',
    1 => 'textdomain',
    2 => 'Define o dom&iacute;nio padr&atilde;o',
  ),
  'up' => 
  array (
    0 => 'ref.gettext.php',
    1 => 'Fun&ccedil;&otilde;es da Gettext',
  ),
  'prev' => 
  array (
    0 => 'function.ngettext.php',
    1 => 'ngettext',
  ),
  'next' => 
  array (
    0 => 'book.iconv.php',
    1 => 'iconv',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'pt_BR',
    'path' => 'reference/gettext/functions/textdomain.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="function.textdomain" class="refentry">
 <div class="refnamediv">
  <h1 class="refname">textdomain</h1>
  <p class="verinfo">(PHP 4, PHP 5, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">textdomain</span> &mdash; <span class="dc-title">Define o domínio padrão</span></p>

 </div>
 <div class="refsect1 description" id="refsect1-function.textdomain-description">
  <h3 class="title">Descrição</h3>
  <div class="methodsynopsis dc-description">
   <span class="methodname"><strong>textdomain</strong></span>(<span class="methodparam"><span class="type"><span class="type"><a href="language.types.null.php" class="type null">?</a></span><span class="type"><a href="language.types.string.php" class="type string">string</a></span></span> <code class="parameter">$domain</code><span class="initializer"> = <strong><code><a href="reserved.constants.php#constant.null">null</a></code></strong></span></span>): <span class="type"><a href="language.types.string.php" class="type string">string</a></span></div>

  <p class="para rdfs-comment">
   Esta função define o domínio a ser pesquisado quando chamadas são
   feitas para <span class="function"><a href="function.gettext.php" class="function">gettext()</a></span>, geralmente o nome de um
   aplicativo.
  </p>
 </div>


 <div class="refsect1 parameters" id="refsect1-function.textdomain-parameters">
  <h3 class="title">Parâmetros</h3>
  <p class="para">
   <dl>
    
     <dt><code class="parameter">domain</code></dt>
     <dd>
      <p class="para">
       O novo domínio de mensagem, ou <strong><code><a href="reserved.constants.php#constant.null">null</a></code></strong> para obter a configuração atual
       sem alterá-la
      </p>
     </dd>
    
   </dl>
  </p>
 </div>


 <div class="refsect1 returnvalues" id="refsect1-function.textdomain-returnvalues">
  <h3 class="title">Valor Retornado</h3>
  <p class="para">
   Se for bem-sucedida, esta função retorna o domínio de mensagem
   atual, após possivelmente alterá-lo.
  </p>
 </div>


 <div class="refsect1 errors" id="refsect1-function.textdomain-errors">
  <h3 class="title">Erros/Exceções</h3>
  <p class="simpara">
   Lança um <span class="exceptionname"><a href="class.valueerror.php" class="exceptionname">ValueError</a></span> se <code class="parameter">domain</code>
   for uma <span class="type"><a href="language.types.string.php" class="type string">string</a></span> vazia.
  </p>
 </div>


 <div class="refsect1 changelog" id="refsect1-function.textdomain-changelog">
  <h3 class="title">Registro de Alterações</h3>
  <table class="doctable informaltable">
   
    <thead>
     <tr>
      <th>Versão</th>
      <th>Descrição</th>
     </tr>

    </thead>

    <tbody class="tbody">
     <tr>
      <td>8.4.0</td>
      <td>
       Agora lança um <span class="exceptionname"><a href="class.valueerror.php" class="exceptionname">ValueError</a></span> se <code class="parameter">domain</code>
       for uma <span class="type"><a href="language.types.string.php" class="type string">string</a></span> vazia.
      </td>
     </tr>

     <tr>
      <td>8.4.0</td>
      <td>
       <code class="parameter">domain</code> agora é opcional.
       Anteriormente, sempre tinha que ser especificado.
      </td>
     </tr>

    </tbody>
   
  </table>

 </div>


 <div class="refsect1 notes" id="refsect1-function.textdomain-notes">
  <h3 class="title">Notas</h3>
  <blockquote class="note"><p><strong class="note">Nota</strong>: 
   <p class="para">
    As informações do <span class="function"><strong>textdomain()</strong></span> são mantidas por processo,
    não por thread.
   </p>
  </p></blockquote>
 </div>

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