admin管理员组文章数量:1429376
I want to set up a page with PayPal subscription gate away to my members area. It's a simple page with PayPal button which offer discounted subscription price for the chosen customers only.
Therefore I want to give one time access to it. So when the visitor leaves the page to go to PayPal to start subscription and then return to the page - access will be denied. The new access will be denied even if he/she do not subscribe. In short, it is one time visit. This will stop them spreading this offer all over the net.
Would appreciate if you provide the code or plugin for this. Thanks
I want to set up a page with PayPal subscription gate away to my members area. It's a simple page with PayPal button which offer discounted subscription price for the chosen customers only.
Therefore I want to give one time access to it. So when the visitor leaves the page to go to PayPal to start subscription and then return to the page - access will be denied. The new access will be denied even if he/she do not subscribe. In short, it is one time visit. This will stop them spreading this offer all over the net.
Would appreciate if you provide the code or plugin for this. Thanks
Share Improve this question asked Apr 27, 2019 at 21:22 VitVit 1 1- Hey hey, welcome to WordPress Stack Exchange! We love to help you. But plugin recommendations are off-topic. And coding requests are too broad unless you can show us what you tried yourself so far and where exactly you are stuck. Please visit the help center and learn How to ask a good question. Thank you and good luck – norman.lol Commented Apr 27, 2019 at 22:02
1 Answer
Reset to default 1Although this is not a WP question, it could be done with some PHP/MySQL code. Just the psuedocode:
- generate a GUID value on each main page visit
- check if the GUID is already in the GUID database
- if not, store the GUID in the GUID database
- if GUID exists in the database, redirect to another page ("you were already here, only one per customer" message)
This requires a GUID database that you get to build. And all of the PHP/MySQL code to implement.
Then, create a template from your theme (and a Child Theme to put it in). Add the code to check/store the GUID to that template.
You could also make it into a plugin, where the plugin checks for the page-id of the page you want to limit, so the plugin only runs on the specific page.
But, again, this is not a WP Development question. You'll have to build it yourself. But it can be done. My approach is only one way; there are probably others discoverable via the googles (or bings or ducks).
本文标签: linksone time visit to the page
版权声明:本文标题:links - one time visit to the page 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745545150a2662670.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论