buda benim kullandığım

$tr_chars = array ("ç","Ç","ğ","Ğ","ı","İ","ö","Ö","ş","Ş","ü","Ü");
$en_chars = array ("c","C","g","G","i","I","o","O","s","S","u","U");
$titlelink = strtolower(str_replace(" ","-",trim(preg_replace("'\s+'"," ",preg_replace("#[^a-zA-Z0-9 ]#"," ",str_replace($tr_chars,$en_chars,html_entity_decode($title)))))));