Merge pull request #27465 from woocommerce/revert-26885-fix/26780
Revert "Fixed HTML entities in product name not showing correctly in cart page"
This commit is contained in:
commit
4d7741c329
|
@ -11,8 +11,8 @@
|
||||||
* the readme will list any important changes.
|
* the readme will list any important changes.
|
||||||
*
|
*
|
||||||
* @see https://docs.woocommerce.com/document/template-structure/
|
* @see https://docs.woocommerce.com/document/template-structure/
|
||||||
* @package WooCommerce\Templates
|
* @package WooCommerce/Templates
|
||||||
* @version 4.4.0
|
* @version 3.8.0
|
||||||
*/
|
*/
|
||||||
|
|
||||||
defined( 'ABSPATH' ) || exit;
|
defined( 'ABSPATH' ) || exit;
|
||||||
|
@ -77,9 +77,9 @@ do_action( 'woocommerce_before_cart' ); ?>
|
||||||
<td class="product-name" data-title="<?php esc_attr_e( 'Product', 'woocommerce' ); ?>">
|
<td class="product-name" data-title="<?php esc_attr_e( 'Product', 'woocommerce' ); ?>">
|
||||||
<?php
|
<?php
|
||||||
if ( ! $product_permalink ) {
|
if ( ! $product_permalink ) {
|
||||||
echo wp_kses_post( apply_filters( 'woocommerce_cart_item_name', esc_html( $_product->get_name() ), $cart_item, $cart_item_key ) . ' ' );
|
echo wp_kses_post( apply_filters( 'woocommerce_cart_item_name', $_product->get_name(), $cart_item, $cart_item_key ) . ' ' );
|
||||||
} else {
|
} else {
|
||||||
echo wp_kses_post( apply_filters( 'woocommerce_cart_item_name', sprintf( '<a href="%s">%s</a>', esc_url( $product_permalink ), esc_html( $_product->get_name() ) ), $cart_item, $cart_item_key ) );
|
echo wp_kses_post( apply_filters( 'woocommerce_cart_item_name', sprintf( '<a href="%s">%s</a>', esc_url( $product_permalink ), $_product->get_name() ), $cart_item, $cart_item_key ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
do_action( 'woocommerce_after_cart_item_name', $cart_item, $cart_item_key );
|
do_action( 'woocommerce_after_cart_item_name', $cart_item, $cart_item_key );
|
||||||
|
|
|
@ -11,15 +11,12 @@
|
||||||
* the readme will list any important changes.
|
* the readme will list any important changes.
|
||||||
*
|
*
|
||||||
* @see https://docs.woocommerce.com/document/template-structure/
|
* @see https://docs.woocommerce.com/document/template-structure/
|
||||||
* @package WooCommerce\Templates
|
* @package WooCommerce/Templates
|
||||||
* @version 4.4.0
|
* @version 1.6.4
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if ( ! defined( 'ABSPATH' ) ) {
|
if ( ! defined( 'ABSPATH' ) ) {
|
||||||
exit; // Exit if accessed directly.
|
exit; // Exit if accessed directly.
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
the_title( '<h1 class="product_title entry-title">', '</h1>' );
|
||||||
<h1 class="product_title entry-title">
|
|
||||||
<?php echo esc_html( get_the_title() ); ?>
|
|
||||||
</h1>
|
|
||||||
|
|
Loading…
Reference in New Issue