Skip to main content.
home | support | download

Back to List Archive

Re: Getting link to pages right in swish.cgi

From: Roy Tennant <roy.tennant(at)not-real.ucop.edu>
Date: Wed Jan 15 2003 - 16:38:12 GMT
I believe what you want is this (a config file directive):

http://swish-e.org/current/docs/SWISH-CONFIG.html#item_ReplaceRules

Roy

On Wednesday, January 15, 2003, at 08:16 AM, John Almberg wrote:

> I've got swish.cgi working (very cool.) One problem: the links to the
> pages included the directory path info, like this:
>
> http://www.mywebsite.com/home/mydir/public_html/index.com.
>
> This obviously doesn't work.  I kludged a fix:
>
>            my $docpath = $h{swishdocpath};
>            $docpath =~ s/\s/%20/g;  # Replace spaces
>            $docpath =~ s|home/mydir/public_html/||g;  # Remove
> /home/mydir/public_html from link
>            $h{swishdocpath_href} = ( $self->config('prepend_path') || 
> ''
> ) . $docpath;
>
> but suspect there is a more elegant way to do this! Any hints?
>
> -- John
>
>
Received on Wed Jan 15 16:38:35 2003