";
?>
Misol.
$host = "127.0.0.1:3306 ";
$username = "root";
$userpass = "";
$dbname = "oila";
$db = mysqli_connect($host,$username,$userpass,$dbname);
if(isset($_POST['add']))
{
$name = $_POST['name'];
$comp = $_POST['comp'];
$color = $_POST['color'];
$year = $_POST['year'];
$price = $_POST['price'];
$adding = mysqli_query($db, "INSERT INTO oila (kim, ism, familiya, yoshi, tel) VALUES ('$name', '$comp', '$color', '$year', '$price')");
}
?>
Document
Do'stlaringiz bilan baham: |