With the new way of searching does this mean the old way through a submit will be depracted in future releases? Are ez recommending using the new fetch method?
I notice that bug i filed is marked as fixed but it is not. While the new fetch method may work the other method of using page limit to control the number of results returned is still the same. You can set the page limit in your template file but it is not read by the advancedsearch.php script. The bug fix remains the same: stick in the code to recognise the post variable.
> With the new way of searching does this mean the old way through a submit will be depracted in future releases? Are ez recommending using the new fetch method?
You will have more flexibility with the new search operator, it also means you can use it in other templates for instance to replace a normal list fetch.
> You can set the page limit in your template file but it is not read by the advancedsearch.php script. The bug fix remains the same: stick in the code to recognise the post variable.
Ah, I though you only wanted template controlled page limit. But this allows you to set the limit from another page, I'll add it.
But I think there should be another check in the code to see if the limit is over a specific max value, if it is the limit is set to the max limit value. That way it's not possible for users to set an limit of something like 10000 which could easily break the server. The limit could be in a .ini file to allow site adminstrators to tweak it, 30 is a good default I guess.
It seems it's already present in 3.2, the post variable is called SearchPageLimit and the template variable search_page_limit. The $pageLimit is only used for the old code which does the search in PHP.
It also seems that the search_page_limit is not set in content/search, I'll add that too with the limiter.
I noticed search_page_limit. I thought this would be what i wanted but if you search the php this value doesn't get passed into the ezsearch call, only $pageLimit does. $searchPageLimit is set but isnt used except to set the tpl result with.
With 3.1 I designed a new advancedsearch.tpl to use the results coming from the advancedsearch.php. This still works but i need to set $pageLimit to the value i want, something different than 10. An upper bound on this value is good to have.
3.2 has the new template search but at the moment i can't spend the time redesigning the template to accomodate this. The php still works with my tpl file. Since the 3.2 code also still uses $pageLimit to define the number of search objects returned i would like that fix to be put in to allow me to set pageLimit.
paul
You must be logged in to post messages in this topic!