Skip to content
jQuery(document).on('click', '.prescription-btn', function() {
// Get product data from button attributes
const productId = jQuery(this).attr('data-product-id');
const productTitle = jQuery(this).attr('data-product-title');
// Set values in the popup form
const popup = jQuery('#elementor-popup-modal');
popup.find('input[name="product_id"]').val(productId);
popup.find('input[name="product_title"]').val(productTitle);
// Debugging (optional)
console.log("Product ID:", productId, "Title:", productTitle);
});
Reviews
There are no reviews yet