You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
382 B

  1. --TEST--
  2. Testing $argc and $argv handling (GET)
  3. --SKIPIF--
  4. <?php if (php_sapi_name()=='cli') echo 'skip'; ?>
  5. --INI--
  6. register_argc_argv=1
  7. --GET--
  8. ab+cd+ef+123+test
  9. --FILE--
  10. <?php
  11. if (!ini_get('register_globals')) {
  12. $argc = $_SERVER['argc'];
  13. $argv = $_SERVER['argv'];
  14. }
  15. for ($i=0; $i<$argc; $i++) {
  16. echo "$i: ".$argv[$i]."\n";
  17. }
  18. ?>
  19. --EXPECT--
  20. 0: ab
  21. 1: cd
  22. 2: ef
  23. 3: 123
  24. 4: test