I have wamp with php nd mysql installed. My php file is in PC wamp/www/Demo folder in which I written query for inserting values getting by url.
Now I want to send multiple rows of data collected from android application to MySQL Wamp server through PHP file.
My php file code is as below,
<?php
$dbhost = "localhost";
$dbuser = "root";
$dbpass = "";
$dbname="billapp";
$order_no= $_GET['no'];
$item_name= $_GET['in'];
$item_value= $_GET['iv'];
$conn = mysqli_connect($dbhost, $dbuser, $dbpass,$dbname);
if(! $conn )
{
}
$sql1 = "INSERT INTO order_details (`order_no`,`item_name`,`item_value`) VALUES ('$order_no','$item_name','$item_value')";
$retval = mysqli_query( $conn,$sql1 );
if(! $retval )
{
}
echo "entered success";
mysqli_close($conn);
?>
and calling url is
"http://localhost/Demo/insertbill.php?no=10&in="item1"&iv="price1""
What I have tried:
Tried below url for single row insertion
"http://localhost/Demo/insertbill.php?no=10&in="item1"&iv="price1""
It is not possible to pass all row values like this way
what to do? please suggest.