-1

So, my website is made of blog, and a page with collections (tutorials, references, inspiration etc) Blog part is easy and collections are just posts in one place that link to other websites. (Also i use mshots to generate these websites previews and users can add their own posts by using form) The problem is: how to manage and add a lot of collection posts in easy and efficent way. (thousends of them) Here is how i want it to work: http://i.imgur.com/mZTdGh5.jpg We have different topics with categories. When user clicks on category, posts with such category appear below the topics dropdowns. (so everything is happening on one page).

Right now it works like that:

Every topics category is a link to new page where is a shortcode with wp_query that filters posts and displays these with matching id's. So i need to do it like that: create post create new category create new shorcode with this post's category id create new page with shortcode with wp_query create link to ^ this page on topics page

And i end up with a lot of pages and time consuming workflow. After a while its hard to manage everything. Do you know how this could be resolved in a better way? Is there any theme or plugin that could help me? I would really apreciate any advice, thanks in advance :D

  • Hello @Michal - Welcome to the WordPress Development community! It's worth noting that product recommendations are considered off-topic here. – bosco Feb 23 '17 at 0:55
0

WordPress already provides a built-in mechanism for navigating collections of posts called "Archives". Taxonomies such as "Category" naturally create a collection of posts - and thus WordPress automatically facilitates taxonomy archives. Meanwhile, pages are intended to display singular, definitive content that is usually timeless.

It sounds to me as though your "Topics" should be top-level terms in the Category taxonomy, and your "Categories/Topic subCateogries" child terms nested under your "Topics" terms. If that is the case, then there's no reason to recreate WordPress's built-in archive functionality by manually creating pages and shortcodes - links to your topics and categories should already direct to the proper archive displaying relevant posts. If the archive doesn't display as you desire, you should alter your theme (or create your own, or alternately a child theme of a third party theme), likely by modifying the theme's archive.php file to suit your needs.

Instead of manually constructing navigation to your category terms' archives, you can use functions in your templates such as get_categories() and/or get_category_link() to programmatically construct the appropriate markup.

The above in mind, adding new items to your collections should only consist of creating a new post and selecting or creating the appropriate category on the same screen. No custom pages, no custom shortcodes, no custom queries - no handling category IDs, no creating custom links.

If you wish to programmatically manipulate content in bulk instead of using the WordPress Dashboard, you can use the various WordPress APIs to do so.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.