I'm a novice in PHP and I would like to know on how exactly could I define said row. Any helps/tips are appreciated. Thank you in advanced!
function add_review() {
if(isset($_POST['add_review'])){
(THE UNDEFINED ROW) **$product_id = $row['product_id'];**
$review_name = escape_string($_POST['review_name']);
$review_email = escape_string($_POST['review_email']);
$review_content = escape_string($_POST['review_content']);
$review_created = date("Y-m-d H:i:s");
$rating = escape_string($_POST['rating']);
$review_query = query("INSERT INTO reviews(review_id, product_id, review_name, review_email, review_content, review_created, rating) VALUES('NULL', '$product_id', '$review_name', '$review_email' , '$review_content' , '$review_created' , '$rating')");
confirm_query($review_query);
set_message("Thank you for the feedback!");
}}