PDA

View Full Version : New Similar Threads Plugin?


GCC LLC
09-05-2012, 02:13 PM
Does anyone have any suggestions (or know if a premade plugin that would do this) for creating a new plugin which will search for similar threads ONLY within a specfic forumid? I don't want to edit the existing similar threads code, I want to basically duplicate its functionality but only limit the search to a specific forum. The results of this search will appear below the existing similar threads list (but labeled differently to serve a different purpose).

Any thoughts/suggestions appreciated!

kh99
09-05-2012, 02:36 PM
Look at file packages/vbdbsearch/coresearchcontroller.php, function get_similar_threads() (around line 138). It's really just a query that uses a mysql feature to match text against a something and return a score.

GCC LLC
09-05-2012, 02:56 PM
Thanks, I had seen that. Do you know per chance how I could go about duplicating that, modifying the MySQL query, and then making those results available within a template on vB? Inknownthe query I need to run, it's just a matter of getting those results to show in vBulletin. I'd rather not modify any core vB files if I can avoid it, which is why I was hoping I could just write a plugin to accomplish this.

kh99
09-07-2012, 12:38 PM
Yeah, sorry, I guess that was the easy part. I never have looked closely at the search code to see how it could be modified - maybe someone else will help.