I've had it running on my site for the last month, but was a little hacked in. I'm still not sure it's ready for primetime, but if people would like this sooner than later, I can pull something together over the weekend. Actually, I spent many, many hours this week working on this further towards that goal.
This is a uni-directional, one-to-many table. I.E., you don't say A and B are related, you specifically say A is related to B, B is related to A, if you want it bi-directional. This is somewhat purposeful (to control the related counts).
Basic functionality is as follows:
- Add one script call to your sidebar/menu, shows only to admins.
- Add one script call to your posts loop and set a global at the top of index OR let the automatic code hook into the date display (requires you display date for every post).
- When looking at a single post, a button will show up in the sidebar that says 'Start Relating'. Clicking it sets a cookie setting the current post as the target.
- Then, go to ANY view (homepage, cat, search, etc.). In those views, there will be a [+] button next to each (either following the date in auto mode, or wherever you put the call in manual mode).
- Clicking the + button adds that post to the related-posts list for the 'target'.
- Clicking the + button also just refreshed the current page, and you'll see the + is now a - instead. Clicking the - will take that post off the target post's related list.
- In the sidebar, the master button now says 'Done Related'. Clicking it clears the cookie, turns off all the 'editing' buttons.
- One function call then retrieves/shows the related posts list for a given post -- I use it in the sidebar for single posts.
- no many-to-many mapping, or otherwise automatic bi-directional. You manually map all connections between posts.
- Currently no view of 'show me all the articles currently mapped to the target' for easier deletion. That'll have to wait a little bit.
- My site has 'post_type' fields for segmenting the list. Segmenting by category might not be too too difficult, but isn't on my top-10 list of things to do (CG-Amazon needs a lot of work!).