Luapress
Luapress copied to clipboard
Tags for posts
Hi, I write about various topics. It would be nice if I could tag my posts and the user could then select the tag and get a list of posts with those tags. I think that this is the sanest solution to the 'too many posts' problem.
@hollunder I really like this idea! There's a few things to think about, brain dumping:
- What URL (
/tag/<tag>
?) - and how does this affect creating apages/tag.md
- Pagination for the tagged posts (archive could also use this)
- Archive could share logic and simply apply to all tags
- Would need ability to list tags somewhere
Glad you like it :)
- I do not know what you mean by pagination
- I did not think about the URL, but your suggestion sounds fine.
- I do not know what you mean by "how does this affect creating a pages/tag.md". Not at all perhaps?
I think that pretty much the same logic could be used everywhere.
- Landing page: lists the last N posts of all tags in reverse chronological order
- Archive: lists all posts of all tags in reverse chronological order
-
page: lists all (or N?) tags of in reverse chronological order
As for displaying, how about a special piece of markdown called --tags--?
I am far from a wizard with web technologies, but I guess if --tags-- inserts a list of links to the
- In the header or some sort of side bar
- On a page
- probably a number of other ways
I guess one may need proper CSS or moustache code for some of that stuff.
Thinking probably too far ahead of myself: if I dedicate a page to tags it might be nice to add a short description to each one. No idea how that could be done. I have my doubts that it is necessary, it is just an idea.