From 1a0124d88b33b5e25195cde0e92d5d367920a1cc Mon Sep 17 00:00:00 2001 From: Jon Parise Date: Mon, 30 Sep 2002 11:53:23 +0000 Subject: [PATCH] Adding initial documentation for the new getopt() function. git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@97526 c90b9560-bf6c-de11-be94-00142212c4b1 --- reference/info/functions/getopt.xml | 67 +++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 reference/info/functions/getopt.xml diff --git a/reference/info/functions/getopt.xml b/reference/info/functions/getopt.xml new file mode 100644 index 0000000000..1542d4172c --- /dev/null +++ b/reference/info/functions/getopt.xml @@ -0,0 +1,67 @@ + + + + + getopt + Gets options from the command line argument list + + + Description + + stringgetopt + stringoptions + + + Returns an associative array of option / argument pairs based on the + options format specified in options, or &false; + on an error. + + + + + + + + The options parameter may contain the following + elements: individual characters, and characters followed by a colon to + indicate an option argument is to follow. For example, an option string + x recognizes an option -x, and an + option string x: recognizes an option and argument + -x argument. It does not matter if an argument has + leading white space. + + + This function will return an array of option / argument pairs. If an + option does not have an argument, the value will be set to &null;. + + + This function requires that the + register_argc_argv configuration option be enabled. + + + + + + +