Scusate, ho cercato di adattare il codice come da risposta di Andrea
<code>
<?php
function lire($euro)
{
return ($euro*1936.27);
}
?>
<form name="form_function" method="post" action="">
Immetti valore €:
<input type="text" name="valore_€">
</p>
<input type="submit" name="Submit_function" value="Invia">
</p>
</form>
<?php
if (isset(!$_POST['valore_€']) || !is_numeric($_POST['valore_€']))
{
$altrimenti="immetti un valore numerico";
print($altrimenti);
}
else
{
$euro = htmlspecialchars($_POST['valore_€']);
$valore=lire($euro);
echo("varole equivalente in Lit: $valore");
}
?>
</code>
ma ottengo il seguente errore:
Parse error: syntax error, unexpected '!', expecting T_STRING or T_VARIABLE or '$' in C:\Programmi\Apache Software Foundation\Apache2.2\htdocs\function+return.php on line 16
Grazie di nuovo.
Amos