<?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 => 'it',
  ),
  'this' => 
  array (
    0 => 'function.ucfirst.php',
    1 => 'ucfirst',
    2 => 'Converte in maiuscolo il primo carattere del testo',
  ),
  'up' => 
  array (
    0 => 'ref.strings.php',
    1 => 'String Funzioni',
  ),
  'prev' => 
  array (
    0 => 'function.trim.php',
    1 => 'trim',
  ),
  'next' => 
  array (
    0 => 'function.ucwords.php',
    1 => 'ucwords',
  ),
  'alternatives' => 
  array (
  ),
  'source' => 
  array (
    'lang' => 'it',
    'path' => 'reference/strings/functions/ucfirst.xml',
  ),
  'history' => 
  array (
  ),
);
$setup["toc"] = $TOC;
$setup["toc_deprecated"] = $TOC_DEPRECATED;
$setup["parents"] = $PARENTS;
manual_setup($setup);

contributors($setup);

?>
<div id="function.ucfirst" class="refentry">
   <div class="refnamediv">
    <h1 class="refname">ucfirst</h1> 
    <p class="verinfo">(PHP 4, PHP 5, PHP 7, PHP 8)</p><p class="refpurpose"><span class="refname">ucfirst</span> &mdash; <span class="dc-title">Converte in maiuscolo il primo carattere del testo</span></p>

   </div>
   <div class="refsect1 unknown-1465" id="refsect1-function.ucfirst-unknown-1465">
    <h3 class="title">Descrizione</h3>
     <div class="methodsynopsis dc-description">
      <span class="methodname"><strong>ucfirst</strong></span>(<span class="methodparam"><span class="type"><a href="language.types.string.php" class="type string">string</a></span> <code class="parameter">$str</code></span>): <span class="type"><a href="language.types.string.php" class="type string">string</a></span></div>

    <p class="para rdfs-comment">
     Restituisce un testo in cui il primo carattere di
     <code class="parameter">str</code> è maiuscolo, se si tratta di una carattere
     alfabetico.
    </p>
    <p class="para">
     Attenzione che i &#039;caratteri alfabetici&#039; sono determinati dalle impostazioni locali. Ad esempio
     nelle impostazioni locali &quot;C&quot; di default, caratteri tipo 
     ä non saranno convertiti.
     <div class="example" id="example-1">
      <p><strong>Example #1 Esempio di uso di <span class="function"><strong>ucfirst()</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 />$foo </span><span style="color: #007700">= </span><span style="color: #DD0000">'hello world!'</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">$foo </span><span style="color: #007700">= </span><span style="color: #0000BB">ucfirst</span><span style="color: #007700">(</span><span style="color: #0000BB">$foo</span><span style="color: #007700">);             </span><span style="color: #FF8000">// Hello world!<br /><br /></span><span style="color: #0000BB">$bar </span><span style="color: #007700">= </span><span style="color: #DD0000">'HELLO WORLD!'</span><span style="color: #007700">;<br /></span><span style="color: #0000BB">$bar </span><span style="color: #007700">= </span><span style="color: #0000BB">ucfirst</span><span style="color: #007700">(</span><span style="color: #0000BB">$bar</span><span style="color: #007700">);             </span><span style="color: #FF8000">// HELLO WORLD!<br /></span><span style="color: #0000BB">$bar </span><span style="color: #007700">= </span><span style="color: #0000BB">ucfirst</span><span style="color: #007700">(</span><span style="color: #0000BB">strtolower</span><span style="color: #007700">(</span><span style="color: #0000BB">$bar</span><span style="color: #007700">)); </span><span style="color: #FF8000">// Hello world!<br /></span><span style="color: #0000BB">?&gt;</span></span></code></div>
      </div>

     </div>
    </p>
    <p class="para">
     Vedere anche <span class="function"><a href="function.strtolower.php" class="function">strtolower()</a></span>, <span class="function"><a href="function.strtoupper.php" class="function">strtoupper()</a></span>
     e <span class="function"><a href="function.ucwords.php" class="function">ucwords()</a></span>.
    </p>
   </div>

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