Copy and Paste  -   An Application to Copy/Paste Text  

 
S.No 4361 Name Checkout Date/Time 23-Mar-2020 03:15:04 PM

Copy text from below
<?php

//$conn = mysqli_connect("localhost","root","","ecommerce");
session_start();


if(!isset($_SESSION['loggedin']))
{
echo "<script language=\"javascript\"type=\"text/javascript\">window.location.href=\"login.php\";</script>";
exit(0);
}
$id =0.0;
if(isset($_COOKIE['vistor_id']))
{
$id=$_COOKIE['vistor_id'];
}
include("db/opendb.php");
include("db/functions.php");
$date=date('Y-m-d H:i:s');
//Code where error exists
$run_cart=mysqli_query($conn,"Select qty from cart vistor_id='$id'");
$qty=mysqli_fetch_array($run_cart);
echo $qty;
//End Of Code where error exists

$msg = NULL;
$dbobj = new Database();
$dbobj1 = new Database();


$query = "insert into order_t(order_des,order_date, fuser_name) values ('order placed at $date', '$date', '".$_SESSION['s_username']."')";

$msg = $dbobj -> UpdateRecord($query, "Inserted");
$orderid=$conn->lastInsertId();

$query="select Product_id from cart where vistor_id='".$id."'";

$dbobj -> FetchRecord($query);




while($row = $dbobj->pstmt->fetch())
{


$query = "insert into order_detail(forder_id,fproduct_id,qty) values ('$orderid', '$row[0]','$qty')";


$msg = $dbobj1 -> UpdateRecord($query, "Inserted");




}


$dbobj -> CloseDBCon();
//echo "<script language=\"javascript\" type=\"text/javascript\">window.location.href=\"CheckoutComplete.php\";</script>";
//exit(0);

return;





?>




comments powered by Disqus
NEW ENTRIES
S.No Name Entry Time/Date
4460 drop 21-Jan-2021 04:01:50 PM
4459 asda 21-Jan-2021 03:54:27 PM
4458 asda 21-Jan-2021 03:54:05 PM
4457 zeb.xml 20-Jan-2021 10:33:38 PM
4456 zeb 20-Jan-2021 10:32:54 PM
4455 WEBvIEW 20-Jan-2021 05:34:52 PM
4454 osm_phone 19-Jan-2021 05:47:37 PM
4453 ii 18-Jan-2021 02:03:04 PM
4452 Ikram audio 18-Jan-2021 01:17:34 PM
4451 AWS 17-Jan-2021 04:22:27 PM
4450 row.xml 15-Jan-2021 03:40:59 PM
4449 parm table 12-Jan-2021 04:05:42 PM
4448 andriod 08-Jan-2021 03:29:57 PM
4447 AMK2 08-Jan-2021 03:05:46 PM
4446 AMK 1 08-Jan-2021 03:05:25 PM
4445 link 07-Jan-2021 11:35:05 PM
4444 test 05-Jan-2021 10:24:22 AM
4443 file up flas 05-Jan-2021 10:23:49 AM
4442 NRG Benjyfis 04-Jan-2021 04:04:39 AM
4441 Os 01-Jan-2021 10:04:46 PM
4440 post 01-Jan-2021 12:16:39 PM
4439 afaq 01-Jan-2021 11:27:02 AM
4438 python_flask 28-Dec-2020 02:05:29 AM
4437 link 24-Dec-2020 03:27:25 PM
4436 internet 16-Dec-2020 06:08:27 PM
4435 http 16-Dec-2020 06:05:59 PM
4434 uuu 14-Dec-2020 10:36:15 AM
4433 dd 12-Dec-2020 11:00:00 PM
4432 23 12-Dec-2020 10:54:41 PM
4431 94 12-Dec-2020 10:40:18 PM

1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 [Next] [Last]
 
web counter
web counter


To report any error messages or bugs, or other issues, please send email at: info@pakproject.com