function kucult($text){ 
$search = array ('@Ğ@', 
'@Ü@', 
'@Ş@', 
'@I@', 
'@İ@', 
'@Ö@', 
'@Ç@'); 

$replace = array ('ğ', 
'ü',  
'ş',  
'ı',  
'i', 
'ö', 
'ç');  
$text = preg_replace($search, $replace, $text);  
$text = strtolower($text); 
return($text); 
} 

function seo_cevir($str) 
{ 
    $str = kucult($str); 

    $turkce[0] = '/ö/'; 
    $turkce[1] = '/ç/'; 
    $turkce[2] = '/ş/'; 
    $turkce[3] = '/ğ/'; 
    $turkce[4] = '/ü/'; 
    $turkce[5] = '/ı/'; 
    $turkce[6] = '/é/'; 
    $turkce[7] = '/à/'; 
    $turkce[8] = '/ã/'; 
    $turkce[9] = '/â/'; 
    $turkce[10] = '/ù/'; 
    $turkce[11] = '/û/'; 
    $turkce[12] = '/ì/'; 
    $turkce[13] = '/î/'; 
    $turkce[14] = '/ò/'; 
    $turkce[15] = '/õ/'; 
    $turkce[16] = '/ô/'; 
    $turkce[17] = '/ß/'; 
    $turkce[18] = '/è/'; 
    $turkce[19] = '/ê/'; 
     
    $turkceCevir[0] = 'o'; 
    $turkceCevir[1] = 'c'; 
    $turkceCevir[2] = 's'; 
    $turkceCevir[3] = 'g'; 
    $turkceCevir[4] = 'u'; 
    $turkceCevir[5] = 'i'; 
    $turkceCevir[6] = 'e'; 
    $turkceCevir[7] = 'a'; 
    $turkceCevir[8] = 'a'; 
    $turkceCevir[9] = 'a'; 
    $turkceCevir[10] = 'u'; 
    $turkceCevir[11] = 'u'; 
    $turkceCevir[12] = 'i'; 
    $turkceCevir[13] = 'i'; 
    $turkceCevir[14] = 'o'; 
    $turkceCevir[15] = 'o'; 
    $turkceCevir[16] = 'o'; 
    $turkceCevir[17] = 's'; 
    $turkceCevir[18] = 'e'; 
    $turkceCevir[19] = 'e'; 
     
    $str = preg_replace ( $turkce, $turkceCevir, $str ); 
    $str = preg_replace('/[^a-z0-9 *]/i', '', $str); 
    $str = str_replace(' ', '-', $str); 
    return $str; 
} 

// Kullanımı 
echo(seo_cevir("Deneme ÖÇŞİĞÜ öçşığü àãâé ÀÃÂ èê"));