woocommerce_product_add_to_cart_url

woocommerce_product_add_to_cart_url

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: filter

See hook in core

Displaying hooks found in version: woocommerce.9.8.1

apply_filters('woocommerce_product_add_to_cart_url') is found 4 times:

  • /includes/abstracts/abstract-wc-product.php line 2024
    2020
    2021
    2022
    2023
    2024
    2025
    2026
    2027
    2028
    2029
    2030
    *
     * @return string
     */
    public function add_to_cart_url() {
        return apply_filters( 'woocommerce_product_add_to_cart_url', $this->get_permalink(), $this );
    }
     
    /**
     * Get the add to cart button text for the single page.
     *
     * @return string
  • /includes/class-wc-product-external.php line 164
    160
    161
    162
    163
    164
    165
    166
    167
    168
    169
    170
    * @access public
     * @return string
     */
    public function add_to_cart_url() {
        return apply_filters( 'woocommerce_product_add_to_cart_url', $this->get_product_url(), $this );
    }
     
    /**
     * Get the add to cart button text for the single page.
     *
     * @access public
  • /includes/class-wc-product-simple.php line 53
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
                ),
                ( function_exists( 'is_feed' ) && is_feed() ) || ( function_exists( 'is_404' ) && is_404() ) ? $this->get_permalink() : ''
            )
        ) : $this->get_permalink();
        return apply_filters( 'woocommerce_product_add_to_cart_url', $url, $this );
    }
     
    /**
     * Get the add to cart button text.
     *
     * @return string
  • /includes/class-wc-product-variation.php line 208
    204
    205
    206
    207
    208
    209
    210
    211
    212
    213
    214
                ),
                $this->get_permalink()
            )
        ) : $this->get_permalink();
        return apply_filters( 'woocommerce_product_add_to_cart_url', $url, $this );
    }
     
    /**
     * Get SKU (Stock-keeping unit) - product unique ID.
     *
     * @param  string $context What the value is for. Valid values are view and edit.