parent
591725874a
commit
07237d9a09
|
@ -494,7 +494,7 @@ class WC_Meta_Box_Product_Data {
|
||||||
foreach ( $product_ids as $product_id ) {
|
foreach ( $product_ids as $product_id ) {
|
||||||
$product = wc_get_product( $product_id );
|
$product = wc_get_product( $product_id );
|
||||||
if ( is_object( $product ) ) {
|
if ( is_object( $product ) ) {
|
||||||
$json_ids[ $product_id ] = wp_kses_post( html_entity_decode( $product->get_formatted_name() ) );
|
$json_ids[ $product_id ] = wp_kses_post( html_entity_decode( $product->get_formatted_name(), ENT_QUOTES, get_bloginfo( 'charset' ) ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -511,7 +511,7 @@ class WC_Meta_Box_Product_Data {
|
||||||
foreach ( $product_ids as $product_id ) {
|
foreach ( $product_ids as $product_id ) {
|
||||||
$product = wc_get_product( $product_id );
|
$product = wc_get_product( $product_id );
|
||||||
if ( is_object( $product ) ) {
|
if ( is_object( $product ) ) {
|
||||||
$json_ids[ $product_id ] = wp_kses_post( html_entity_decode( $product->get_formatted_name() ) );
|
$json_ids[ $product_id ] = wp_kses_post( html_entity_decode( $product->get_formatted_name(), ENT_QUOTES, get_bloginfo( 'charset' ) ) );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -530,7 +530,7 @@ class WC_Meta_Box_Product_Data {
|
||||||
if ( $parent_id ) {
|
if ( $parent_id ) {
|
||||||
$parent = wc_get_product( $parent_id );
|
$parent = wc_get_product( $parent_id );
|
||||||
if ( is_object( $parent ) ) {
|
if ( is_object( $parent ) ) {
|
||||||
$parent_title = wp_kses_post( html_entity_decode( $parent->get_formatted_name() ) );
|
$parent_title = wp_kses_post( html_entity_decode( $parent->get_formatted_name(), ENT_QUOTES, get_bloginfo( 'charset' ) ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
echo esc_attr( $parent_title );
|
echo esc_attr( $parent_title );
|
||||||
|
|
|
@ -391,7 +391,7 @@ class WC_Emails {
|
||||||
*/
|
*/
|
||||||
public function low_stock( $product ) {
|
public function low_stock( $product ) {
|
||||||
$subject = sprintf( '[%s] %s', $this->get_blogname(), __( 'Product low in stock', 'woocommerce' ) );
|
$subject = sprintf( '[%s] %s', $this->get_blogname(), __( 'Product low in stock', 'woocommerce' ) );
|
||||||
$message = sprintf( __( '%s is low in stock.', 'woocommerce' ), html_entity_decode( strip_tags( $product->get_formatted_name() ) ) ) . ' ' . sprintf( __( 'There are %d left', 'woocommerce' ), html_entity_decode( strip_tags( $product->get_total_stock() ) ) );
|
$message = sprintf( __( '%s is low in stock.', 'woocommerce' ), html_entity_decode( strip_tags( $product->get_formatted_name() ), ENT_QUOTES, get_bloginfo( 'charset' ) ) ) . ' ' . sprintf( __( 'There are %d left', 'woocommerce' ), html_entity_decode( strip_tags( $product->get_total_stock() ) ) );
|
||||||
|
|
||||||
wp_mail(
|
wp_mail(
|
||||||
apply_filters( 'woocommerce_email_recipient_low_stock', get_option( 'woocommerce_stock_email_recipient' ), $product ),
|
apply_filters( 'woocommerce_email_recipient_low_stock', get_option( 'woocommerce_stock_email_recipient' ), $product ),
|
||||||
|
@ -409,7 +409,7 @@ class WC_Emails {
|
||||||
*/
|
*/
|
||||||
public function no_stock( $product ) {
|
public function no_stock( $product ) {
|
||||||
$subject = sprintf( '[%s] %s', $this->get_blogname(), __( 'Product out of stock', 'woocommerce' ) );
|
$subject = sprintf( '[%s] %s', $this->get_blogname(), __( 'Product out of stock', 'woocommerce' ) );
|
||||||
$message = sprintf( __( '%s is out of stock.', 'woocommerce' ), html_entity_decode( strip_tags( $product->get_formatted_name() ) ) );
|
$message = sprintf( __( '%s is out of stock.', 'woocommerce' ), html_entity_decode( strip_tags( $product->get_formatted_name() ), ENT_QUOTES, get_bloginfo( 'charset' ) ) );
|
||||||
|
|
||||||
wp_mail(
|
wp_mail(
|
||||||
apply_filters( 'woocommerce_email_recipient_no_stock', get_option( 'woocommerce_stock_email_recipient' ), $product ),
|
apply_filters( 'woocommerce_email_recipient_no_stock', get_option( 'woocommerce_stock_email_recipient' ), $product ),
|
||||||
|
@ -439,7 +439,7 @@ class WC_Emails {
|
||||||
}
|
}
|
||||||
|
|
||||||
$subject = sprintf( '[%s] %s', $this->get_blogname(), __( 'Product Backorder', 'woocommerce' ) );
|
$subject = sprintf( '[%s] %s', $this->get_blogname(), __( 'Product Backorder', 'woocommerce' ) );
|
||||||
$message = sprintf( __( '%s units of %s have been backordered in order #%s.', 'woocommerce' ), $quantity, html_entity_decode( strip_tags( $product->get_formatted_name() ) ), $order->get_order_number() );
|
$message = sprintf( __( '%s units of %s have been backordered in order #%s.', 'woocommerce' ), $quantity, html_entity_decode( strip_tags( $product->get_formatted_name() ), ENT_QUOTES, get_bloginfo( 'charset' ) ), $order->get_order_number() );
|
||||||
|
|
||||||
wp_mail(
|
wp_mail(
|
||||||
apply_filters( 'woocommerce_email_recipient_backorder', get_option( 'woocommerce_stock_email_recipient' ), $args ),
|
apply_filters( 'woocommerce_email_recipient_backorder', get_option( 'woocommerce_stock_email_recipient' ), $args ),
|
||||||
|
|
Loading…
Reference in New Issue