• Resolved michaeljgibson

    (@michaeljgibson)


    I created a very simple website on Bluehost with WordPress Version: 6.6.2 and PHP Version: 8.3 installed to test this. The only plugin is Simple Membership. I deleted all other auto-installed plugins. The sample page is configured to be restricted to approved users. The only page I manually added is “Home”. There is an approved username “test”, password: “test”.

    The test procedure is:

    1. clear all cache.
    2. Select “Sample Page” and, as expected, get:
      • You need to be logged in to view this content. Please Log In. Not a Member? Join Us
    3. Log in with test user, and see a login success:
      • Logged in as
      • test
      • Account Status
      • Active
      • Membership
      • Approved
      • Account Expiry
      • Never
    4. Select “Sample Page” and, not as expected, get:
      • You need to be logged in to view this content. Please Log In. Not a Member? Join Us
    5. However if I refresh the page, I am given access to the protected content.
    6. This problem seems to be intermittent. Sometimes it works as desired and sometimes not.

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Support mbrsolution

    (@mbrsolution)

    Thank you for reaching out to us.

    There is an approved username “test”, password: “test”.

    If you added the member manually, did you follow the following instructions?

    https://simple-membership-plugin.com/manually-adding-members-site/

    However if I refresh the page, I am given access to the protected content. This problem seems to be intermittent. Sometimes it works as desired and sometimes not.

    This does sound like a caching issue. Does your server have some sort of caching system running? I know your site does not have a cache plugin because mentioned above that you disabled or deleted all other plugins except Simple Membership Plugin.

    The following documentation explains the registration process. This will help you understand how our plugin works.

    https://simple-membership-plugin.com/membership-registration-process-overview/

    The following troubleshooting step can also help you troubleshoot your issue.

    Content protection not working as expected.

    https://simple-membership-plugin.com/common-reasons-content-protection-not-work/

    Let me know if the information above helps you in any way.

    Kind regards.

    Thread Starter michaeljgibson

    (@michaeljgibson)

    I have done some more playing around and testing with this and also tried another membership plugin as well as creating a shortcode that shows the current user:

    <?php 
    function custom_shortcode_func()
    {
    ob_start();
    $current_user = wp_get_current_user();
    if($current_user->ID != 0)
    {
    if(isset($current_user->display_name))
    {
    echo 'Hello ' . $current_user->display_name;
    }
    // $current_user->user_firstname . ' ' . $current_user->user_lastname . '<br />';
    }
    $output = ob_get_clean();
    return $output;
    }
    add_shortcode('current_user', 'custom_shortcode_func');
    ?>

    The problem is the same with the other plugin and the shortcode. To see the user info or restricted content, I have to refresh the page.

    As far as I know, I have all caching turned off, but obviously there is something going on with caching the pages.

    Plugin Support mbrsolution

    (@mbrsolution)

    This is very strange because no one is reporting this issue. What browsers are you using? Have you also cleared the browser cache? When viewing the protected content, are you logged in as the member or are you trying to view the protected content as an admin?

    Kind regards.

    Thread Starter michaeljgibson

    (@michaeljgibson)

    In answer to the questions from mbrsolution, I have tried all the major browsers, edge, chrome, and firefox. I have spent days researching the cache – for all the ways to clear cache, I have cleared them or turned off the caching, and tried all variations multiple times. The login I am using to test is setup as a subscriber, and the protection on the content is configured to allow subscribers to see it. The user configuration and content protection are working, just not right away.

    All that aside, what I have now found is that the problem appears to occur just on Bluehost. I tried a local install, and everything was good, and then I tried a similar test on IONOS, and that worked also. So I have to say that the problem is on Bluehost. They do have some cache configurations and settings that I have tried all variations of, but I still cant get it to work.

    For one more point that might be of interest, I tried using another plugin, “User Registration”, that auto generated a couple pages, and the interesting point is that those pages worked just fine on Bluehost. The user was recognized on the first try as I switched to those pages.

    Plugin Support mbrsolution

    (@mbrsolution)

    Thank you for providing more information.

    All that aside, what I have now found is that the problem appears to occur just on Bluehost. I tried a local install, and everything was good, and then I tried a similar test on IONOS, and that worked also. So I have to say that the problem is on Bluehost. They do have some cache configurations and settings that I have tried all variations of, but I still cant get it to work.

    Have you been in contact with Bluehost support about this issue? Have you check the server log files?

    For one more point that might be of interest, I tried using another plugin, “User Registration”, that auto generated a couple pages, and the interesting point is that those pages worked just fine on Bluehost. The user was recognized on the first try as I switched to those pages.

    What I can suggest is to uninstall the plugin and delete the pages created by the plugin. Install and activate a fresh new copy. Then carry out a test. Make sure Debug log is activated. Once you complete the test, check the log file. Report back with any findings.

    Kind regards

Viewing 5 replies - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.