I have a problem with our site and what follows is my tentative workaround and how it's a hack.
We are using a "sites" taxonomy vocabulary to control the switching of themes based on what 'site' a particular is categorized as. The functionality in most cases uses current($terms) which means that we get the first term. In our case, we want the last term (as defined by the numbering) because the lowest tid is our default site and we want 'sub-sites' to supplant that.
So, where I needed this changed I changed it to end($terms) so that the highest applicable term (by tid) kicks in.
Is there a better way to weight these terms? What if current() were replaced with a function call to a new function in taxonomy_theme? This function would need a config screen. My thinking is that it would need these weighting options:
- weight by tid ascending
- weight by tid descending
- weight by name ascending
- weight by name descending
- weight by parentage (term_heirarchy parent) ascending
- weight by parentage (term_heirarchy parent) descending
- weight by weight (as in system.weight value) ascending (then maybe a way to affect those)
- weight by weight (as in system.weight value) descending (ditto)
All the best,
Mike
Comments
Comment #1
dewolfe001 commentedMy workaraound was this: