1
rickh
[search function] don't show empty results
  • 2004/10/21 12:07

  • rickh

  • Just popping in

  • Posts: 94

  • Since: 2004/4/9 6


Hello,

When I start a search action with xoops, I get the results ordered by module. But with a lot of search actions on my site I only get results in 1 or 2 modules. All the other modules say "no result matched your query". In fact nothing wrong with this.

But I think it's easier to understand for users that they dont see that modules which say 'no results matched your query' in their search results. i.e. if there's only a result in the news module u only get THAT module as search result and the others will be totally hidden.

Is this possible to create? Maybe a hack or something?

2
Mithrandir
Re: [search function] don't show empty results

search.php:
Move line 141
echo "<h4>".$myts->makeTboxData4Show($module->getVar('name'))."</h4>";

inside the subsequent else-clause

and comment out line 144, so it will look something like this:
if (!is_array($results) || $count == 0) {
        
//echo "<p>"._SR_NOMATCH."</p>";
} else {
    echo 
"<h4>".$myts->makeTboxData4Show($module->getVar('name'))."</h4>";
    for (
$i 0$i $count$i++) {

3
rickh
Re:[search function] don't show empty results
  • 2004/10/21 12:21

  • rickh

  • Just popping in

  • Posts: 94

  • Since: 2004/4/9 6


thanks a lot!!

Login

Who's Online

208 user(s) are online (141 user(s) are browsing Support Forums)


Members: 0


Guests: 208


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits