Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Selecting multiple categories?
peripatew
New
Would it be possible to select multiple categories? Meaning that the new post would duplicate itself within all the selected categories?
0
Comments
It would probably be possible yes, but I'm no backend-guru I'm afraid :-)
Kasper Kronborg Isager (kasperisager) | Freelance Developer @Vanilla | Hit me up: Google Mail or Vanilla Mail | Find me on GitHub
I have the SQL code to do such, but someone else would have to wrap that code in PHP.
@peripatew, @kasperisager It seems that selecting multiple categories could be more complicated that I thought. There are some aspects to cover, for it to work:
Gdn_Form
class, apparently, doesn't support multi-select elements. It can render and handle a drop down list, but it doesn't interpret the "multiple" attribute. I tried to see what happened when I forced the select to become a multiselect, and, when I saved the data, only one value, of all the ones I selected, was returned.It's surely doable, but it can take quite a bit time to avoid all the pitfalls and do proper testing.
My shop | About Me
Vanilla has a strict hierarchical approach to categories, and one category per discussion, and thus, if you want more than one, then you have save more than one discussion.
Such an approach is largely outmoded. Tagging is a much better approach being non-heriacial reference. This doesn't have the problem of having separate discussions.
grep is your friend.
Tagging is also a good option, to avoid duplicates.
In reference to @peripatew requirements, having multiple discussions would actually be a good solution. He just needs being able to post the same discussions (in his case, Assignments) to multiple, isolated groups (Categories) and keep comments attached to each separate entity. He was just looking for a solution that would not require creating each discussion/assignment by hand.
My shop | About Me
sure though sometime people don't think of all the consequences. duplication is bad SEO, it also quite messy having two separate threads.
it would be better to mark a main category, then have a 301 redirect, so it is kept all together.
grep is your friend.
That's also true. In the specific case of @peripatew, I don't think SEO would be of any importance, though (he is building a portal for his students, which I don't think it needs to be promoted via SEO).
My shop | About Me
ok just checking.
grep is your friend.