Revision 20119,
410 bytes
checked in by nanasess, 13 years ago
(diff) |
module 以下は svn:keywords を除外
|
-
Property svn:eol-style set to
LF
|
Line | |
---|
1 | --TEST-- |
---|
2 | Function -- array_combine |
---|
3 | --SKIPIF-- |
---|
4 | <?php if (function_exists('array_combine')) { echo 'skip'; } ?> |
---|
5 | --FILE-- |
---|
6 | <?php |
---|
7 | require_once 'PHP/Compat.php'; |
---|
8 | PHP_Compat::loadFunction('array_combine'); |
---|
9 | |
---|
10 | $a = array('green', 'red', 'yellow'); |
---|
11 | $b = array('avocado', 'apple', 'banana'); |
---|
12 | $c = array_combine($a, $b); |
---|
13 | |
---|
14 | print_r($c); |
---|
15 | ?> |
---|
16 | --EXPECT-- |
---|
17 | Array |
---|
18 | ( |
---|
19 | [green] => avocado |
---|
20 | [red] => apple |
---|
21 | [yellow] => banana |
---|
22 | ) |
---|
Note: See
TracBrowser
for help on using the repository browser.