Hi we are using Wordpress with Woocommerce.
I want to display a button based on conditional logic in our private member area. The logic has to check if the logged in user has purchased OR not purchased a specific product (by its ID).
Here's the logic:
Check for products the current user has bought (return product_ids and save them for processing)
If no products bought before (no product_id's found) -> display button1
If product_id contains number 1 or 2 or 3 -> display button2
Elseif product_idcontains number 4 or 5 -> display button3
Elseif product_id contains number 6 -> display button4
Else: dont show any button!
I need a shortcode for this e.g. [productpromotion]. We'll input the shortcode in a widget or on a page / blog post. This is where the conditional logic (as explained above) will be triggered.
When you apply, I'll send you a snippet, that you might need to do this task faster.
Thanks in advance.
About the recuiterMember since May 20, 2018 Ajay Kumar
from Ohio, United States