![]()
![]()
posta la form
Questo e il codice HTML del Form...codice:<td> Voglio segnalarvi:</p> Riguardo a cosa ci stai scrivendo? * <label> <select name="oggetto" id="oggetto"> <option value="1">Problemi ad entrare?</option> <option value="2">Ho dimenticato la password</option> <option value="3">Hablux Crediti</option> <option value="4">Perchè sono stato bannato?</option> <option value="5">Sono un genitore</option> <option value="6">Ho un'idea</option> <option value="7">Altro</option> </select> </label> </p> Come si chiama il tuo Hablux? * <input type="text" name="nomehablux" id="nomehablux"> </p> Qual'è l'indirizzo email con quale ti sei iscritto? * <label> <input type="text" name="email" id="email"> </label> </p> Scrivi il tuo Messaggio: * <textarea name="testo" id="testo" cols="45" rows="5"></textarea> </p></td> </tr> </table></td>
Scusatemi, mi sono dimenticato di aggiungere alcune cose:
Il resto intendi anche gli altri script check? il punto e che ancora non ho stillato altro, adesso mi dedico un pò a vedere se riesco a fare i 3 check...codice:<tr> <td><form action="checkform.php" method="post"> Voglio segnalarvi:</p> Riguardo a cosa ci stai scrivendo? * <label> <select name="oggetto" id="oggetto"> <option value="1">Problemi ad entrare?</option> <option value="2">Ho dimenticato la password</option> <option value="3">Hablux Crediti</option> <option value="4">Perchè sono stato bannato?</option> <option value="5">Sono un genitore</option> <option value="6">Ho un'idea</option> <option value="7">Altro</option> </select> </label> </p> Come si chiama il tuo Hablux? * <input type="text" name="nomehablux" id="nomehablux"> </p> Qual'è l'indirizzo email con quale ti sei iscritto? * <input type="text" name="email" id="email"> </p> Scrivi il tuo Messaggio: * <textarea name="testo" id="testo" cols="45" rows="5"></textarea> </p> <label> <input type="submit" name="send" id="send" value="Invia"> </label> </p> </form></td> </tr> </table></td>
Però mi viene dato questo errore:codice:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Check...</title> </head> <? if (empty($_POST['nomehablux'])){ header("Location: aiuto/contattaci/ops"); } else { header("Location: checkuser.php"); ?> <body> </body> </html>
Parse error: syntax error, unexpected $end in C:\inetpub\wwwroot\checkform.php on line 13
in checkform.php recuperi i dati del form con $_POST e il nome dell'elemnto html
per esempio $_POST['oggetto'] avrà vaolre 1 o 2 o 3 etc etc a seconda di cosa l'utente ha selezionato
ti consiglio di non usare il tag breve per aprire php
ovvero non usare <? ma usa il tag esteso <?php
cmq è un errore di sintassi, manca la chiusura della parentesi graffa dell'else
Codice PHP:
<?php
if (empty($_POST['nomehablux'])){
header("Location: maintenance.php");
} else {
header("Location: checkuser.php");
}
?>
Pensandoci bene però, io devo recuperare tutti i dati del Form in Checkform.php per poi trasmetterli a checkuser.php , come faccio?![]()
Warning: Cannot modify header information - headers already sent by (output started at C:\inetpub\wwwroot\checkform.php:7) in C:\inetpub\wwwroot\checkform.php on line 10
Adesso Checkform mi da il solito errore di Header already sent...
In effetti ha ragione, ma come risolvo?