1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
$str
=
"你好<我>(爱)[北京]{天安门}"
;
echo
f1(
);
//返回你好
f2(
//返回我
f3(
//返回爱
f4(
//返回北京
f5(
//返回天安门
function
)
{
$result
=
array
();
preg_match_all(
"/^(.*)(?:<)/i"
,
);
return
[1][0];
}
)
{
();
"/(?:<)(.*)(?:>)/i"
);
[1][0];
}
)
{
();
"/(?:\()(.*)(?:\))/i"
);
[1][0];
}
)
{
();
"/(?:\[)(.*)(?:\])/i"
);
[1][0];
}
)
{
();
"/(?:\{)(.*)(?:\})/i"
);
[1][0];
}
|