MyBB Community Forums

Full Version: Searchbox that only searches titles.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This should be easier than my usermap request ...

worldbeyblade.org
As you can see, our site is currently using MySideBox, and there is a searchbox on that side. However, I want to remove it from there, and place it right below the banner and upper navigation; essentially, where you get your new private message notifications.

That searchbox in particular, though, would need to search topic titles only, not every post, as it does currently. There would still be an "Advanced Search" link nearby.


In theory I think this should be relatively easy, but one of the problems I see is that I believe this {searchbox} is common everywhere around the site, like at the bottom of each forum, yet those should remain as they are right now, searching all posts.
I assume the templates that control the sidebar are the portal's, correct? If so, it should be searching titles only by default. Make sure the following piece of code is in your portal_search template:

<input type="hidden" name="showresults" value="threads" />
Hm, yes, it does seem that the elements on the sidebar are mostly the same as in the portal, but I just tried and it does not search topic titles. Yes, the results that come up are threads, but the keyword I was searching for is not in those titles at all. That means that it searched within the threads, and it is just telling me which topics have that keyword somewhere.