Grazie per le dritte, adesso ho sistemato la funzione che chiamo prima di salvare su database per elaborare il nome ed il commento inserito dall'utente così:
codice:
 
function elaboraHTMLComm($text,$nome,$ajax){
    /*Elimina i tag HTML*/
    $text=strip_tags($text);
    $nome=strip_tags($nome);
    /*Elimina gli slash*/
    $text=stripslashes($text);
    $nome=stripslashes($nome);
    /*Sostituisce le lettere accentate*/
    if($ajax){
	$text=htmlentities(utf8_decode($text));
	$nome=htmlentities(utf8_decode($nome));
	}
    else{
	$text=htmlentities($text);
	$nome=htmlentities($nome);
	}
    $text=nl2br($text);
    /*Prepara la stringa per l'inserimento*/
    $text=mysql_escape_string($text);
    $nome=mysql_escape_string($nome);
    return array($text,$nome);
  }
Mi pare Ok...