Page Index Toggle Pages: 1
Topic Tools
Normal Topic Default Search parameters (Read 762 times)
ajchis
YaBB Newcomer
*
Offline



Posts: 6
Default Search parameters
May 12th, 2013 at 12:25pm
Post Tools
Can anyone please tell me how to change the default search from "Posts made in the last week" to "All Posts" ?

Thanks
Alastair
  
Back to top
 
IP Logged
 
Dandello
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 2,489
Location: Earth

YaBB 2.6.1
Re: Default Search parameters
Reply #1 - May 12th, 2013 at 3:24pm
Post Tools
What version of YaBB (in 2.5.2 and below it's hardcoded to 31 days.)

You can edit Subs.pl
find
Code
Select All
<input type="hidden" name="age" value="31" /> 


and replace with
Code
Select All
<input type="hidden" name="age" value="0" /> 

(Haven't test this but it should work.)

or better, install Carsten's Set Search mod (It's for 2.4 but should install in 2.5AE and 2.5.2)
« Last Edit: May 12th, 2013 at 11:22pm by Dandello »  

If you only have one solution to a problem you're not trying hard enough!
Back to top
WWW  
IP Logged
 
Bill Myers
God Member
Beta Testers
*****
Offline



Posts: 1,737
Location: Los Angeles

YaBB 2.4
Re: Default Search parameters
Reply #2 - May 12th, 2013 at 6:34pm
Post Tools
ajchis wrote on May 12th, 2013 at 12:25pm:
Can anyone please tell me how to change the default search from "Posts made in the last week" to "All Posts" ?

To give your members even more options if they don't already know to use Search on your menu, another way is to include a highlighted link directly underneath YaBB's default search box.

If you want to do this (based on YaBB 2.4), in Admin Center go to Forum Layout and then Template.

In the Edit Templates text box, search for {yabb searchbox} as follows:
Code
Select All
{yabb searchbox} 


Immediately add after {yabb searchbox} the following HTML language (but replace the url of this forum with your own of course):
Code
Select All
<br><a href="http://www.yabbforum.com/community/YaBB.pl?action=search" onMouseover="window.status='forum search options'; return true;"><SPAN style="BACKGROUND-COLOR: #ffff00">Default search: 7 days. Click/tap for more options.</SPAN></a> 


The result will look like the following directly underneath YaBB's search box in the upper right hand corner of your forum:

Default search: 31 days.
Click/tap for more options.


When the link above is clicked on or tapped on while using an iPad for instance, YaBB's more comprehensive search feature will be made available.

Note: You may want to change the "Maximum number of messages returned on a Search?" to a higher number to better serve your forum's visitors. Go to Admin Center, then Advanced Settings, and then Advanced to do this.
Have fun with your forum! Smiley

« Last Edit: May 12th, 2013 at 6:49pm by Bill Myers »  

Morning, noon, or night, have a great one!

Note: This forum doesn't allow for us to freely edit our posts or topics to make corrections as needed, so please remember to look for subsequent posts if you see any mistakes or outdated information. Sorry for the inconvenience.
Back to top
IP Logged
 
ajchis
YaBB Newcomer
*
Offline



Posts: 6
Re: Default Search parameters
Reply #3 - May 12th, 2013 at 9:12pm
Post Tools
Thanks so much for the excellent suggestions.
All good now!

Alastair
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Topic Tools