|
|
|
|
|
|
|
|
|
|
|
|
|
|
PROGRAMMING POWER
Extend the reach of your IWWCM search, Part 2
By Colin Neale
Last week (in http://www.dominopower.com/issues/issue200509/00001643001.html), I demonstrated how I used my own C-Search program to extend IWWCM search capabilities beyond it's own publishing database without the need to develop search routines inside IWWCM itself.
Last week, I showed you how to load Web content and configure IWWCM indexing, configure Web Reports indexing, and create the search forms. In this article, I'll show you how to render the search forms and search results.
As with last week's article, I'm assuming that you are familiar with IWWCM for Domino and the basics of JavaScript and Domino search techniques.
Render the Search forms The search forms added to C-Search earlier required rendering through the Web site framework. This was accomplished by creating a page layout "Search". This was based on the "2 Pane Layout" that is supplied with IWWCM.
Next, I created a page style "Search". This was assigned it to the "Search" page layout.
Finally I created a web content page named "Search" and added the following code to the body of the document.
<IFRAME ID="search" SRC="/C-Search.nsf/Search?OpenForm" NAME="search" width="659" height="381" align="right" MARGINHEIGHT="0" MARGINWIDTH="0" FRAMEBORDER="0" SCROLLING="No" NORESIZE="TRUE"></IFRAME>
|
The code here uses an inline frame to display the "Search" form from C-Search in the IWWCM search page as shown in Figure A below:
FIGURE A
 
Here, the C-Search form is rendered in IWWCM. Roll over picture for a larger image.
,H1 Render the search results
The final task was to set up the site to display the results of a search. This was achieved by creating a page layout called "Search Results". As before, this was based on the "2 Pane Layout" supplied with IWWCM. In this layout, I added the following to the "Pre-Body Component" block:
<IFRAME ID="searchresults" SRC='[CGI:IndexDb]&Query=[CGI:Query]' WIDTH="685" HEIGHT="350" NAME="searchresults" FRAMEBORDER="0" NORESIZE="TRUE" SCROLLING="yes">
|
and the following to the "Post-Body Component" block:
The code above renders C-Search results in an IWWCM content page on the Web site. This is achieved with IWWCM's [CGI] tag. This tag allows IWWCM to extract CGI variables from the URL string of loaded content. This tag was the key to allowing straightforward integration between IWWCM and C-Search.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
-- Advertisement --
Sophisticated Meets Simple For Document Management
Share. Control. Manage.
Documents, emails, and content in the context of how work is done.
Native to Lotus Domino. The User Experience unseen for Lotus Domino.
Do more with less. Really.
See the possibilities Docova unleashes for Lotus Domino. |
-- Advertisement --
Mark your calendar for in-depth Lotus training, May 12-14, Boston
Join experts and peers May 12-14 in Boston for educational and networking events that deliver real-world Lotus training so you can increase productivity and efficiency in your company, advance your skills, and squeeze the most from your current environment. One registration gets you into THE VIEW's Admin2010 and Lotus Developer2010.
Register by April 10 to save $200. |
|
|
|
|
|
|
|
|
|
|