ashleycyber
Forum Replies Created
-
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageThat seems to have done the trick – thank you!
When going to the next page, however, shouldn’t it go back up to the top of the page?
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageThank you!
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageWe have to refresh the page in order for the restricted product alerts to go away (so the cookie IS set properly)
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageWe’ve testing it on Chrome, Edge, and FF. Age is not set per product – all are the same.
So if you go to https://staging.yougrogurl.com/shop/gifts-rewards, click ‘Yes, I am 21+ Years Old”, scroll down and go to the next page (page 2) …. you see the products?
- This reply was modified 3 years, 11 months ago by ashleycyber.
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageNow we noticed that on a shop page that is restricted, and you click Yes, I’m 21+, the notice goes away as expected, but if the user then goes to the next page the notice appears again. Any ideas? (https://staging.yougrogurl.com/shop/gifts-rewards as an example)
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageIt happened once, but now I cannot recreate the issue now – so I think we’re good. Thank you so much for your help.
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageThank you!
So now if a user goes to a restricted category page, and clicks the yes, I’m over 21 button, the individual products beneath still have the restricted item notice, unless the user refreshes the page. I solved this by disabling “Use JavaScript Age Gate”, but isn’t as nice regarding transitions that way. Is there a way to keep JS but not have the individual items showing the notice if a user passes the test on a category page?
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageI changed one line of your code from
if ($restrict) {
to:
if ($restrict or has_term( ‘gifts-rewards’, ‘product_cat’ )) {
———————————————————————-
Is there a better way?
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pagePhil – this works great if the individual products are manually marked as restricted – thank you! What do I need to change to hide any/all products in a product category that is restricted?
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pagePhil – any ideas/thoughts on this?
Forum: Plugins
In reply to: [Age Gate] Replace age restricted product content on shop / archive pageI have a product category that is restricted – that works well on the product pages themselves and the category page, but not on the shop/archive page. Those products still appear, which is fine, but the ‘are you 21?’ should appear (like an overlay) instead of the product details (title, image, etc.) on those products, until the user confirms that they are, in fact, 21.
At the very least, those products shouldn’t show on the shop pages —- but that is not ideal as the user may be over the age and not realize that they aren’t seeing everything.
- This reply was modified 4 years ago by ashleycyber.