AW: [opencms-dev] Search Help

Armen Markarian a.markarian at alkacon.com
Mon Nov 22 10:30:29 CET 2004


In case your opencms-search.xml contains an individual index like "MY
INDEX NAME":

Use the setIndex() Method of the search Bean in your Result JSP

<jsp:useBean id="search" scope="request"
class="org.opencms.search.CmsSearch">
	<jsp:setProperty name="search" property="*"/>
	<% 
	    	search.init(cms.getCmsObject()); 
	    	search.setIndex("YOUR INDEX NAME");
	    	search.setField(new String[] {"title", "keywords",
"description", "content"});	    	
	%> 
</jsp:useBean>

Best reagrds

Armen Markarian
-------------------
Alkacon Software
Alexander Kandzior
Eugen-Langen-Str. 8
50968 Koeln, DE


-----Ursprüngliche Nachricht-----
Von: opencms-dev-bounces at opencms.org
[mailto:opencms-dev-bounces at opencms.org] Im Auftrag von Pankaj Johri
Gesendet: Sonntag, 21. November 2004 14:37
An: opencms-dev at opencms.org
Betreff: [opencms-dev] Search Help


I am using OpenCMS 6.0 Alpha 2 Version.
I wanted to implement Search in one of my module. But whenever I
searched, it always fetch the result from /sites/default/. Please help
how can i specify the location from where I wanted to serach???




_______________________________________________
This mail is send to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please
visit http://mail.opencms.org/mailman/listinfo/opencms-dev




More information about the opencms-dev mailing list