• Resolved jmccrone

    (@jmccrone)


    Probably an easy one but I’m new to the backend of WooCommerce hooks, etc. I have a WooCommerce site that is using the Force Sells extension from WooCommerce. Works exactly how I need it to, but the Force Sell product message (notifying the customer an additional product will be added with the product they are looking at) is shown after the Add to Cart button and messes the layout display of the Qty box and Add to Cart button because it’s all on one line in my theme (Astra). I’m just looking for best way to change where the Force Sells instance gets called so the message gets displayed above the price versus after the add to cart button. Link above is an example of a product that has a Force Sell product associated.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello, @jmccrone Currently your force sell is showing on the “woocommerce_cart_contents” hook. You can shift your force-sell to the after cart content. For this, you can use “woocommerce_after_cart_contents” this hook.Download the whole plugin of the Force-sell then find for “woocommerce_cart_contents” hook and replace this hook via “woocommerce_after_cart_contents”.Then It will look better.

    Hello @jmccrone,

    You can add this following CSS code to display the message below the add to cart button.

    .wc-force-sells{
    position: absolute;
    top: 60px;
    }
    Plugin Support AW a11n

    (@slash1andy)

    Automattic Happiness Engineer

    Hey there!

    As mentioned above, there are 2 options to solving this:

    * CSS to position the message exactly where you are wanting (this is the cleanest, best way to do this)
    * Use PHP to change where the message is output. Note: please do not make changes directly to the PHP files in the plugin as recommended above, as that makes the plugin unable to be updated in the future. If you update it will revert to the old version.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WooCommerce Force Sells Extension’ is closed to new replies.