下面的函數check_porn_terms
檢查一個變量是否包含不適合家庭使用的條件,如果它包含,則將用戶重定向回主頁面。一次可以在一個函數中使用兩個變量嗎?
如下所列,它檢查變量$title
是否有不適合家庭使用的術語。我想對另一個變量$cleanurl
執行此檢查。我可以用check_porn_terms($title, $cleanurl)
或其他類似的東西替換下面的check_porn_terms($title)
嗎?如果不是,我該怎麼做?
由於提前,
約翰
if(!check_porn_terms($title))
{
session_write_close();
header("Location:http://www.domain.com/index.php");
exit;
}
爲什麼不使用數組? – Cristian 2010-06-30 19:02:29