Scoop -- the swiss army chainsaw of content management
Front Page · Everything · News · Code · Help! · Wishlist · Project · Scoop Sites · Dev Notes · Latest CVS changes · Development Activities
Scoop Box Exchange - Show Box: song_list 1.00

Author: bittondb [Info]

Description:

creates .m3u song list from file system and query submitted from song_search box

Box Code:

use File::Find;

my $content;
my $search = $S->cgi->param('song');
my $list = $S->cgi->param('list');
my $re = qr/$search/i;

if ($list) {
$S->apache->content_type("audio/m3u");
$S->apache->header_out('Content-Disposition' => "attachment; filename=list.m3u");
}

find( \&getmp3, "/var/mp3/");

sub getmp3 {
if(/$search/)
{
my $name = $File::Find::name;
$name =~ s/\/var\/mp3/\/tunes/;
$content .= "http:\/\/www.codenoevil.com" . $name . "\n";
}
}

return '' unless $content;
return $content;
Display: Sort:
Menu
· create account
· faq
· search
· report bugs
· Scoop Administrators Guide
· Scoop Box Exchange

Scoop Site Scroller: Get one yourself!
Smokedot
It's 4:19... do you know where your bong is?

Login
Make a new account
Username:
Password:

Hosted by ScoopHost.com Powered by Scoop
All trademarks and copyrights on this page are owned by their respective companies. Comments are owned by the Poster. The Rest © 1999 The Management

create account | faq | search