aspetta non ho capito bene:
Dove lo metto e come ?
ti passo il form:
-----------
<?php
include('include.php');
$Da = $_POST["Da"];
$Oggetto = $_POST["Oggetto"];
$Descrizione = $_POST["Descrizione"];
$Note= $_POST["Note"];
$Annulalto = $_POST["Annullato"];
$RegistratoDa = $_POST["RegistratoDa"];
$conn = mssql_connect( $host, $user, $password );
mssql_select_db( $database );
//INSERISCO I DATI NEL DB
$query = "INSERT INTO Entrata (Da, Oggetto, Descrizione, Note, Annullato, RegistratoDa)
VALUES ('$Da', '$Oggetto', '$Descrizione', '$Note', '$Annullato', '$RegistratoDa')";
$result = mssql_query( $query );
if (!isset($_POST['Registra'])) { // if page is not submitted to itself echo the form
?>
<html>
<head>
<title>Personal INFO</title>
</head>
<body>
<form method="post" action="<?php echo $PHP_SELF;?>">
Da:<input type="text" size="12" maxlength="12" name="Da">
Oggetto:<input type="text" size="12" maxlength="36" name="Oggetto">
Descrizione:<input type="text" size="12" maxlength="36" name="Descrizione">
Note:<input type="text" size="12" maxlength="36" name="Note">
Annullato:
<select name="Annullato">
<option>------
<option value="Si">Si</option>
<option value="No">No</option>
</select>
Registrato Da:<input type="text" size="12" maxlength="36" name="RegistratoDa">
<input type="submit" value="submit" name="Registra">
</form>
<?
} else {
echo "Da= ".$Da."
";
echo "Oggetto= ".$Oggetto."
";
echo "Descrizione= ".$Descrizione."
";
echo "Note= ".$Note."
";
echo "Annulato= ".$Annullato."
";
echo "Registrato Da= ".$RegistratoDa."";
}
?>