Gossamer Forum
Home : Products : Gossamer Links : Version 1.x :

SSI in a CGi script! Can someone help!

Quote Reply
SSI in a CGi script! Can someone help!
Hello.

I have this program

Code:
#!/usr/bin/perl
$num_links = 4;
print "Content-type: text/plain\n\n";
my $LASTX = $num_links;
open (DB, "<admin/data/links.db");
my @lines = <DB>;
close DB;
#setup list
print qq|
<table><UL class="mainlinks">
|;
for ($i=$#lines; $i>=$#lines - $LASTX; $i--) {
chomp $lines[$i];
@fields = split(/\|/,$lines[$i]);
#----UNFORMATTED----
#foreach $field (@fields) {print "$field\n"};
#----FORMATTED----
print '<LI><a class="side" href=http://mysite.com/';
print "@fields[3]/";
print "@fields[0]";
print ".shtml>";
print @fields[1].'</A>';
print '</LI>';
print "\n";
}
#end list
print qq|
</UL></table>
|;
now because cgi cant run in cgi i wanted to make it a global

<%hdln%>

what would be the correct procedure as to get the desired results?!

Thanks Again

Gian Wilson


Subject Author Views Date
Thread SSI in a CGi script! Can someone help! Gian 3027 Dec 28, 2000, 9:44 AM
Post Re: SSI in a CGi script! Can someone help!
pugdog 2901 Dec 28, 2000, 10:30 AM