• Resolved cbunce

    (@cbunce)


    Hello,

    In my WordPress queries I have previously used ‘has_password’ to exclude those that are password protected. Please can you advise how/if this can be done using this plugin so I can specifically exclude the posts and pages from queries.

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi @cbunce,

    Thanks for reaching out to us.

    Yes, we do have a solution for you to achieve that.

    For faster assistance from our team, could you send over specific codes you’re using to collect posts to our support email – hello(at)preventdirectaccess.com?

    Which PPWP version are you using, by the way?

    Hi @cbunce,

    Hope you’re doing well as usual.

    We haven’t heard back from you for a while now. So we’d like to follow up wondering if we can be of any further assistance.

    Have you managed to get the issue resolved yet, @cbunce?

    Please reply to this support thread or drop us an email at hello(at)preventdirectaccess.com so that we can assist you further.

    Awaiting your reply.

    Just an update, the issue was resolved with the user via email.

    As a reference for other users, in our PPWP Lite version, all passwords are stored under wp_postmeta table.

    The content protection status is defined via wp_postmeta using the “wp_protect_password_multiple_passwords” meta_key.

    Adding the following codes to his query worked.

    'meta_query' 
        array(
          'relation' => 'OR',
          array(
            'key' => 'wp_protect_password_multiple_passwords',
            'compare' => 'NOT EXISTS',
          ),
          array(
            'key' => 'wp_protect_password_multiple_passwords',
            'value' => 'false',
          )
        ),

    Hope it helps.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Exclude protected posts from WP query’ is closed to new replies.