Custom template for Password Protect Form

In WordPress I have created a custom page template using the page-slug.php syntax. The page is very different than all the other pages and doesn’t need any managed content.

The page needs to be password protected, so I have set the visibility of the page to Password Protected.

Read More

What happens:
The password protected box only shows up when include the_content() somewhere in the template. The problem is that I can’t include the password field on the page-slug.php template.

What I want to happen (or something similar):
When you navigate to http://site/slug/ it takes you to a password page, and then once authenticated it displays the intended page.

Is this possible with default WordPress functionality? Are there plugins that could accomplish this?

Related posts

Leave a Reply

1 comment

  1. If the page doesn’t need any content, why not just include the call to “the_content()” and not write any content? If no content has been added, it won’t output anything.