cvs: phpdoc-hu /reference/simplexml/functions simplexml-element-addChild.xml

From: Date: Fri, 09 Jun 2006 04:11:42 +0000
Subject: cvs: phpdoc-hu /reference/simplexml/functions simplexml-element-addChild.xml
Groups: php.doc.hu 
Request: Send a blank email to doc-hu+get-1402@lists.php.net to get a copy of this message
chappy Fri Jun 9 04:11:42 2006 UTC Added files: /phpdoc-hu/reference/simplexml/functions simplexml-element-addChild.xml Log: SimpleXMLElement->addChild http://cvs.php.net/viewcvs.cgi/phpdoc-hu/reference/simplexml/functions/simplexml-element-addChild.xml?view=markup&rev=1.1 Index: phpdoc-hu/reference/simplexml/functions/simplexml-element-addChild.xml +++ phpdoc-hu/reference/simplexml/functions/simplexml-element-addChild.xml <?xml version="1.0" encoding="iso-8859-2"?> <!-- $Revision: 1.1 $ --> <refentry id='function.simplexml-element-addChild'> <refnamediv> <refname>SimpleXMLElement->addChild</refname> <refpurpose> Utód elemet ad a SimpleXML elemhez. </refpurpose> </refnamediv> <refsect1 role="description"> &reftitle.description; <methodsynopsis> <type>SimpleXMLElement</type><methodname>SimpleXMLElement->addChild</methodname> <methodparam><type>string</type><parameter>name</parameter></methodparam> <methodparam choice="opt"><type>string</type><parameter>value</parameter></methodparam> <methodparam choice="opt"><type>string</type><parameter>namespace</parameter></methodparam> </methodsynopsis> <para> Utódot ad a csomóhoz és a SimpleXMLElement utóddal tér vissza. </para> </refsect1> <refsect1 role="parameters"> &reftitle.parameters; <para> <variablelist> <varlistentry> <term><parameter>name</parameter></term> <listitem> <para> A hozzáadandó utód neve. </para> </listitem> </varlistentry> <varlistentry> <term><parameter>value</parameter></term> <listitem> <para> Ha megadott, az utód értéke. </para> </listitem> </varlistentry> <varlistentry> <term><parameter>namespace</parameter></term> <listitem> <para> Ha megadott, a névtér, amihez az utód tartozik. </para> </listitem> </varlistentry> </variablelist> </para> </refsect1> <refsect1 role="returnvalues"> &reftitle.returnvalues; <para> A <literal>addChild</literal> metódus <type>SimpleXMLElement</type> objektummal tér vissza, ami az XML csomóhoz addot utódot képviseli. </para> </refsect1> <refsect1 role="examples"> &reftitle.examples; <para> <example> <title>Attribútumok és utódok hozzáadása egy SimpleXML elemhez</title> <programlisting role="php"> <![CDATA[ <?php $sxe = new SimpleXMLElement($xmlstr); // vagy használd a simplexml_load_string() függvényt $sxe->addAttribute('type', 'documentary'); $movie = $sxe->addChild('movie'); $movie->addChild('title', 'PHP2: More Parser Stories'); $movie->addChild('plot', 'This is all about the people who make it work.'); $characters = $movie->addChild('characters'); $character = $characters->addChild('character'); $character->addChild('name', 'Mr. Parser'); $character->addChild('actor', 'John Doe'); $rating = $movie->addChild('rating', '5'); $rating->addAttribute('type', 'stars'); echo $sxe->asXML(); ?> ]]> </programlisting> </example> </para> </refsect1> <refsect1 role="seealso"> &reftitle.seealso; <para> <simplelist> <member><xref linkend="function.simplexml-element-addAttribute" /></member> </simplelist> </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 -->

« previous php.doc.hu (#1402) next »