Scoured the forum for help with this as I’m trying to send clients proposals as CMS pages, but each item would need its own password unique to the client (which Webflow doesn’t offer yet).
I found some code on a forum post a while ago (unfortunately I can’t find the post so I can’t credit the author yet) that goes like this:
<script> var password = "password"; if(prompt("Enter password:", "") !== password) window.location = "/"; </script>
It’s not a full password page but it works as a little popup.
So I created a “Proposals” collection with a reference field to another collection called “Passwords.”
Add the above code to inside the header of the Collection Page Template (in this case, “Proposals”), and click Add Field. Replace the word “password” (in var password= “password”) with the reference field to a Password Code field in the Passwords collection. It’ll automatically link each custom password to each particular collection page to which they apply!
Let me know how this works for you!