WordPress.org

Forums

[resolved] Password Protect A Single Page (6 posts)

  1. deltaomicronmu
    Member
    Posted 8 years ago #

    I am looking for way to better password protect one of the pages on my WordPress site. The page is currently password protected by the option when you create a page, but it is not secure enough.
    I can log in and I will be kept logged in for weeks at a time. I need some way to log-in so that users will be logged out whenever they navigate away from the page.

  2. jetshack
    Member
    Posted 8 years ago #

    this isn't perfect... but... you can change the cookie timeout by

    go to
    wp-includes/pluggable.php
    find the line which looks something like

    if ( $remember )
    $expire = time() + 31536000;
    else
    $expire = 0;

    change the expire time from 31536000 (which equals 365 days in seconds) to the desired ammount of seconds

    that's going to change the timeout for your cookies sitewide... not just for that page.

  3. deltaomicronmu
    Member
    Posted 8 years ago #

    I tried this: changing 31536000 to a limit which should have only kept me logged in for an hour. I am still logged in 12 hours later.

    -----

    I want a plugin that will result in a JavaScript password-prompt box showing up when someone navigates to this specific page.
    Or even something as simple as the login that WP-Cal uses that doesn't cause any extra pop-up windows.

  4. jetshack
    Member
    Posted 8 years ago #

    I'm willing to bet that you're still logged in because your cookie hasn't been modified yet, if you delete your current batch of cookies as relates to your site then I think that issue would be taken care of.

    as regards a plugin for what you're looking for, I don't know of one. Not saying that there isn't one, just that I don't know of one.

  5. nakedape
    Member
    Posted 8 years ago #

    I want a plugin that will result in a JavaScript password-prompt box showing up when someone navigates to this specific page.

    did you ever find one?

    I would like to know about it.

    :)

  6. criscom
    Member
    Posted 8 years ago #

Topic Closed

This topic has been closed to new replies.

About this Topic