Melly has asked for the wisdom of the Perl Monks concerning the following question:
The error looks like this:use strict; use CGI qw/:all/; my $thumbs_url='./pics/thumbs/'; my $images_url='./pics/'; my @files; my $file; # main prog get_list(); print_thumbs(); exit; # subroutines sub get_list{ @files = glob("../pics/*.jpg"); } sub print_thumbs{ for(my $n = 0; $n < @files; $n++){ $files[$n] =~ /.*\/(.*)(\..*)/; $file = $1 . $2; print h3($1) . "\n"; print a( {-href => "$images_url" . $file}, img({-src => "$thumbs_url" . $file, -alt => $file, -border => "0 +"}) ); print "\n" . p($1) . "\n"; } }
Tom Melly, tom@tomandlu.co.uk<h3>sand1</h3> <a href="./pics/sand1.jpg"><img alt="sand1.jpg" border="0" src="./pics +/thumbs/sand1.jpg" /></a> <p>sand1</p> (note the /> at the end of the img tag)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: CGI IMG tag error
by bikeNomad (Priest) on Jun 08, 2001 at 19:14 UTC | |
by Abigail (Deacon) on Jun 08, 2001 at 23:58 UTC | |
|
(boo)Re: CGI IMG tag error
by boo_radley (Parson) on Jun 08, 2001 at 19:14 UTC | |
by briac (Sexton) on Jun 08, 2001 at 19:33 UTC | |
by Melly (Chaplain) on Jun 08, 2001 at 19:19 UTC | |
by arturo (Vicar) on Jun 09, 2001 at 19:07 UTC | |
by RatArsed (Monk) on Jun 11, 2001 at 13:22 UTC | |
|
Re: CGI IMG tag error
by marcink (Monk) on Jun 08, 2001 at 19:16 UTC | |
|
Re: CGI IMG tag error
by Anonymous Monk on Jun 09, 2001 at 05:27 UTC |