WordPress.org

Ready to get started?Download WordPress

Forums

Help with Creating Client Portal Using Categories (1 post)

  1. daveycoleman
    Member
    Posted 2 years ago #

    Hey folks,

    I am setting up a Client Area for a graphic design studio's website. Here is the scenario:

    • A client is provided with login details.
    • They log in at http://birthedcreative.com/client
    • They are presented with two links (WordPress categories); Jobs & Support.
    • A new sub-category is set up for each new client, under Jobs (i.e. Jobs > john.doe)
    • A wp_query in the category.php file displays the posts filed under the 'Jobs' category:
      <?php wp_reset_query(); if ( is_category( 'projects' ) ) { ?>
      CONTENT HERE
      <?php } ?>
    • Capa Protect restricts the categories at a user-by-user level, so John Doe has the 'john.doe' and 'Jobs' category ticked. Mary Jane has the 'mary.jane' and 'Jobs' category ticked.
    • Initially, for each post for a client, the Category ticked was only the client's name. This meant permissions worked correctly, as ticking the 'Jobs' cat for each post meant this post could be viewed by all clients. This is obviously undesirable.
    • Unfortunately, this means the posts do not display correctly, as the template file is looking for posts filed under 'Jobs'.

    Herein lies the rub;

    How does one uniquely categorise each post (to keep Capa permissions working) while generically categorising (to keep templates working)?

    Obviously this is theoretically impossible, but I was wondering if anyone has any suggestions as to another solution? Essentially having a large repository of posts under two main categories (Jobs & Support), while restricting the viewing permissions in such a way that only relevant posts are available to their respective client, would be amazing.

    Any ideas, good people?

    Thanks in advance for your time!

    Dave.

Topic Closed

This topic has been closed to new replies.

About this Topic