Last Updated: February 25, 2016
·
600
· cmdann

Make A Secure Page For WordPress

I recently wanted to secure a certain page against unregistered users. This obviously is not totally secure in that a user can just register for the website to get access (but that is the point in this case). This is a simple php template for WordPres that will only display the content if the user is logged in.

You can check out this on github:
https://github.com/CMDann/WordPress-Secure-Page-Template

You can also see it in action here:
http://cmdann.ca/etherpad

When the user is logged in the content of the page is displayed. Otherwise an error is displayed and a log in form is provided for the user.

You can style the log in form however you like.