from https://businessbloomer.com/woocommerce-conditional-logic-ultimate-php-guide/
global $woocommerce_loop;
if ( is_product() && $woocommerce_loop['name'] == 'related' ) {
add_action('woocommerce_after_shop_loop_item_title','your_custom_function',20);
}
Related Posts:
- Adding new divs with custom classes to products on WooCommerce shop page [closed]
- Remove Woocommerce product link
- get product attributes for current product and store it in a variable
- WooCommerce: How to display item meta data in email confirmation using woocommerce_order_item_meta_end
- How to remove “out of stock” variation options from size dropdown in woocommerce?
- How to Remove a Filter from the Admin List Table?
- Replace existing content from specific WooCommerce admin orders list column
- Woocommerce – How to get products which have a sale between 20% to 40%? [closed]
- How To Change The Html of Products filtration sidebar in Woocommerce?
- WooCommerce: Add Payment Gateway Field to Webhooks [closed]
- How to select WooCommerce products by post_meta and order them
- How to add a second ‘place order’ button in WooCommerce [closed]
- Setting up 2 SMTP accounts: 1 for wordpress and 1 for woocommerce
- Reload part of checkout on changed shipping method
- Trying to build simple deposit code that hooks into woocommerce
- Woocommerce: hook action/filter I could use to add variation id and price with each attribute opt on WooCommerce Rest api
- Add a product to checkout via form
- Displaying Woocommerce Product Category in WordPress
- Is it possible to intercept all ajax requests and get the parameters and the returns?
- Woocommerce : Can’t get product info in loop
- How to remove woocommerce_breadcrumb() from do_action( ‘woocommerce_before_main_content’ ); [closed]
- WP_Query multiple post results
- Convert Featured products loop into Recent products loop?
- How to sort WooCommerce products page by latest in-stock items first?
- Variation prices breakdown only for single product page
- Display custom field value in woocommerce variable product via jQurey
- Adding custom field to product category and show it to shop/category shop page
- Display all categories including sub categories under a list ul
- Discount in the specific product title using keyword ( Woocoommerce )
- How do I remove an action hook inside a class that is called by another class?
- Need to forward Data from WooCommerce Webhook sent to same site WordPress REST API custom endpoint
- Clone the “proceed to cart” button and place it above checkout on the cart page, but only appear display size is 320px
- Display product attributes for current product
- Post formating on Home page
- How to add custom checkout field in user details mail template
- For each loop will not append to the_content hook
- Change Checkout “Place Order” text if cart has a specific product
- Send a custom notification to customer on WooCommerce cancelled order status
- Woocommerce linking variations
- Woocommerce – add tracking code to another email template
- WordPress Search Results for Multiple Post Types
- Call global variable array() in woocommerce child/template
- Remove price from Woocommerce variable product dropdown menu
- hook that when page is starting to load
- Changing layout with wp_customise
- How to change home or site url using action hooks or filter?
- Adding nofollow to a PHP generated Nav
- Dynamic Stylesheet loads but doesn’t finish
- ajax, right way to do it and make it works?
- Filter Select results based on selection
- Using loop pagination on single.php
- Loop with slider (slider not loading)
- How to hide all child pages with post_query?
- How to sort posts based on the value (number) of a post’s metadata?
- Show css depending on activity type in BuddyPress activity-loop [closed]
- Automated Cart Update With Alert Box Each Time
- Two Different Links for Same Product – WooCommerce [closed]
- Issue adding sub category programmatically
- WooCommerce/WordPress: how hide entire table form after submit (Admin Dashboard)?
- Sending data from custom inputs in WordPress comment form in the admin notification email
- Edit incorrect password message WordPress
- Why my filterable portfolio page work not perfectly between slug button and slug output WORDRPESS?
- dividing sub-categories by parent category – WordPress
- Show prices with tax in Woocommerce Mini Cart [closed]
- Woocommerce product variation backorder
- Status 400 for AJAX POST Request with admin-ajax.php
- Problem with custom plugin using AJAX to pull info from php file
- Woocommerce hook run after an Order been created through REST API
- How can I apply_filters from inside a function?
- Get and insert order email address to the PHP template inside HTML text
- Modify HTML structure of fields in woocommerce checkout form
- Pass Category Name, Description and Photo into variables to pass to jQuery
- Auto-update products after they were published – Woocommerce
- How to VAR_DUMP a $variable during checkout process (Is my product meta callable?)
- How to get all shipping rates and costs without session in woocommerce?
- Display a specific category of products in shop page and disable code for specific actions
- If no products are on sale – hide ID or class
- Woocommerce related product text
- Woocommerce api: create product with images – bad request
- WooCommerce Webhooks not firing because of error in wp-includes/meta.php
- Contact Fom 7 – how to add custom HTML inside span.wpcf7-form-control-wrap AND IMMEDIATELY AFTER input.wpcf7-form-control?
- Different Minimum Order Amounts based on Shipping Zone [closed]
- Iterate through posts based on array of categories
- do search in two site and show the result in first site
- Remove metabox from WordPress menu editor page?
- Trying to place a custom field after the total section in the checkout page in woocommerce
- WordPress default Search function inconsistent in WooCommerce Product Titles
- get author_name from queried post
- Which field should I edit to make the checkbox marked by default?
- Why ajax doesn’t work on certain wordpress hooks and reload the page instead?
- Why ajax doesn’t work on certain wordpress hooks?
- Remove a div from RSS feed
- user_profile_update_errors hook not executing
- Set meta field to publish date + 2 weeks
- WooCommerce: How can I get orders with a custom ID in order meta data object?
- How to add an arrow to menu items has submenus
- WordPress Gravatar filter is removing my custom attributes
- wordpress + woocommerce display product with additional information [closed]
- how to fix error “called incorrectly, should not be accessed directly”?
- How can I add extra word in permalink when someone click download button?