From ecb628cad8a553207c643cbf53377e16282412b4 Mon Sep 17 00:00:00 2001 From: johnnyq Date: Thu, 3 Mar 2022 23:28:16 -0500 Subject: [PATCH] Fix Add Software --- post.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/post.php b/post.php index e55912a8..8a204ab1 100644 --- a/post.php +++ b/post.php @@ -4780,7 +4780,7 @@ if(isset($_POST['add_software'])){ mysqli_query($mysqli,"INSERT INTO software SET software_name = '$name', software_version = '$version', software_type = '$type', software_key = '$key', software_license_type = '$license_type', software_seats = '$seats', software_purchase = '$purchase', software_expire = '$expire', software_notes = '$notes', software_created_at = NOW(), software_client_id = $client_id, company_id = $session_company_id"); - $software_id = $mysqli->lastInsertId(); + $software_id = mysqli_insert_id($mysqli); // Add Asset Licenses if(!empty($_POST['assets'])){