Here is the code am trying to use in the submission of my data through mjforms (Button Script)
Could anyone help me out???
<?php
if(isset($_POST['add']))
{
$dbhost = 'localhost:3036';
$dbuser = 'root';
$dbpass = '';
$conn = mysql_connect($dbhost, $dbuser, $dbpass);
if(! $conn )
{
die('Could not connect: ' . mysql_error());
}
if(! get_magic_quotes_gpc() )
{
$Number = addslashes ($_POST['data_number']);
$plain = addslashes ($_POST['data_plain']);
$defe = addslashes ($_POST['data_defe']);
$Date = addslashes ($_POST['data_datefilled']);
$entryDate = addslashes ($_POST['data_logtime']);
}
else
{
$Number = $_POST['data_number'];
$entryDate = $_POST['logtime'];
$plain = $_POST['plain'];
$defe = $_POST['defendant'];
$Date = $_POST['datefilled'];
}
$sql = "INSERT INTO info_table ".
"(data_number, data_plain, data_defe, data_datefilled, data_logtime) ".
"VALUES('$Number,',$plain,',$defe','$Date', '$entryDate')";
mysql_select_db('odues');
$retval = mysql_query( $sql, $conn );
if(! $retval )
{
die('Could not enter data: ' . mysql_error());
}
echo "Entered data successfully\n";
mysql_close($conn);
}
else
{
?>
how to submit data in Mjform into a different table using
Re: how to submit data in Mjform into a different table usin
You can use javascript change action url to another url
Put you javascript into onClick Script
I think it work but not sure.
Put you javascript into onClick Script
I think it work but not sure.