With YITH WooCommerce Share for Discounts, you can allow the sharing of the contents of your shop on social networks via Facebook, Twitter and Google+, or via email. In order to do that, you just have to activate the related options you can find in the settings panel of the plugin.
In order to let the plugin work fine, it is essential to enable coupons in the WooCommerce settings panel.
The product sharing generates a coupon which value depends on how configurated in the “Coupon settings” tab of the plugin settings dashboard.
You can share the same product more than once only after 24 hours have passed.
For the correct functioning of the plugin, it is essential to create an application for each social network you use. An authorized application is a required procedure in accordance with Facebook, Twitter, and LinkedIn privacy policies and is necessary to interact with the social networks. It is also indispensable when used with YITH WooCommerce Share for Discounts to verify the content sharing.
Recently, Facebook has updated the Terms of the platform and is now considering the issuing of a coupon code in exchange of a sharing as a breach of their Terms (read here for more details). Consequently, you might receive an email from Facebook regarding your Facebook app block. Moreover, as Facebook constantly applies changes to their API, the plugin might not work after one of these changes. As long as we can, we will keep supporting the plugin, but please, consider what we have just stated above as a possibility. If you want to use Facebook sharing anyway, please, add this line in the functions.php file of your theme:
Complete the required fields and insert in “Callback url” one of the two options suggested in YITH Plugins -> Share for Discounts -> Settings -> Twitter
After creating the application, go to the “Keys and Access Tokens” section to recover the required parameters, that is “Twitter Consumer Key” and “Twitter Consumer Secret”. Copy and paste them in the related options of the plugin.
As last step click on the “Create my access token” button that you find at the bottom of “Keys and Access Tokens” Twitter section.
If the process ended well, now your users could start sharing your contents via Twitter in order to get the discount you provided.
To enable the sharing via email, you just have to enable the option in the plugin settings and whenever users click on the email sharing button, they will get a form where they can enter the sender and receiver email addresses and a custom message.
The receiver will get a message with a link to the page you’ve shared.
The plugin automatically generates a coupon when a product is shared. The user could use the coupon by adding it to the cart. The amount and modality about the use of the generated coupon depend on the configuration settings, in Share for Discounts -> Coupon Settings, after the coupon sharing.
The coupon can be applied to the shared product or to the cart. Generically, the coupons are cumulative only if applied on the product and the user doesn’t share the same product on the same day. Once shared, the product could no longer be selected again within the same day.The user will find the coupon automatically applied in “cart” and “checkout” pages.
Each generated coupon from a sharing is identified by a name that includes the username- label followed by year, month, day, hour, minute and second of the content shared.
If you want to automatically remove all the expired coupons generated by the plugin, enable “Expired Coupon Clearing”. The removal can be also done manually through the “Remove expired coupons” button.
The sharing buttons can be shown on the product page and in “Cart” and “Checkout” pages. Go to “Share for Discounts -> Sharing Settings” to enable or not the addition and to choose in what spot of the page you want to insert the buttons.
Here, in the Sharing settings section, you can also enable the option Add to cart after sharingwhich allows applying the coupon automatically once shared the related product.
The sharing URL will be the same as the one of the current page unless you inserted a specific URL in “URL to share”.
Any page of the site can be shared if you have inserted the [ywsfd_shortcode] shortcode in the page.
The plugin is ready to use with the new Gutenberg editor. When you add a new post or page, you will be able to find our YITH shortcodes and widgets. With a simple click they will be added to your page.