Hi, I'm trying to understand how to refine search results for a site using Company Directory and News for most of the websites content.
How would I restrict the search results to only show CD and News entries.
Any help will be much appreciated.
CMSMS Version 2.1.6
AdminSearch 1.0.2
Album 1.11
CGCalendar 2.4.4
CGExtensions 1.55.6
CGFeedback 1.8.3
CGGoogleMaps2 1.1.1
CGSimpleSmarty 2.1.6
CGSmartImage 1.21.9
CGStaticMaps 1.0.2
CMSContentManager 1.1.4
CMSMailer 6.2.14
Captcha 0.5.5
CompanyDirectory 1.23.5
DesignManager 1.1.1
FileManager 1.5.2
FormBuilder 0.8.1.6
JQueryTools 1.4.0.3
MicroTiny 2.0.3
ModuleManager 2.0.5
Navigator 1.0.3
News 2.50.6
Search 1.50.2
Restrict Search from showing everything
-
CapereSpiritum
- Forum Members

- Posts: 223
- Joined: Wed Dec 28, 2011 12:11 pm
Re: Restrict Search from showing everything
As far as I remember there is a nice and clear example in the search result template itself. Check it in the DesignManager.
-
CapereSpiritum
- Forum Members

- Posts: 223
- Joined: Wed Dec 28, 2011 12:11 pm
Re: Restrict Search from showing everything
Hi Jos
Yes, I saw that. it shows:
So I added:
I get a page not found error
There's gotta be something pretty basic that I'm missing.
Any clues?
Thanks
Simon
Yes, I saw that. it shows:
Code: Select all
{if $entry->module == 'News'}{News action='detail' article_id=$entry->modulerecord detailpage='News'}Code: Select all
<li>{if $entry->module == 'CompanyDirectory'}{CompanyDirectory action='detail' article_id=$entry->modulerecord detailpage='entry-details'}{$entry->title} - <a href="{$entry->url}">View Result</a>{/if}</li>There's gotta be something pretty basic that I'm missing.
Any clues?
Thanks
Simon
Re: Restrict Search from showing everything
There is a parameter you can add to your Search tag for only showing only results from specified modules if that's what you're after...
Code: Select all
(optional) modules="null" - Limit search results to values indexed from the specified (comma separated) list of modules


