I think that works. There is a function iconv() that would replace all accented characters in one line and catch any other characters you might have missed that might be a little cleaner.
<?php
// funzione pulizia stringa
function CleanString($string)
{
$strResult = iconv('UTF-8', 'ASCII//TRANSLIT', $string);
$strResult = str_ireplace("'", " ", $strResult);
$strResult = str_ireplace("_", " ", $strResult);
$strResult = preg_replace('/[^A-Za-z0-9 ]/', "", $strResult);
$strResult = trim($strResult);
$strResult = preg_replace('/[ ]{2,}/', " ", $strResult);
$strResult = str_replace(" ", "-", $strResult);
return $strResult;
}
?>