0
$stmtt=$dbh->prepare("INSERT INTO `dbname` (`Shop_ID`,`Shop_name`,`Shop_owner_name`,`Shop_phone1`,`Shop_phone2`,`Shop_category`,`Shop_address`,`Shop_pincode`,`Shop_state`,`Shop_add_by_user_id`) VALUES (:shopid,:shopname,:shopownername,:shopphone1,:shopphone2,:shopcategory,:shopaddress,:shoppincode,:shopstate,:shopaddbyuserid)");

$stmtt->execute(array(':shopid' => $shop_id_n, ':shopname' => $shop_name, ':shopownername' => $shop_owner_name, ':shopphone1' => $shop_phone1, ':shopphone2' => $shop_phone2, ':shopcategory' => $shop_category, ':shopaddress' => $shop_address, ':shoppincode' => $shop_pincode, ':shopstate' => $shop_state, ':shopaddbyuserid' => $shop_add_by_user_id));
trigger_error("PDO errorInfo: ".$dbh->errorInfo());
if(($stmtt->rowCount())>0)
{
    return "true";
}
else
{
    return "false";
}

after executing above code i am getting error like:

Notice: Array to string conversion in /home/tnuwgfoah4wc/public_html/dbconn/functions.php on line 109

Notice: PDO errorInfo: Array in /home/tnuwgfoah4wc/public_html/dbconn/functions.php on line 109

i have tried every possible method but unable to find the error.... can anyone please help me out?

0 Answers0