The Query block is my favorite for generating dynamic #WordPress #websites for free with almost no code.
-
The Query block is my favorite for generating dynamic #WordPress #websites for free with almost no code.
-
@jos I use QueryLoop block for characters on my fantasy stories website. First of all I created a custom post type called "person", and a taxonomy "stories" which matches with "posts". Then, every person has their posts: person John Doe's content has a queryloop picking articles whose story is "john", ordered alphabetically. Then the page "characters" queryloops alphabetically all contents of type "person" so I have characters list.
-
@talksina amazing! Sorting, ordering, mixing and matching with different taxonomies—the possibilities are endless.
-
@jos QueryLoops needs attentions though: if I don't take care of the nested block in it, I run the risk of finding title without link. Or the heading of wrong level, if I don't double-check both sides settings (toolbar and block settings). I remember that until last year I had to use a paid plugin to organize my content, now it's different. I only miss to condition names with languages because "Pedro" is Pedro in Italian, in English, and so on. So I have to deeply work.
-
@jos We wrote one over the other. I also redirected tags, that is, instead of pointing to /tag/events it points to a page called "events" with appropriate header, footer, queryloop. It also allows me to have one page with articles tagged "events" from Italian category, then another with "international" so that it is filtered even more. What's missing? An "or" operator. If I set "queryloops -> tag -> announcements" I can include "spoilers" by keyword "spoiler" but not exclude.
-
@talksina @jos I created a block-variation of the query block to handle contextual queries.
Additionally it query with the context of:
1. IN same author
2. IN same author & other post type
3. NOT IN same author
4. Some IN same tags
5. All IN same tags
6. NOT IN same category
7. IN same category & NOT IN same tags
8. EXACT same date
9. BEFORE same year
10. AFTER same month
11. EXACT same day last month
12. EXACT same day last yearYou can download it here, if you want: https://github.com/carstingaxion/additional-advanced-query-loops/archive/refs/heads/contextual-query-loop.zip
-
@carstingaxion @jos I'll get it asap, and try it. No idea of how to add a block from github (think it's as a plugin) then I'll make some experiments!