Greetings! I Set-up my very first (feedback) forum with one single plugin, being XYTreads (of course :] ),
If you want to see
http://softimageinput.netne.net/
Everything essentially went quite nicely..
I added a custom field with a key named "tag",
and added a custom field column in the threadlist
showing each posts value for this new "tag" field (being wonderful)
and I can now filter by this new field, which is also (very) wonderful.
BUT! .. *sorting* by this field returns an error saying
_________________________
SQL Error:
1054 - Unknown column 't.tf_tag' in 'order clause'
Query:
SELECT t.*, tfd.`tag` AS `xthreads_tag`, (t.totalratings/t.numratings) AS averagerating, t.username AS threadusername, u.username FROM mbb_threads t LEFT JOIN mbb_users u ON (u.uid = t.uid) LEFT JOIN `mbb_threadfields_data` tfd ON t.tid=tfd.tid WHERE t.fid='2' AND t.visible='1' ORDER BY t.sticky DESC, t.tf_tagkey desc LIMIT 0, 20
______________________
Why is it looking for the preceding 't.'? and where is 'order clause'
I added in forumdisplay.php ::
case "tf_tag":
$sortfield = "tf_tag";
break;
and I setup the column header sorting link in the Template: forumdisplay_threadlist
but even just entering in the adressbar:
http://softimageinput.netne.net/forumdis...http://softimageinput.netne.net/forumdisplay.php?fid=2&sor
returns that same error
The doc is straightforward enough saying:
<< To sort by a thread field, prefix its key with tf_, for example,
forumdisplay.php?fid=2&sortby=tf_myfield will sort the threads by myfield. >>
Having tried many things over several days, and searched all over the net,
if anyone could say if I'm doing something wrong, or otherwise missed something,
it would be very much appreciated,
thanks!
Jason
EDIT: Just so you know if you visit the site, the key (and all references) has been renamed from 'tag' to 'tagkey'