mirror of
https://gitlab.com/harald.mueller/aktuelle.kurse.git
synced 2024-10-19 09:55:03 +02:00
177 lines
9.9 KiB
HTML
177 lines
9.9 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<title>setlocale</title>
|
|
<link rel="stylesheet" type="text/css" href="../../src/self.css">
|
|
<meta name="description" content="Ändert die lokalen Einstellungen eines Landes">
|
|
<meta name="keywords" content="SELFPHP, PHP, String-Funktionen, setlocale">
|
|
<meta name="author" content="Damir Enseleit, mail@selfphp.info">
|
|
<meta name="DC.Contributer" content="Matthias Hupp, m.hupp@selfphp3.de">
|
|
<meta name="DC.Publisher" content="Damir Enseleit, mail@selfphp.info">
|
|
<meta name="DC.Date" content="2001-08-24T12:18+01:00">
|
|
<meta name="DC.Identifier" content="http://www.selfphp3.de/funktionsreferenz/string_funktionen/setlocale.html">
|
|
<meta name="DC.Language" content="de">
|
|
<meta name="DC.Rights" content="../../editorial/index.html">
|
|
<meta name="SELF.Firstdate" content="2001-08-24T12:18+01:00">
|
|
<meta name="SELF.Version" content="1">
|
|
<meta name="SELF.Pagetype" content="Information">
|
|
<meta name="SELF.Path" content="SELFPHP == ../../index.php // Funktionsreferenz == ../index.php // String-Funktionen == index.html">
|
|
</head>
|
|
<body bgcolor="#FFFFFF" text="#000000" link="#AA5522" vlink="#772200" alink="#000000">
|
|
|
|
<table cellpadding="4" cellspacing="0" border="0" width="100%">
|
|
<tr>
|
|
<td bgcolor="#FFEEDD" class="nav"><a class="an" name="top"><img src="../../src/refkap.gif" width="16" height="13" border="0" alt="Teil von"></a> <a href="../../index.html"><b>SELFPHP</b></a>/<a href="../../navigation/index.html">Navigationshilfen</a> <img src="../../src/refkap.gif" width="16" height="13" border="0" alt="Teil von"> <a href="../index.html"><b>Funktionsreferenz</b></a> <img src="../../src/refkap.gif" width="16" height="13" border="0" alt="Teil von"> <a href="index.html"><b>String-Funktionen</b></a></td>
|
|
</tr>
|
|
</table><table cellpadding="4" cellspacing="0" border="0" width="100%">
|
|
<tr>
|
|
<td bgcolor="#EEEEEE" class="doc" width="110"><img src="../../src/logo.gif" width="106" height="109" border="0" alt="SEL.html"></td>
|
|
<td bgcolor="#EEEEEE" class="doc" valign="bottom" width="100%">
|
|
<h2>setlocale</h2>
|
|
<tr>
|
|
<td bgcolor="#EEEEEE" class="doc" valign="top" align="center">
|
|
<img src="../../src/dokx.gif" width="30" height="20" vspace="6" border="0" alt="Informationsseite">
|
|
</td>
|
|
<td bgcolor="#FFFFFF" valign="top" nowrap>
|
|
<p>
|
|
<img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"> <a href="#befehl"><b>Befehl</b></a><br>
|
|
<img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"> <a href="#version"><b>Version</b></a><br>
|
|
<img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"> <a href="#beschreibung"><b>Beschreibung</b></a><br>
|
|
<img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"> <a href="#beispiel"><b>Beispiel</b></a><br>
|
|
<img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"> <a href="#ausgabe"><b>Ausgabe</b></a><br>
|
|
</p>
|
|
</td>
|
|
</tr><tr><td colspan=2 bgcolor="#EEEEEE" class="doc"><a href="#bottom"><img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"></a> </td></tr>
|
|
</table>
|
|
|
|
|
|
|
|
<h2 class="Sh2"><a class="an" name="befehl">Befehl</a></h2>
|
|
|
|
|
|
|
|
<table width="100%" cellpadding=10><tr>
|
|
<td class="xmpcode" bgcolor="#E4EEFF">string <b>setlocale</b>(string category,
|
|
string locale)</td>
|
|
</tr></table>
|
|
|
|
<p> </p>
|
|
|
|
<table bgcolor="#EEEEEE" class="doc" width="100%"><tr><td>
|
|
<a href="#top"><img src="../../src/up.gif" width="14" height="10" border="0" alt="nach oben"></a><a href="#bottom"><img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"></a> 
|
|
</td></tr></table>
|
|
|
|
<h2 class="Sh2"><a class="an" name="version">Version</a></h2>
|
|
|
|
<table width="100%" cellpadding=10 height="32">
|
|
<tr>
|
|
<td class="xmpcode" bgcolor="#E4EEFF" height="20">PHP 3, PHP 4 >= 4.0b1</td>
|
|
</tr></table>
|
|
|
|
<p> </p>
|
|
|
|
<table bgcolor="#EEEEEE" class="doc" width="100%"><tr><td>
|
|
<a href="#top"><img src="../../src/up.gif" width="14" height="10" border="0" alt="nach oben"></a><a href="#bottom"><img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"></a> 
|
|
</td></tr></table>
|
|
|
|
<h2 class="Sh2"><a class="an" name="beschreibung">Beschreibung</a></h2>
|
|
|
|
<table width="100%" cellpadding=10 height="122">
|
|
<tr>
|
|
<td class="xmpcode" bgcolor="#E4EEFF" height="108">
|
|
<p>Mit setlocale() kann man die Lokalisierungseinstellungen der angegebenen<br>
|
|
Kategorie (category) auf ein bestimmtes Land (locale) setzen. Die Auswahl
|
|
des<br>
|
|
Landes ist optional; falls der Wert local leer ist (""), so
|
|
wird der Wert der<br>
|
|
entsprechenden Umgebungsvariablen genommen. Ist local "0", werden
|
|
die<br>
|
|
Einstellungen nicht verändert, sondern der zuvor gesetzte Wert zurückgegeben.</p>
|
|
<p>Folgende Kategorien stehen zur Auswahl:<br>
|
|
LC_ALL - für alle Einstellungen<br>
|
|
LC_COLLATE - Vergleich von Strings (Zeichenketten)<br>
|
|
LC_CTYPE - Umwandlung von Strings (Zeichenkette), z.B. strtoupper()<br>
|
|
LC_MONETARY - für Währungsangaben<br>
|
|
LC_NUMERIC - für Dezimaltrennzeichen (numerische Operatoren)<br>
|
|
LC_TIME - für Datum- und Zeitformatierungen bei strftime()</p>
|
|
<p>Siehe auch:</p>
|
|
<ul>
|
|
<li><a href="../datums_und_zeit_funktionen/strftime.html">strftime()</a></li>
|
|
</ul>
|
|
</td>
|
|
</tr></table>
|
|
|
|
<p> </p>
|
|
|
|
<table bgcolor="#EEEEEE" class="doc" width="100%"><tr><td>
|
|
<a href="#top"><img src="../../src/up.gif" width="14" height="10" border="0" alt="nach oben"></a><a href="#bottom"><img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"></a> 
|
|
</td></tr></table>
|
|
|
|
<h2 class="Sh2"><a class="an" name="beispiel">Beispiel</a></h2>
|
|
|
|
<table width="100%" cellpadding=10 height="66">
|
|
<tr>
|
|
<td class="xmpcode" bgcolor="#E4EEFF">
|
|
<pre><?PHP<br>setlocale ("LC_TIME", "de_DE"); <br>echo strftime("%A, %e %B %Y, in Deutschland"); <br>echo "<br>";<br>setlocale ("LC_TIME", "fr_CA"); <br>echo strftime("%A, %e %B %Y , in Frankreich"); <br>echo "<br>";<br>setlocale ("LC_TIME", "fi_FI"); <br>echo strftime("%A, %e %B %Y , in Finnland");<br>echo "<br>";<br>setlocale ("LC_TIME", "it_IT"); <br>echo strftime("%A, %e %B %Y , in Italien"); <br>echo "<br>";<br>setlocale ("LC_TIME", "tr_TR"); <br>echo strftime("%A, %e %B %Y , in Türkei"); <br>echo "<br>";<br>setlocale ("LC_TIME", "nl_NL"); <br>echo strftime("%A, %e %B %Y , in Niederlande"); <br>echo "<br>";<br>setlocale ("LC_TIME", "hu_HU"); <br>echo strftime("%A, %e %B %Y , in Ungarn"); <br>echo "<br>";<br>setlocale ("LC_TIME", "pl_PL"); <br>echo strftime("%A, %e %B %Y , in Polen"); <br>echo "<br>";<br>?></pre>
|
|
<p></p>
|
|
</td>
|
|
</tr></table>
|
|
|
|
<p> </p>
|
|
|
|
<table bgcolor="#EEEEEE" class="doc" width="100%"><tr><td>
|
|
<a href="#top"><img src="../../src/up.gif" width="14" height="10" border="0" alt="nach oben"></a><a href="#bottom"><img src="../../src/down.gif" width="14" height="10" border="0" alt="nach unten"></a> 
|
|
</td></tr></table>
|
|
|
|
|
|
<h2 class="Sh2"><a class="an" name="ausgabe">Ausgabe</a></h2>
|
|
|
|
<table width="100%" cellpadding=10 height="45">
|
|
<tr>
|
|
<td class="xmpcode" bgcolor="#E4EEFF" height="57">
|
|
<p>Sonntag, 22 Juli 2001, in Deutschland<br>
|
|
dimanche, 22 juillet 2001 , in Frankreich<br>
|
|
sunnuntai, 22 heinäkuu 2001 , in Finnland<br>
|
|
domenica, 22 luglio 2001 , in Italien<br>
|
|
Pazar, 22 Temmuz 2001 , in Türkei<br>
|
|
zondag, 22 juli 2001 , in Niederlande<br>
|
|
VASÁRNAP, 22 JÚLIUS 2001 , in Ungarn<br>
|
|
niedziela, 22 lipiec 2001 , in Polen</p>
|
|
<p></p>
|
|
</td>
|
|
</tr></table>
|
|
|
|
|
|
<p> </p>
|
|
|
|
|
|
<table cellpadding="4" cellspacing="0" border="0" width="100%">
|
|
<tr><td colspan=2 bgcolor="#EEEEEE" class="doc">
|
|
<a href="#top"><img src="../../src/up.gif" width="14" height="10" border="0" alt="nach oben"></a>
|
|
</td></tr>
|
|
<tr>
|
|
<td bgcolor="#EEEEEE" class="doc" align="right" width="110">weiter:<a href="similar_text.html"><img src="../../src/next.gif" width="10" height="10" border="0" hspace="10" alt="weiter"></a></td>
|
|
<td bgcolor="#FFFFFF"><img src="../../src/dok.gif" width="15" height="10" border="0" alt="Seite">
|
|
<a href="similar_text.html"><b>similar_text</b></a> </td>
|
|
</tr>
|
|
<tr>
|
|
<td bgcolor="#EEEEEE" class="doc" align="right" width="110">zurück:<a href="rtrim.html"><img src="../../src/prev.gif" width="10" height="10" border="0" hspace="10" alt="zurück"></a></td>
|
|
<td bgcolor="#FFFFFF" width="100%"><img src="../../src/dok.gif" width="15" height="10" border="0" alt="Seite">
|
|
<a href="rtrim.html"><b>rtrim</b></a> </td>
|
|
</tr>
|
|
<tr><td colspan=2 bgcolor="#EEEEEE" class="doc"> </td></tr>
|
|
</table><table cellpadding="4" cellspacing="0" border="0" width="100%">
|
|
<tr>
|
|
<td bgcolor="#FFEEDD" class="nav"><a class="an" name="bottom"><img src="../../src/refkap.gif" width="16" height="13" border="0" alt="Teil von"></a>
|
|
<a href="../../index.html"><b>SELFPHP</b></a>/<a href="../../navigation/index.html">Navigationshilfen</a> <img src="../../src/refkap.gif" width="16" height="13" border="0" alt="Teil von">
|
|
<a href="../index.html"><b>Funktionsreferenz</b></a> <img src="../../src/refkap.gif" width="16" height="13" border="0" alt="Teil von">
|
|
<a href="index.html"><b>String-Funktionen</b></a></td>
|
|
</tr>
|
|
</table>
|
|
|
|
<p><a class="an" name="bottom">© 2001, 2002, 2003</A> <img src="../../src/mail.gif" width="15" height="10" border="0" alt="E-Mail"> <a href="mailto:mail@selfphp.info">Damir Enseleit, mail@selfphp.info</a></p>
|
|
|
|
|
|
|
|
</body>
|
|
</html> |