Add third-party search options to the search control 

You can extend the search control in IBM Connections to include options from third-party search engines by configuring settings in the LotusConnections-config.xml file.


Before starting

To edit configuration files, use the wsadmin client. See Starting the wsadmin client for information about how to start the wsadmin command-line tool.


About this task

When you configure settings for additional search options in the LotusConnections-config.xml file, those options are made available to users from the Search drop-down menu, allowing them to search content from the sources described in the configuration file. When a user selects a third-party search engine from the Search menu and enters a query term, the results of the search display on a third-party search results page.


Procedure

To add a third-party option to the IBM Connections search control...

  1. Use the wsadmin client to access and check out the IBM Connections configuration files.

    1. Enter the following command to access the IBM Connections configuration file: execfile("connectionsConfig.py")

        If prompted to specify a service to connect to, type 1 to pick the first node in the list. Most commands can run on any node. If the command writes or reads information to or from a file using a local file path, pick the node where the file is stored. This information is not used by the wsadmin client when you are making configuration changes.

    2. Check out the IBM Connections configuration files:

        LCConfigService.checkOutConfig("<working_directory>","<cell_name>")

        where:

        • <working_directory> is the temporary working directory to which the configuration XML and XSD files are copied and are stored while you make changes to them. Use forward slashes to separate directories in the file path, even if you are using the Microsoft™ Windows™ operating system.

            AIX and Linux™ only: The directory must grant write permissions or the command does not run successfully.

        • <cell_name> is the name of the WAS cell hosting the IBM Connections application. This argument is case-sensitive, so type it with care. To obtain the cell name:print AdminControl.getCell()

        For example:

        • AIX or Linux:LCConfigService.checkOutConfig("/opt/temp","foo01Cell01")

        • Microsoft Windows:LCConfigService.checkOutConfig("c:/temp","foo01Cell01")

  2. Navigate to the temporary working directory that you specified in the previous step, and then open the LotusConnections-config.xml file in a text editor.

  3. Define the additional search option as a child element of the serviceName="search" element by adding a <sloc:searchScope> element that contains the details of the third-party service.

      For example:

      <sloc:serviceReference bootstrapHost="" bootstrapPort="" clusterName="cluster" enabled="true" serviceName="search" ssl_enabled="true">  
         <sloc:href>
            <sloc:hrefPathPrefix>/search</sloc:hrefPathPrefix>
            <sloc:static href="http://myserver.example.com:9081" ssl_href="https://myserver.example.com:9444"/>
            <sloc:interService href="https://myserver:9444"/>
         </sloc:href>
         <!-- Add third Party Search Options here -->
         <sloc:searchScope scopeName="Yahoo" enabled="true" isGlobal="true">
            <sloc:searchApplicationURL>
               <sloc:static href="http://search.yahoo.com/search?q=" ssl_href="https://search.yahoo.com/search?q="/>
            </sloc:searchApplicationURL>
            <sloc:searchScopeIconClass>lconnSprite lconnSprite-iconThirdParty16</sloc:searchScopeIconClass>
         </sloc:searchScope>
         <-- Third party Search options added-->
      </sloc:serviceReference>

      where:

      • <sloc:searchApplicationURL> defines the URL to the third-party search application. When a user selects the third-party search engine from the Search menu and enters a search term, that search query term is appended to this URL.

          Ensure that the URL that you define will use the search query terms that are passed to the URL. Pointing to a base URL, such as www.yahoo.com, does not work. Refer to the external documentation for the third-party search engine to find the correct URL to use. For example, the correct URL for searching using the Yahoo search engine is "http://search.yahoo.com/search?q=".

      • <sloc:searchScopeIconClass> specifies the CSS class for an icon that identifies the third-party search option in the Search drop-down menu. The value of <sloc:searchScopeIconClass> must always be set to lconnSprite lconnSprite-iconThirdParty16.

      For the new search engine to display in the search control, ensure that the enabled parameter is set to true for the <sloc:serviceReference> and <sloc:searchScope> elements. The isGlobal parameter for the <sloc:searchScope> element must also be set to true.

      1. To point to a Search option that is locally available on the same URL as the IBM Connections server, use the <sloc:hrefPathPrefix> tag instead of the <sloc:href> tag.

          For example:

          <sloc:searchScope scopeName="myPlaces" enabled="true" isGlobal="false">
             <sloc:searchApplicationURL>
                <sloc:hrefPathPrefix>places?scope=myPlaces&query=</sloc:hrefPathPrefix>
             </sloc:searchApplicationURL>
             <sloc:searchScopeIconClass>lconnSprite lconnSprite-iconThirdParty16</sloc:searchScopeIconClass>
          </sloc:searchScope>

          Note: In this case the isGlobal parameter is set to false because the example is for a local search.

  4. Save your changes and then close the LotusConnections-config.xml file.

  5. After making changes, check the configuration files back in, and do so during the same wsadmin session in which you checked them out for the changes to take effect. See Apply common configuration property changes for information about how to apply your changes.


Parent topic

Administer Search


Related tasks


Apply common configuration property changes


   

 

});

+

Search Tips   |   Advanced Search