You probably want to do something different:
pg_prepare: don't put specific values, but placeholders. You will bind them to values later on. I prefer to always give statements a name.
If dungeonasdb.crea_personaggio is the function that returns void, you can call it by means of:
SELECT dungeonasdb.crea_personaggio(...)
You cannot call your function by means of SELECT * FROM dungeonasdb.crea_personaggio(...) because this would imply that dungeonasdb.crea_personaggio is a set returning function, which is not.
So you probably want your statements to be:
$result = pg_prepare($dbconn, "crea_personnagio",
'SELECT dungeonasdb.crea_personaggio($1, $2, $3, $4)');
$result = pg_execute($dbconn, "crea_personnagio",
ARRAY($nome, $descrizione, $email, $password))
or die('Query execuzione fallita');
Your second statment is a pg_execute statement that binds parameters to the placedholders ($1, ...), and executes.
dungeonasdb.crea_personaggiois your table name ?