Would be possible to access the protected pages with password through of a token. What I mean I pass the token by URL, is going to be checked if the page is protected, if yes check if the URL has the token than the token to be check if match or not.
Leave a Reply
You must be logged in to post a comment.
The protected post system uses
POST
so by default, no you can’t. However, here is a bare-bone mechanism that will let you do this.You need to set the
bypasskey
value for the post using the normal custom meta fields form. You’d access the protected post by tacking?bypasskey=<whatever>
onto the URL. Place this in your theme’sfunctions.php
and you are good to go.Consider this a sort-of proof-of-concept. I don’t think I’d implement it exactly as it is. I’d probably put it in a plugin and use one-time keys or keys with a limited lifespan– say two or three days. And maybe include a random key generator.