Toggle (Show/Hide) Partial Page Content with a Password

Hi Weavers!
I am building a page where I would l like half of the content viewable to anyone, but the other half would be locked and only displayed AFTER a user enters an access code they receive from me. For my purposes, I can give the same access code to many people. It does not have to be a unique access code for each person.

So, at the bottom of the default content, there would need to be a field for entering the access code to reveal additional content.

I am using Foundation 6 and Stacks if that helps.

Thanks,
Brad

If I understand your requirements, PageSafe has a stack that will Show different content for users that have logged in and users that haven’t yet logged in. You could make it dowhat I think you are talking about.

If you need more finite control then there’s SiteLok, it’s a full membership system.

Could be a job for the free Query Display stack?

1 Like

Hi Doug,
Thanks for the response.
I did try to get the PageSafe option working. The stack you are referring to there is called Stack Safe. The only way I could get this solution to work was by having the login on a different page. If I put the PageSafe & Stack Safe components on the same page, then that page will only show a blank screen needing to be unlocked. I’m sure @joeworkman would know more so I will bump him here.

I’m not at a Mac right now, but couldn’t you put a link to a login page in the “not logged in” area of that stack?

Not sure if it would work or not, but might be worth a try.

Here’s a rough mock-up.

Yes, the DisplayQuery stack could work!

Yes, Doug, I certainly could. Doing so just makes this a bit more complex than I would like it to be. I would love to limit this to a single page, if possible.

This is correct. You can have a centralized login page that you link to. Once the user logs in, they can be redirected back to the page that they were at. Then Stack Safe will display the hidden content.

This centralized login page could have nothing but PageSafe on it. This is really a super simple implementation.

1 Like

Brad, I’ve been looking for the same thing for a long time with no success. I only want to hide a single stack, but all the options I can find force a page reload, which I can’t have. The one exception is 1LD’s restrict content. I used it for awhile, but it seems to conflict with other stacks, causing JS errors, and making it impossible to preview my pages. It might work for you, but I am seeking other options. It seems like a simple matter for a stack developer to create essentially a toggle that has a conditional text entry as the trigger. Maybe if enough of us ask for it, someone might pick it up. Please reply if you find the solution you are looking for!

1 Like

Hi Anderson,

I implemented the QueryDisplay stack. It’s very simple to setup as long as you don’t need ultra secure content. I am simply using one page to display 3 different things depending on the key I add to the end of the string.
For a new client that wants to inquire about coaching with us, they go to our website here (be sure to hover the URLS below so you can see what they are):

After they submit an inquiry, we send them to the same page, but with different content displayed:

Then when they are ready to schedule an appointment, we send them to:

This allows us a way to control who is submitting forms to us and scheduling on our calendar. It seems to be working great and I have always been a fan of Will’s stacks.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.