Parašė Narysx· 2009 Sau. 20 19:01:15
#1
Kuriu čia šiokią tokią užpildymo formą...:
<?php
/*---------------------------------------------------+
|Sukure chipass
|chipass@gmail.com
|www.e-studija.lt Internetinių svetainių kūrimas
+----------------------------------------------------*/
require_once "../../maincore.php";
require_once "../../subheader.php";
require_once "../../side_left.php";
if(isset($status) && $status != '') {
if($status == 'pateikta') { /*kazkas jeigu pridejo*/ }
elseif($status == 'atmesta') { /*Kazkas jei nepridejo*/}
}
if (isset($_POST['submit'])) {
$ip = $_SERVER['REMOTE_ADDR'];
$result = dbquery("INSERT INTO fusion_pavadinimas (ho_team, ho_score, aw_team, aw_score, ho_goal1_name, ho_goal1, ho_goal2_name, ho_goal2, ho_goal3_name, ho_goal3, ho_goal4_name, ho_goal4, ho_goal5_name, ho_goal5, aw_goal1_name, aw_goal1, aw_goal2_name, aw_goal2, aw_goal3_name, aw_goal3, aw_goal4_name, aw_goal4, aw_goal5_name, aw_goal5) VALUES ('".$_POST['ho_team']."', '".$_POST['ho_score']."', '".$_POST['aw_team']."', '".$_POST['aw_score']."', '".$ip."', '".$_POST['ho_goal1_name']."', '".$_POST['ho_goal1']."', '".$_POST['ho_goal2_name']."', '".$_POST['ho_goal2']."', '".$_POST['ho_goal3_name']."', '".$_POST['ho_goal3']."', '".$_POST['ho_goal4_name']."', '".$_POST['ho_goal4']."', '".$_POST['ho_goal5_name']."', '".$_POST['ho_goal5']."', '".$_POST['aw_goal1_name']."', '".$_POST['aw_goal1']."', '".$_POST['aw_goal2_name']."', '".$_POST['aw_goal2']."', '".$_POST['aw_goal3_name']."', '".$_POST['aw_goal3']."', '".$_POST['aw_goal4_name']."', '".$_POST['aw_goal4']."', '".$_POST['aw_goal5_name']."', '".$_POST['aw_goal5']."')");
if($result) { redirect(FUSION_SELF."?status=pateikta"); }
else { redirect(FUSION_SELF."?status=atmesta"); }
}
else {
opentable('sekmes');
echo " <form method='POST' action='".FUSION_SELF."'>
1 <input type='text' name='ho_team'><br><br>
2 <input type='text' name='ho_score'><br><br>
3 <input type='text' name='aw_team'><br><br>
4 <input type='text' name='aw_score'><br><br>
5 <input type='text' name='ho_goal1_name'><br><br>
6 <input type='text' name='ho_goal1'><br><br>
7 <input type='text' name='ho_goal2_name'><br><br>
8 <input type='text' name='ho_goal2'><br><br>
9 <input type='text' name='ho_goal3_name'><br><br>
10 <input type='text' name='ho_goal3'><br><br>
11 <input type='text' name='ho_goal4_name'><br><br>
12 <input type='text' name='ho_goal4'><br><br>
13 <input type='text' name='ho_goal5_name'><br><br>
14 <input type='text' name='ho_goal5'><br><br>
15 <input type='text' name='aw_goal1_name'><br><br>
16 <input type='text' name='aw_goal1'><br><br>
17 <input type='text' name='aw_goal2_name'><br><br>
18 <input type='text' name='aw_goal2'><br><br>
19 <input type='text' name='aw_goal3_name'><br><br>
20 <input type='text' name='aw_goal3'><br><br>
21 <input type='text' name='aw_goal4_name'><br><br>
22 <input type='text' name='aw_goal4'><br><br>
23 <input type='text' name='aw_goal5_name'><br><br>
24 <input type='text' name='aw_goal5'><br><br>
<br>
<input type='submit' name='submit' value='Patvirtinti'>
</form>";
closetable();
}
require_once "../../side_right.php";
require_once "../../footer.php";
?>
Kodėl užpildžius visus laukelius vistiek meta į atmesta ir nenusiunčia informacijos į duom. bazę? Viskas atrodo gerai padaryta...
Redagavo Narysx· 2009 Sau. 20 19:01:30