<get_description>

The WooCommerce get description shortcode.


Usage

  1. // assign value 
  2. $get_description = 'dynamic_tag'; 
  3.  
  4. // basic usage 
  5. echo do_shortcode("[$get_description]"); 
  1. // assign value 
  2. $get_description = 'dynamic_tag'; 
  3.  
  4. // variable usage 
  5. $result = do_shortcode("[$get_description]"); 
  6. echo $result;  

Defined (4)

The shortcode is defined in the following location(s).

/includes/api/class-wc-rest-products-controller.php  
  1. 'date_modified_gmt' => wc_rest_prepare_date_response( $product->get_date_modified() ),  
  2. 'type' => $product->get_type(),  
  3. 'status' => $product->get_status(),  
  4. 'featured' => $product->is_featured(),  
  5. 'catalog_visibility' => $product->get_catalog_visibility(),  
  6. 'description' => wpautop( do_shortcode( $product->get_description() ) ),  
  7. 'short_description' => apply_filters( 'woocommerce_short_description', $product->get_short_description() ),  
  8. 'sku' => $product->get_sku(),  
  9. 'price' => $product->get_price(),  
  10. 'regular_price' => $product->get_regular_price(),  
  11. 'sale_price' => $product->get_sale_price() ? $product->get_sale_price() : '',  
/includes/api/legacy/v2/class-wc-api-products.php  
  1. ),  
  2. 'shipping_required' => $product->needs_shipping(),  
  3. 'shipping_taxable' => $product->is_shipping_taxable(),  
  4. 'shipping_class' => $product->get_shipping_class(),  
  5. 'shipping_class_id' => ( 0 !== $product->get_shipping_class_id() ) ? $product->get_shipping_class_id() : null,  
  6. 'description' => wpautop( do_shortcode( $product->get_description() ) ),  
  7. 'short_description' => apply_filters( 'woocommerce_short_description', $product->get_short_description() ),  
  8. 'reviews_allowed' => $product->get_reviews_allowed(),  
  9. 'average_rating' => wc_format_decimal( $product->get_average_rating(), 2 ),  
  10. 'rating_count' => $product->get_rating_count(),  
  11. 'related_ids' => array_map( 'absint', array_values( wc_get_related_products( $product->get_id() ) ) ),  
/includes/api/legacy/v3/class-wc-api-products.php  
  1. ),  
  2. 'shipping_required' => $product->needs_shipping(),  
  3. 'shipping_taxable' => $product->is_shipping_taxable(),  
  4. 'shipping_class' => $product->get_shipping_class(),  
  5. 'shipping_class_id' => ( 0 !== $product->get_shipping_class_id() ) ? $product->get_shipping_class_id() : null,  
  6. 'description' => wpautop( do_shortcode( $product->get_description() ) ),  
  7. 'short_description' => apply_filters( 'woocommerce_short_description', $product->get_short_description() ),  
  8. 'reviews_allowed' => $product->get_reviews_allowed(),  
  9. 'average_rating' => wc_format_decimal( $product->get_average_rating(), 2 ),  
  10. 'rating_count' => $product->get_rating_count(),  
  11. 'related_ids' => array_map( 'absint', array_values( wc_get_related_products( $product->get_id() ) ) ),  
/includes/api/v1/class-wc-rest-products-controller.php  
  1. 'date_modified' => wc_rest_prepare_date_response( $product->get_date_modified() ),  
  2. 'type' => $product->get_type(),  
  3. 'status' => $product->get_status(),  
  4. 'featured' => $product->is_featured(),  
  5. 'catalog_visibility' => $product->get_catalog_visibility(),  
  6. 'description' => wpautop( do_shortcode( $product->get_description() ) ),  
  7. 'short_description' => apply_filters( 'woocommerce_short_description', $product->get_short_description() ),  
  8. 'sku' => $product->get_sku(),  
  9. 'price' => $product->get_price(),  
  10. 'regular_price' => $product->get_regular_price(),  
  11. 'sale_price' => $product->get_sale_price() ? $product->get_sale_price() : '',