mirror of
https://github.com/php/doc-es.git
synced 2026-04-25 16:18:09 +02:00
647acfd269
git-svn-id: https://svn.php.net/repository/phpdoc/es/trunk@313018 c90b9560-bf6c-de11-be94-00142212c4b1
79 lines
2.0 KiB
XML
79 lines
2.0 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!-- $Revision$ -->
|
|
<!-- EN-Revision: cb0630b14901459c0bf1556e7d68f1b4c0d3796e Maintainer: chuso Status: ready -->
|
|
|
|
<phpdoc:varentry xmlns:phpdoc="http://php.net/ns/phpdoc" xml:id="reserved.variables.argc" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
|
|
<refnamediv>
|
|
<refname>$argc</refname>
|
|
<refpurpose>El número de argumentos pasados a un script</refpurpose>
|
|
</refnamediv>
|
|
|
|
<refsect1 role="description">
|
|
&reftitle.description;
|
|
<para>
|
|
Contiene el número de argumentos pasados al script actual cuando se ejecuta
|
|
desde la <link linkend="features.commandline">línea de comandos</link>.
|
|
</para>
|
|
<note>
|
|
<simpara>
|
|
El nombre del script es pasado siempre como argumento del script, por lo tanto,
|
|
el valor mínimo de <varname>$argc</varname> es <literal>1</literal>.
|
|
</simpara>
|
|
</note>
|
|
<note>
|
|
<simpara>
|
|
Esta variable sólo está disponible cuando <link linkend="ini.register-argc-argv">register_argc_argv</link>
|
|
está activado.
|
|
</simpara>
|
|
</note>
|
|
</refsect1>
|
|
|
|
<refsect1 role="examples">
|
|
&reftitle.examples;
|
|
<para>
|
|
<example xml:id="variable.argc.basic">
|
|
<title>Ejemplo de <varname>$argc</varname></title>
|
|
<programlisting role="php">
|
|
<![CDATA[
|
|
<?php
|
|
var_dump($argc);
|
|
?>
|
|
]]>
|
|
</programlisting>
|
|
<simpara>
|
|
Cuando se ejecuta el ejemplo con: php script.php arg1 arg2 arg3
|
|
</simpara>
|
|
&example.outputs.similar;
|
|
<screen>
|
|
<![CDATA[
|
|
int(4)
|
|
]]>
|
|
</screen>
|
|
</example>
|
|
</para>
|
|
</refsect1>
|
|
|
|
</phpdoc:varentry>
|
|
|
|
<!-- 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:"~/.phpdoc/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
|
|
-->
|
|
|