複製程式碼 程式碼如下:
$key = array();
$val = array();
foreach ($_POST as $k=>$v)
{
$key[] = '`'.strip_tags(mysql_real_escape_string(trim($k))).'`';
$val[] = "'".strip_tags(mysql_real_escape_string(trim($v)))."'";
}
$keys = join(",",$key);
$vals = join(" ,",$val);
以上就介紹了how to train your dragon php join函數應用,包括了how to train your dragon方面的內容,希望對PHP教程有興趣的朋友有所幫助。