mirror of
https://github.com/php/doc-de.git
synced 2026-03-24 15:22:14 +01:00
fixed svn properties git-svn-id: https://svn.php.net/repository/phpdoc/de/trunk@283886 c90b9560-bf6c-de11-be94-00142212c4b1
88 lines
2.5 KiB
XML
88 lines
2.5 KiB
XML
<?xml version="1.0" encoding="iso-8859-1"?>
|
|
<!-- $Revision$ -->
|
|
<!-- EN-Revision: n/a Maintainer: nobody Status: ready -->
|
|
<!-- CREDITS: tom -->
|
|
<refentry xml:id="function.array-unshift" xmlns="http://docbook.org/ns/docbook">
|
|
<refnamediv>
|
|
<refname>array_unshift</refname>
|
|
<refpurpose>
|
|
Fügt ein oder mehr Elemente am Anfang eines Arrays ein
|
|
</refpurpose>
|
|
</refnamediv>
|
|
<refsect1 role="description">
|
|
&reftitle.description;
|
|
<methodsynopsis>
|
|
<type>int</type><methodname>array_unshift</methodname>
|
|
<methodparam><type>array</type><parameter role="reference">array</parameter></methodparam>
|
|
<methodparam><type>mixed</type><parameter>var</parameter></methodparam>
|
|
<methodparam choice="opt"><type>mixed</type><parameter>...</parameter></methodparam>
|
|
</methodsynopsis>
|
|
<para>
|
|
<function>array_unshift</function> fügt die übergebenen Elemente
|
|
am Anfang von <parameter>array</parameter> ein. Beachten Sie,
|
|
dass die Liste von Elementen als Ganzes eingefügt wird, sodass
|
|
die eingefügten Elemente die selbe Reihenfolge haben. Die
|
|
numerischen Schlüssel werden so modifiziert, dass bei null zu
|
|
zählen begonnen wird, Strings als Schlüssel bleiben unverändert.
|
|
</para>
|
|
<para>
|
|
Diese Funktion gibt die neue Anzahl der in
|
|
<parameter>array</parameter> enthaltenen Elemente zurück.
|
|
</para>
|
|
<para>
|
|
<example>
|
|
<title><function>array_unshift</function></title>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
$queue = array("Orange", "Banane");
|
|
array_unshift($queue, "Apfel", "Himbeere");
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
<para>
|
|
Als Ergebnis enthält <varname>$queue</varname>
|
|
die folgenden Elemente:
|
|
</para>
|
|
<screen role="php">
|
|
<![CDATA[
|
|
Array
|
|
(
|
|
[0] => Apfel
|
|
[1] => Himbeere
|
|
[2] => Orange
|
|
[3] => Banane
|
|
)
|
|
]]>
|
|
</screen>
|
|
</example>
|
|
</para>
|
|
<para>
|
|
Siehe auch <function>array_shift</function>,
|
|
<function>array_push</function> und
|
|
<function>array_pop</function>.
|
|
</para>
|
|
</refsect1>
|
|
</refentry>
|
|
|
|
<!-- Keep this comment at the end of the file
|
|
Local variables:
|
|
mode: sgml
|
|
sgml-omittag:t
|
|
sgml-shorttag:t
|
|
sgml-minimize-attributes:nil
|
|
sgml-always-quote-attributes:t
|
|
sgml-indent-step:1
|
|
sgml-indent-data:t
|
|
indent-tabs-mode:nil
|
|
sgml-parent-document:nil
|
|
sgml-default-dtd-file:"../../../../manual.ced"
|
|
sgml-exposed-tags:nil
|
|
sgml-local-catalogs:nil
|
|
sgml-local-ecat-files:nil
|
|
End:
|
|
vim600: syn=xml fen fdm=syntax fdl=2 si
|
|
vim: et tw=78 syn=sgml
|
|
vi: ts=1 sw=1
|
|
-->
|