Jump to content

faure

Members
  • Content count

    5
  • Joined

  • Last visited

Community Reputation

0 Neutral

About faure

  • Rank
    Newbie
  1. i cannot post a table in a form (only last td)

    problem resolved good luck to w3school : it is a very good product por a beginner
  2. i cannot post a table in a form (only last td)

    <?php // /////////////////////// // second file bz92.php // ////////////////////// session_start(); ?> <!DOCTYPE HTML> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>bz92</title> <style> </style> </head> <body> </body> <?php echo "POST "; echo"<br>"; print_r($_POST); echo"<br>"; if(isset($_POST['valider'])) { echo "<br>"; // boucle $tableau = array(); // init $n=0; foreach($_POST as $index=>$valeur) { $n= $n+1; echo "valeur ".$valeur." // "; echo "<br>"; } } echo "<br>"; echo "nombre ".$n; // header('Location: bz5.php'); exit(); ?> </html>
  3. i cannot post a table in a form (only last td)

    like original message here 2 files php post is not working well, only last tr thank you for your help <?php // ////////////////////////////// // first file bz91.php // ///////////////////////////// session_start(); ?> <!DOCTYPE HTML> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css"> <title>bz91</title> <style> .zone1{ width : 800px; height : 400px; margin: 0 auto; } </style> </head> <body> <div class="zone1"> <center> <div class="w3-display-container w3-lime w3-section w3-round-xlarge" style="height:400px;" style="width:50%" ;> <form action="bz92.php" id="ID1" method="POST" accept-charset="utf-8"> <div class="w3-display-position w3-white" style="top:20px;" > <table id="t01" name="t01" BGCOLOR="#98FB98" align= center > <?php $_SESSION[ 'lib'."1"]="Npm"; $_SESSION[ 'lib'."2"]="Prénom"; $_SESSION[ 'lib'."3"]="Début"; $_SESSION[ 'lib'."4"]="Fin"; $_SESSION[ "1"]="A"; $_SESSION[ "2"]="B"; $_SESSION[ "3"]="C"; $_SESSION[ "4"]="D"; // //////////////////// // loop // /////////////////// for ($i = 1; $i <= 4; $i++) { ?> <tr height=30> <td> <input type= "label" name = 'one'.$i value= <?php echo $_SESSION[ "lib".$i] ?> > </td> <td> <input type= "text" name = 'two'.$i value= <?php echo $_SESSION[ $i] ?> > </td> <?php } ?> </table> </div> <div class="w3-display-position w3-white" style="top:330px;left:20px"> <input type="submit" name = "valider" value="OK"> </div> </form> </div> </center> </div> <p> Click on OK for validation</p> </body> </html>
  4. i cannot post a table in a form (only last td)

    It is my first post ! excuse me http://faureinfo.dyndns.biz/bz91.php to see bz91.php and bz92.php in action thanks you (merci in french)
×