[RSS Feed/News] Best way to use the finder to find a thread based on a tag?

Status
Not open for further replies.

XenForo

Administrative
  • Thread starter
  • Admin
  • #1
Hi,

If I'm trying to find the most recent open visible thread with a tag (ID or Url whatever is better?)

Is the best way like below to just hit the thread table searching the tag blob using the tag_url/tag_id?

Or should I be joining with the tag table and finding based on the tag_ID?

Just hitting the thread table
Code:

Code:
$this->app->finder('XF:Thread')
->where('tag', 'LIKE', $finder->escapeLike($tag_url, '%?%'))
->where('discussion_state', '=', 'visible')
->where('discussion_open', '=', 1)...

Read more

ادامه مطلب...
 
Status
Not open for further replies.
Back
Top Bottom