SHOW:
|
|
- or go back to the newest paste.
1 | function get($param) { | |
2 | - | |
2 | + | $big_array = array(); |
3 | foreach ($param as $k => $v) { | |
4 | ||
5 | preg_match_all($v, $GLOBALS['post'], $out); | |
6 | $out = (isset($out[1][0]) && $out[1][0] != null) ? $out[1][0] : null; | |
7 | ||
8 | $array = array( | |
9 | $k => $out | |
10 | ); | |
11 | ||
12 | - | $out .= $array; |
12 | + | $big_array = array_merge($big_array, $array); |
13 | ||
14 | ||
15 | } | |
16 | - | echo $out; |
16 | + | |
17 | echo json_encode($big_array); | |
18 | } |