imageTable; $query .= " (filename, filepath) VALUES (?,?)"; } $data = [ 'Errormsg' => $uploadImage['msg'] ?? '', 'success' => $success ]; return json_encode($data); //return var_dump($jsonPayLoad); $keys = array_keys($inputModel); $n = count($keys); $query .= "CALL insert_new_customer_proc ("; for($i = 0; $i < $n-1; $i++) { $query .= "'" . $inputModel[$keys[$i]] . "', "; } $query .= $inputModel[$keys[$i]] . ")"; //return var_dump($query); $rowCount = $this->processImage($query); return $rowCount; } }