Password Protect and Upfront?

Suppose I have a one-page web site made with Upfront, and I want to password-protect the bulk of the content — i.e., the user sees only the password input field and has to enter the password to see the rest of the site, which is also designed using Upfront. Is that possible with this plugin? If so, can I get some instructions? Thanks.

  • Predrag Dubajic
    • Support

    Hey @DKwan,

    Hope you're doing well today :slight_smile:

    Password Protect is intended to be used to hide only certain parts of page/post content that are wrapped in the password protect shortcode, it can't be used to hide entire pages.

    Have you considered using our Membership 2 Pro plugin to limit access to certain parts of your site?
    You can create new memberships and disable access to registered users and visitors, it's not quite enter password and see content but it has some great options you could use.

    Or, have you considered protecting your site using .htaccess, you can find tutorial for that here:

    Hope this solutions will work for you :slight_smile:

    Best regards,

  • DKwan
    • WPMU DEV Initiate

    Thanks Predrag. What if the one-page site has 3 sections, all built with Upfront, and only the second section needs to be password protected? Since the Password Protect feature is implemented by using shortcodes, would that section have to be manually coded (as opposed to built with Upfront)? Or is there a way to build the section with Upfront and then insert the Password Protect shortcodes afterward? Would that break things?

  • Adam Czajczyk
    • Support Gorilla

    Hey DKwan,

    I hope you're well today!

    As you've already noticed, the Password Protect editor's button simply adds a shortcode to the content like this:

    [protect password="abc"]
    this is some content

    As for "pure content" placed inside a section with Upfront's front-end editor, this should work. I've just tested it on my test setup and you can simply add a "text"-type element before and at the end of the content you wish to protect and put the opening and closing shortcodes there.

    That said, it's not meant to work with entire sections and should be rather used at back-end to easily hide some parts of posts/pages content. I'm not saying this will not work at all but you may want to give it a try with your design. I'm pretty sure it should work with "text" (or "text+images") based sections but with more complex designs it will most likely break.

    However, if it will not work for you you may want to give aforementioned Membership 2 Pro a try as it also features shortcodes and is much more advanced.

    I hope that helps!


Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.