$hook_query_joins = "LEFT JOIN " . TABLE_PREFIX . "thread AS t ON (a.contentid = t.firstpostid)";$hook_query_fields = ", t.threadid";