Hi everyone,
I would like if someone could point me in the right direction for doing this.
Each post frontend should have a button that changes the database value on/off if the user is logged in.
Ie.: post_id: 685, meta_key: switch-01, meta_value: off
Clicking the button changes it to on, but only for 2 minutes, then reverts to off.
At the same time when clicked, I would like a hidden “timer” in the frontend under the button to get visible on click and count down ie. 2 minutes to 0.
Any help is much appreciated!