如何通过使用extract($ _ REQUEST)
来修剪多个参数值process.php?ticketid=101 & TrID=902121
extract($_REQUEST);
echo $ticketid;// result " 101 "
echo $TrID;//result " 902121 "
答案 0 :(得分:0)
首先从您的网址中删除空格,如下所示:
process.php?ticketid=101&TrID=902121
extract($_REQUEST);
// looping through all elements of $_REQUEST
foreach($_REQUEST as $key=>$val){
$arr[$key] = trim($val);
}
print_r(arr);