
enviar datos
Publicado por carlos (1 intervención) el 27/07/2017 23:47:04
hola chicos, ando liadisimo intentando conseguir el envio de varios datos, ya consegui pasar datos de un formulario a otro por medio de php, bien, ahora quiero que al darle a enviar, vaya a todas las direcciones obtenidas,
bien, ya visto el codigo seria hacer una funcion o un bucle, no se, donde mandar los datos input, la variable $coord, ontiene las coordenadas que se introducen en ellas, el tema es que al hacer click, me las envie todas de una vez, no se si me explique XD
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" <html>
<?php
$lancero=$_POST ["lancero"];
$espadachin=$_POST["espadachin"];
$hacha=$_POST["hacha"];
$arquero=$_POST["arquero"];
$espia=$_POST["espia"];
$lija=$_POST["lija"];
$arcab=$_POST["arcab"];
$pesada=$_POST["pesada"];
$ariete=$_POST["ariete"];
$catapulta=$_POST["catapulta"];
$paladin=$_POST["paladin"];
$noble=$_POST["noble"];
$coord=$_POST["coord"];
?>
<head>
<link href="css/1.css" rel="stylesheet" type="text/css" />
<link href="css/2.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">
</script>
</head>
<body>
<table class="SCscreen" border="0" cellspacing="0" cellpadding="0">
<tr>
<td align="center">
<div class="SCscreen">
<h2 style="text-align: center;">Tropas</h2>
<div class="float">
Cantidad de ataques: <input type="text" id="ONE_incomings_per_target" value="1" size="4" name="objetivo">
<br />
<hr />
Primera LLgada<input type="text" id="ONE_first_arival" value="dd mm yyyy hh:mm" class="ONEtime" name="fecha" />
</div>
<div class="float">
Lnaza <input name="lancero" type="text" class="ONE_units" id="ONE_units_" value="<?php echo $lancero?> " size="5" /><br>
Espada
<input type="text" id="ONE_units_2" class="ONE_units" value="<?php echo $espadachin?> " name="espada" size="5"><br>
Hachas
<input type="text" id="ONE_units_2" class="ONE_units" value="<?php echo $hacha?> " name="hachas" size="5"><br>
Arcos <input type="text" id="ONE_units_3" class="ONE_units" value="<?php echo $arquero?> " name="arcos" size="5"/><br>
Espia
<input type="text" id="ONE_units_4" class="ONE_units" value="<?php echo $espia?> " name="espias" size="5"/><br>
Lijeras <input type="text" id="ONE_units_2" class="ONE_units" value="<?php echo $lija?> " name="lijeras" size="5"><br>
A. Cab
<input type="text" id="ONE_units_2" class="ONE_units" value="<?php echo $arcab?> " name="arquero a caballo" size="5" ><br>
Ariete <input type="text" id="ONE_units_2" class="ONE_units" value="<?php echo $ariete?> " name="ariete" size="5"><br>
Cata <input type="text" id="ONE_units_2" class="ONE_units" value="<?php echo $catapulta?> " name="catapulta" size="5" ><br>
Paladin <input type="text" id="ONE_units_2" class="ONE_units" value="<?php echo $paladin?> " name="paladin" size="5" ><br>
Noble <input type="text" id="ONE_units_2" class="ONE_units" value="<?php echo $noble?> " name="noble" size="5"><br>
</div>
<div class="float"> objetivos elegidos<br>
<input id="ONE_targets" value="<?php echo $coord?>" style="resize:vertical;min-height:150px;width:275px;"> (ejemplo) 123|456</textarea><br><br>
<input type="button" onclick="location.href='mi_programa.php';" class="boton" id="ONEsubmit" value="enviar" size="20" />
</div>
</td>
</tr>
</table>
</body>
bien, ya visto el codigo seria hacer una funcion o un bucle, no se, donde mandar los datos input, la variable $coord, ontiene las coordenadas que se introducen en ellas, el tema es que al hacer click, me las envie todas de una vez, no se si me explique XD
Valora esta pregunta


0