I have a perl script that parses an index for search results.<br><br>Is there a way to make the script make a call to two separate indices and display the results as one search. I want to avoid merging the indices, but instead want to have a divider between the two sets of results. ( I have done this with another script, but this one eludes me.)<br><br><br>The script:<br><br><br>#!/usr/local/bin/perl<br><br># REQUIRED<br><br># Firstly check the path to PERL executable in the first line of the script.<br><br>$swish_path = '/path/to/swish-e'; # path to SWISH executable<br><br><br># You should carefully set configuration options in your `swish.conf' file.<br># Search imports `IndexName' and `IndexPointer' values and<br># its behaviour considerably depends on `ReplaceRules' settings.<br><br>#################################################################################<br><br># YOUR CHOICE<br><br>%form = ( 'ipath', '/path/index.swish');#default `Search path'<br><br><br>$bgcolor = '"#ffffff"'; # background color<br>$textcolor = 'black'; # text color on `bgcolor' background<br>$atextcolor = 'white'; # text color on `linkcolor' background and<br> # activ link color<br>$headercolor = 'maroon'; # headers color<br>$linkcolor = 'blue'; # links color and alternate background<br>$alinkcolor = 'lime'; # links color on `linkcolor' background<br>$vlinkcolor = 'navy'; # visited links color<br><br>#################################################################################<br><br># YOU SHOULD NOT ALTER THE REST OF THE SCRIPT<br><br>read( STDIN, $buffer, $ENV{ 'CONTENT_LENGTH' } );<br>@pairs = split( /&/, $buffer );<br><br>foreach $pair( @pairs )<br>{<br> ( $name, $value ) = split( /=/, $pair );<br><br> $value =~ tr/+/ /;<br> $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C",hex($1))/eg;<br><br> $form{ $name } = $value;<br>}<br><br>open( RES, ( $form{ 'terms' } ) ?<br> "$swish_path -f $form{ 'ipath' } -m 50 -t HBthe -w $form{ 'terms' } ¦" :<br> "$swish_path -f $form{ 'ipath' } -m 1 -w 0 ¦" );<br><br>_1: while( <RES> )<br>{<br> $Name = $1 if /^# Name: (.*)$/o;<br> $Pointer = $1 if /^# Pointer: (.*)$/o;<br> last _1 if defined( $Name ) && defined( $Pointer );<br> $error = $1 if /^err: (.*)$/o;<br> $error = 'Invalid search words' if /^options:/o;<br>}<br><br>$hc = "FONT COLOR=$headercolor";<br>$atc = "FONT COLOR=$atextcolor";<br>$alc = "FONT COLOR=$alinkcolor";<br><br>$_ = <<EOP;<br>Content-type: text/html<br><br><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN"><br><html><br><br><head><br><title></title><br></head><br></head><br><table border="0" cellpadding="0" cellspacing="0" width="100%"><br> <tr><br> <td width="50%" valign="top"><img SRC="<A HREF=" TARGET="_new"> ALT=" " width="442" height="103" BORDER="0"><br> </td><br> <td width="50%" style="padding-left: 0" bordercolor="#808080"><br> <p align="center"><font size="5"><b><i><br><br> </i></b></font><b><font face="Arial">Tell Your Suppliers You Found Them on<br> PetroPages</font></b></td><br> </tr><br></table><br><br>EOP<br><br>s/VALUE=.$form{ 'ipath' }./$& CHECKED/o;<br>s/VALUE=.$form2{ 'ipath' }./$& CHECKED/o;<br>print;<br><br>if( $error )<br>{<br> print "<BR><$hc><B>Error:</B> $error<BR><BR><BR>\n";<br>}<br>elsif( $form{ 'terms' } )<br>{<br> print "<BR><$hc><B>Documents found:</B> <SMALL>(red <FONT COLOR=red>¶</FONT> sign shows confidence in the match, best match first)</SMALL><BR><BR>\n";<br><br> while( <RES> )<br> {<br> print "<FONT SIZE=\"+0\" COLOR=\"".( $1 > 99 ? 'red' : 'black' ).<br> "\"><B>¶</B></FONT> <A HREF=\"$2\">$3</A> <BR>"<br> if /^([0-9]*) +([^ ]*) +.([^\"]*). +([0-9]*)/o;<br> print "No documents found<BR>\n" if /^err/o;<br> }<br> print "<BR>\n";<br>}<br>else<br>{<br> print <<EOP;<br> <UL><br>EOP<br>}<br><br>print <<EOP;<br><p align="left"><br><br>*<br><br><br><br><table border="0" cellpadding="0" cellspacing="0" width="100%"><br> <tr><br> <td width="100%" colspan="2"><font color="maroon" face="Arial">TEXT Display:</font> </td><br> </tr><br> </table><br> <br> <br> <br> <table><br> <tr><br> <td width="50%"><form METHOD="POST" ACTION="<A HREF=" TARGET="_new"> TYPE="text"<br> NAME="terms" SIZE="21" VALUE><input TYPE="submit" VALUE=" Product Categories "<br> ALIGN="top"<br> style="background-color: #000000; color: #FFFFFF; font-family: sans-serif; font-size: 10pt; font-weight: normal; background-image: url('/images/DoSearch.jpg')"><input TYPE="text"<br> NAME="terms" SIZE="21" VALUE><font COLOR="blue"><input TYPE="submit" VALUE=" Product Categories "<br> ALIGN="top"<br> style="background-color: #000000; color: #FFFFFF; font-family: sans-serif; font-size: 10pt; font-weight: normal; background-image: url('/images/DoSearch.jpg')"></td> <br> </tr><br></table><br><br><br>EOP<br><br>__END__<br>