Gossamer Forum
Home : Products : Links 2.0 : Installation -- Unix :

Fatal Error on SEARCH.CGI

Quote Reply
Fatal Error on SEARCH.CGI
 
Just transfered site to new host, but the search option will no longer work. I get this error. Anyone give me a clue as to why?


CGI ERROR
==========================================
Error Message : fatal error: Undefined subroutine &main::site_html_link called at /web/sites/sharky/sexual-linkage.com/cgi-bin/links/search.cgi line 131.

Script Location : /web/sites/sharky/sexual-linkage.com/cgi-bin/links/search.cgi
Perl Version : 5.00404

Form Variables
-------------------------------------------
bool : or
humlang : 1
query : tits
submit : Search

Environment Variables
-------------------------------------------
DOCUMENT_ROOT : /web/sites/sharky/sexual-linkage.com
GATEWAY_INTERFACE : CGI/1.1
HTTP_ACCEPT : image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-comet, */*
HTTP_ACCEPT_ENCODING: gzip, deflate
HTTP_ACCEPT_LANGUAGE: en-us
HTTP_CONNECTION : Keep-Alive
HTTP_HOST : www.sexual-linkage.com
HTTP_REFERER : http://www.sexual-linkage.com/pages/
HTTP_USER_AGENT : Mozilla/4.0 (compatible; MSIE 5.5; Windows NT 5.0)
PATH : /bin:/usr/bin:/sbin:/usr/sbin
QUERY_STRING : bool=or&humlang=1&query=tits&submit=Search
REMOTE_ADDR : 209.214.4.109
REMOTE_PORT : 1143
REQUEST_METHOD : GET
REQUEST_URI : /cgi-bin/links/search.cgi?bool=or&humlang=1&query=tits&submit=Search
SCRIPT_FILENAME : /web/sites/sharky/sexual-linkage.com/cgi-bin/links/search.cgi
SCRIPT_NAME : /cgi-bin/links/search.cgi
SERVER_ADMIN : webmaster@sexual-linkage.com
SERVER_NAME : www.sexual-linkage.com
SERVER_PORT : 80
SERVER_PROTOCOL : HTTP/1.1
SERVER_SIGNATURE :
SERVER_SOFTWARE : Apache/1.3.6 (Unix)



Quote Reply
Re: Fatal Error on SEARCH.CGI In reply to
the area in the search.cgi that the error is talking about reads:

# Go through each category of links returned, and build the HTML. Store in hash %link_output.
SETOFLINKS: foreach $setoflinks (sort keys %link_results) {
my $hits = ($#{$link_results{$setoflinks}} + 1) / ($#db_cols+1);
LINK: for ($i = 0; $i < $hits; $i++) {
$link_hits++;
if (($link_hits <= $highrange) && ($link_hits >= $lowrange)) {
%tmp = &array_to_hash ($i, @{$link_results{$setoflinks}});
$link_output{$setoflinks} .= &site_html_link (%tmp) . "\n";
}
}
}



This has not been changed, and worked perfectly on my old host, so im really confused as to why i get a fatal error now.

Quote Reply
Re: Fatal Error on SEARCH.CGI In reply to
You are missing sub site_html_link in site_html_templates.pl or do not have your link.html template in the templates directory! (I think!)

From Paul Wilson.
http://www.audio-grabber.com
On error resume next..