K Clark wrote:
> 
> Here's what i have, and here's the problem. and here's what i 'think' i
> have to learn/do to fix it:
> 
> #/usr/bin/perl -w
> use strict;
> #
> # script to randomly choose a song
> # and embed html with a link to it
> #
> my @mp3 = glob("/www/mp3/*.mp3");
> #
> # put while statement
> my $mp3 =~ s#.*/##;

$mp3 and @mp3 are different variables so the previous statement is doing
a substitution on an empty variable.

( my $mp3 = $mp3[rand @mp3] ) =~ s#.*/##;


> srand;
> print "http://www.quantifier.org/mp3"; . "$mp3[rand(@mp3)]";

print "http://www.quantifier.org/mp3/$mp3";;


> # end


John
-- 
use Perl;
program
fulfillment

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to