From 90fccabafab458b3b966c83654a066a5c60c4e2c Mon Sep 17 00:00:00 2001 From: shyam-mishra Date: Sun, 18 Jul 2021 17:29:33 +0530 Subject: [PATCH] fixed by putting strip all tag --- includes/class-wc-ajax.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/class-wc-ajax.php b/includes/class-wc-ajax.php index 8f95956421d..23ad973b9f2 100644 --- a/includes/class-wc-ajax.php +++ b/includes/class-wc-ajax.php @@ -1673,7 +1673,7 @@ class WC_AJAX { $products = array(); foreach ( $product_objects as $product_object ) { - $products[ $product_object->get_id() ] = rawurldecode( $product_object->get_formatted_name() ); + $products[ $product_object->get_id() ] = rawurldecode( wp_strip_all_tags( $product_object->get_formatted_name() ) ); } wp_send_json( $products );