Support » Plugin: OG — Better Share on Social Media » Does your plugin work with WooCommerce variable products?

  • Resolved boonhost

    (@boonhost)


    Hi,

    As the title states. Does your plugin work with WooCommerce variable products?

    If not, can I request that feature in a future update?

    Best regards
    Jake.

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

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Marcin Pietrzak

    (@iworks)

    hi @boonhost

    I hope it works, but I’m not sure, I’m not well familiar with Woo.

    Could you describe how can I reproduce it and what should be done.

    I try to implement it.

    Could you mail me? (my email is on the top in og.php.

    Thank you in advance.

    Marcin

    Thread Starter boonhost

    (@boonhost)

    Hi Marcin,

    I couldn’t find your e-mail in the og.php file. There are two links to your website, but I couldn’t find your e-mail anywhere when I visited it. So I’m writing you here.

    In WooCommerce you can have several types of products. One is a simple product, which your plugin works with and another is a variable product. Variable products have variants. These variants has individual prices, SKUs and so on.

    To reproduce it, simply install WooCommerce and your plugin. Then make a variable product.

    What I’m trying to accomplish, using the tags your plugin generates, is to make Facebook Catalogue via the Facebook Pixel. For that to work certain Open Graph tags needs to be present.

    What I think needs to be done is, in class-iworks-opengraph.php starting on line 538, you need to update the code to handle both simple products and variable products.

    /Jake

    Plugin Author Marcin Pietrzak

    (@iworks)

    Great!

    Thank you – I will try to reproduce.

    My – email – I’m sorry – you are right! There is no e-mail.

    Correct one is marcin@ – domain of my site 😀

    Marcin

    • This reply was modified 2 years, 4 months ago by Marcin Pietrzak. Reason: typo
    Plugin Author Marcin Pietrzak

    (@iworks)

    Hi @boonhost

    I checked and variable products do no reload page – then I do not know which variant is currently shown to user – it means i can’t change opengraph tags – there is only SKU for product, not for variables.

    OR?!

    Please tell me how can I display selected variable at once?

    M

    Thread Starter boonhost

    (@boonhost)

    Hi, Marcin,

    I think you have to use jQuery.

    Maybe this will lead you in the right direction https://stackoverflow.com/questions/60274127/get-and-display-the-selected-variation-sku-in-woocommerce

    Plugin Author Marcin Pietrzak

    (@iworks)

    Hi @boonhost

    It do not solve our goal – JS change only a page after user action, in user browser – ok, I change tags, then what? Nothing happens, because we still have the same URL – with the same opengraph data.

    Unfortunately this is not a solution – we should have different URL for variants, then and only then – I can change SKU to proper for variant.

    M

    Thread Starter boonhost

    (@boonhost)

    Hi Marcin,

    Then I do not think it can be solved.

    Thank you for giving it at try.

    You can close this thread.

    /Jake

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Does your plugin work with WooCommerce variable products?’ is closed to new replies.