• Resolved manushaanjaana

    (@manushaanjaana)


    Hi,
    I have a form that has all the types of products we are going to sell in our site.
    So what I want is to know how can I get each product details to a field.
    Ex:
    If I want the price of an apple (saved in products in woocommerce) what is the variable name can be use to get the price details to the form;
    Can you explain this please

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author codepeople

    (@codepeople)

    Hello @manushaanjaana

    I guess you are focusing the integration between our plugin and WooCommerce in the wrong direction.

    If you are talking about the “CFF – WooCommerce” add-on, distributed with the Developer and Platinum versions of our plugin. It allows to include the forms created with our plugin into the WooCommerce products to calculate their prices at runtime (and not the other way around), and once the product be added to the cart (the form is submitted), the control is delegated completely into the WooCommerce.

    If you are integrating the form and product using the “CFF – WooCommerce” add-on, the add-on generates by itself the javascript variable: woocommerce_cpcff_product_price with the default price of the product you can use from the equations associated to the calculated fields. So, assuming you want to duplicate the product’s price, the equation associated to the calculated field would be:

    woocommerce_cpcff_product_price*2

    If you are generating a form for filtering the WooCommerce products, you can read the following post in the plugin’s blog:

    https://cff.dwbooster.com/blog/2019/11/05/case-of-use-filtering-products/

    Best regards.

    Thread Starter manushaanjaana

    (@manushaanjaana)

    Can you explain this
    woocommerce_cpcff_product_price

    What is cpcff:

    Thread Starter manushaanjaana

    (@manushaanjaana)

    What is use as product: Is it Title or slug; or else where can I get the variable name :
    Can you give me an example

    Plugin Author codepeople

    (@codepeople)

    Hello @manushaanjaana

    woocommerce_cpcff_product_price is a global javascript variable generated by the “CFF – WooCommerce” add-on. If the form and product are integrated using the add-on, would be generated the variable with the price defined in the product’s settings. There is another variable generated by the add-on: woocommerce_cpcff_product with the product’s id. (More information in the following post of the plugin’s blog: https://cff.dwbooster.com/blog/2018/11/26/woocommerce)

    If you have additional questions about the commercial features of the plugin, you should contact us through our private website: Contact Us

    Best regards.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘product variable’ is closed to new replies.