source: branches/version-2_5-dev/data/module/Compat/tests/function/array_intersect_key.phpt @ 20116

Revision 20116, 472 bytes checked in by nanasess, 13 years ago (diff)
  • svn properties を再設定
  • 再設定用のスクリプト追加
  • Property svn:eol-style set to LF
  • Property svn:keywords set to Id
Line 
1--TEST--
2Function -- array_intersect_key
3--SKIPIF--
4<?php if (function_exists('array_intersect_key')) { echo 'skip'; } ?>
5--FILE--
6<?php
7require_once 'PHP/Compat.php';
8PHP_Compat::loadFunction('array_intersect_key');
9
10$array1 = array('blue'  => 1, 'red'  => 2, 'green'  => 3, 'purple' => 4);
11$array2 = array('green' => 5, 'blue' => 6, 'yellow' => 7, 'cyan'   => 8);
12
13print_r(array_intersect_key($array1, $array2));
14
15?>
16--EXPECT--
17Array
18(
19    [blue] => 1
20    [green] => 3
21)
Note: See TracBrowser for help on using the repository browser.