Problems navigating a PHP multiForm

0

I have a problem with a form (divided into three forms) that I have done with a php session to get the data later. (I'm using Semantic UI (that's why I have it in 3 separate forms instead of one)).

I put a small example of what the code is with three forms in php.

<form name="form1" action="form2.php" method="POST"> //primer formulario
 <input   type="text" name="nombre" value="" />
 <input type="text" name="DNI" value="" />
 <input type="submit" class="nextbutton1 next1" name="btnform1" value="Siguiente >" >
</form>
------------Segundo formulario aparte----
<form action="form3.php" method="post">
 <input type="text" name="ciudad" value="" />
 <button class="nextbutton next2" value="">Siguiente > </button>
</form>
<button class="prevbutton prev1"  onClick="history.back();" value="">< Anterior </button> 
//este botón lo puse fuera del form ya que si no me lo toma como un submit y me lleva al siguiente, y de esta forma me lleva al formulario anterior.
--------------Tercer formulario aparte-----
<form action="formrecogedatos.php" method="POST">
<input type="text" id= value="" name="Cancion favorita" >
 <input type="submit" class="nextbutton2" id="uploadfiles" value="ENVIAR" href="#" required>        
</form>
 <button class="prevbutton prev2" onClick="history.go(-1);" id="btn-form2" value="">< Anterior </button>
//lo mismo que con el segundo formulario, para poder regresar al anterior formulario.

that is a small example of what my form is, and the problem I have, is that the buttons to navigate the 3 forms.

    
asked by Maci Uzumaki 09.07.2018 в 15:11
source

0 answers