Closed (won't fix)
Project:
Daily
Version:
5.x-2.1
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
16 Jan 2009 at 22:48 UTC
Updated:
14 Aug 2010 at 21:38 UTC
We're creating a database of quotes and we have the Daily module set up to display a new random quote each day. However, we'd also like to create Daily Containers which display random quotes from particular individuals, each of which is identified by a particular taxonomy term.
Thus, we'd like it the Daily Container content type to have another field so that you can specify the taxonomy term from the second vocabulary.
Comments
Comment #1
EvanDonovan commentedI modified the random daily node function to give this functionality. I don't have the time or the skills to integrate this in with the rest of the module, but I present it here in case it's useful to anyone else.
Comment #2
EvanDonovan commentedActually, I've determined this code doesn't work the way I wanted it to. It only allows for one Quote of the Day at a time since the tid for "Quote" is the same regardless of author. I tried to modify it to make it possible to have multiple quotes, but it doesn't seem possible without changing the table schema. So far my modifications to the table schema have been without success.
Comment #3
EvanDonovan commentedI've gotten this functionality working to my satisfaction now. Below is the main function which implements it. The calling functions need to be changed slightly in order to pass in the right variables. I haven't integrated it in with the interface, however.
In order to get this to work, the table schema must be as follows:
Field Type Null Key Default
nrid int(11) NO PRI 0
tid int(10) unsigned NO 0
tid2 int(11) YES NULL
nid int(10) unsigned NO 0
date char(8) NO NULL
Comment #4
Frodo Looijaard commentedThanks for your comments and patch.
I will not commit this as it seems very specific to your needs and not generally needed.
The best general way to solve this, it would seem, is to combine both vocabularies into one.