Deux action dans un <from>

Petit nouveau ! | 5 Messages

14 nov. 2010, 23:08

Bonjour,
J'essaye de créer un formulaire qui comporte plusieurs informations écrit manuellement et une zone ou l'on peut effectuer une signature avec la souris. Une fois que l'on valide, j'aimerais que la signature s'enregistre en JPEG et ensuite exécute le PDF.

Independament, j'arrive a gérer le PDF ou a enregistre la signature mais je n'arrive pas a faire les deux d'un coup.

Voici le code pour la generation du PDF :

Code : Tout sélectionner

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html> <head> <title>Attestation de Remise</title> <link rel="stylesheet" type="text/css" href="style.css" /> </head> <body> <div id="main2"> <div class="logo">. <h1>Attestation de Remise de PC Portable</h1><br /><br /><br /> <div class="center"> <form method="post" action="pdf.php"> Nom : <input type="text" name="nom" size="12"><br> Prénom : <input type="text" name="prenom" size="12"><br> Service : <select name="service"> <option>Achat</option> <option>Informatique</option> <option>DHR</option> <option>Controle de Gestion</option> <option>Comptabilité</option> <option>Regie</option> <option>Création</option> </select> Signature : <br> <input type=submit value="Ok"> </form> </div> </div> </div> </body> </html>
Voici le code qui permet d’enregistrer la page :

Code : Tout sélectionner

<html> <head> <title>Attestation de Remise</title> <link rel="stylesheet" type="text/css" href="style.css" /> </head> <body> <div id="main2"> <div class="logo">. <h1>Attestation de Remise de PC Portable</h1><br /><br /><br /> <div class="center"> Nom : <input type="text" name="nom" size="12"><br> Prénom : <input type="text" name="prenom" size="12"><br> Service : <select name="service"> <option>Achat</option> <option>Informatique</option> <option>DHR</option> <option>Controle de Gestion</option> <option>Comptabilité</option> <option>Regie</option> <option>Création</option> </select> Signature : <br> <applet CODE="SignPad" NAME="signPad" ARCHIVE="signpad.jar" WIDTH="400" HEIGHT="250"> <param name="BACKGROUND" value="blue"> <param name="FOREGROUND" value="white"> </applet> <form action="http://192.168.1.202:8080/SignServlet/servlet/WriteSign" method="POST" onSubmit='sign.value=signPad.getSign();'> <select name="saveas"> <option value="jpeg" selected>JPEG</option> </select> <input type=button value="Clear" onclick="signPad.clear();"> <input type=submit value="Ok"> <input type=hidden name="sign" value=""> </form> </div> </div> </body> </html>
J’espère être assez claire...

Cordialement
Romain