]>
git.ipfire.org Git - people/mfischer/ipfire-2.x.git/blob - html/cgi-bin/mpfire.cgi
2 ###############################################################################
4 # IPFire.org - A linux based firewall #
5 # Copyright (C) 2007 Michael Tremer & Christian Schmidt #
7 # This program is free software: you can redistribute it and/or modify #
8 # it under the terms of the GNU General Public License as published by #
9 # the Free Software Foundation, either version 3 of the License, or #
10 # (at your option) any later version. #
12 # This program is distributed in the hope that it will be useful, #
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of #
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
15 # GNU General Public License for more details. #
17 # You should have received a copy of the GNU General Public License #
18 # along with this program. If not, see <http://www.gnu.org/licenses/>. #
20 ###############################################################################
24 # enable only the following on debugging purpose
26 #use CGI::Carp 'fatalsToBrowser';
28 # use the special mpd POD and the encode POD to handle the utf8 scalars
32 # initiate the connector for the mpd POD, mpd must be running on locahost
33 # port 6600 without authentication
34 my $mpd = Audio
::MPD
->new('localhost',6600,'','$REUSE');
35 my $work = $mpd->status()->updating_db();
37 require '/var/ipfire/general-functions.pl';
38 require "${General::swroot}/lang.pl";
39 require "${General::swroot}/header.pl";
42 my %mainsettings = ();
43 my %mpfiresettings = ();
46 my $errormessage = "";
49 &General
::readhash
("${General::swroot}/main/settings", \
%mainsettings);
50 &General
::readhash
("/srv/web/ipfire/html/themes/".$mainsettings{'THEME'}."/include/colors.txt", \
%color);
52 &Header
::showhttpheaders
();
54 if ( $ENV{'QUERY_STRING'} =~ /title/){
56 ################################################################################
57 # $ENV{'QUERY_STRING'} =~ /title/ is used to handle the inline iframe used to
58 # display the current song playing ( artist - title - album aso )
59 # the cgi call´s itself with a parameter and the iframe refreshes itself without
60 # reloading the whole page
61 ################################################################################
63 my $number = $mpd->status()->song()+1;
64 my $volume = $mpd->status()->volume();
65 my $random = $mpd->status()->random();
73 my $repeat = $mpd->status()->repeat();
81 if ( $mpd->current() )
83 $song = substr("-= ".$mpd->current()->Artist()." | ".$mpd->current()->Title(),0,85)." =-<br /> ";
84 if ( $song eq "-= | =-<br /> " ){
87 $song .= $mpd->current()->Track()."# ".substr($mpd->current()->Album(),0,90)."<br />";
89 $song = "None<br /><br />";
92 if ( $song eq "None<br /># <br />" ){
93 $song = "None<br />".substr($mpd->current()->file(),0,90)."<br />"
95 $song .= "Playlist: ".$number."-".$mpd->status()->playlistlength()." Time: ".$mpd->status()->time()->sofar."/";
96 $song .= $mpd->status()->time()->total." (".$mpd->status()->time()->percent()."%) Status: ";
97 $song .= $mpd->status()->state()." Volume: ".$volume." % Repeat: ".$repeat." Random: ".$random;
100 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
101 <meta http-equiv='refresh' content='5'>
104 <table width='100%' cellspacing='0' align='center' style="background-image:url(/images/mpfire/box.png);background-repeat:no-repeat">
107 print"<tr ><td align='center'><font color='red' face='Verdana' size='2'><br />".encode
('utf-8', $song)."<br /><br /></font></td></tr></table></body>";
109 }elsif ( $ENV{'QUERY_STRING'} =~ /control/){
111 ################################################################################
112 # $ENV{'QUERY_STRING'} =~ /control/ is used to handle the inline iframe used to
113 # display the control button ( prev play skip stop toggle aso )
114 # the cgi call´s itself with a parameter and only the iframe is reloaded on click
115 ################################################################################
117 &Header
::getcgihash
(\
%mpfiresettings);
118 if ( $mpfiresettings{'ACTION'} eq "playall" ){
119 $mpd->playlist->clear();
120 foreach ($mpd->collection->all_pathes){
121 $mpd->playlist->add($_);
124 }elsif ($mpfiresettings{'ACTION'} eq "x" ){
126 }elsif ( $mpfiresettings{'ACTION'} eq "|>" ){
128 }elsif ( $mpfiresettings{'ACTION'} eq "<<" ){
130 }elsif ( $mpfiresettings{'ACTION'} eq ">>" ){
132 }elsif ( $mpfiresettings{'ACTION'} eq "+" ){
134 }elsif ( $mpfiresettings{'ACTION'} eq "-" ){
136 }elsif ( $mpfiresettings{'ACTION'} eq "++" ){
138 }elsif ( $mpfiresettings{'ACTION'} eq "--" ){
140 }elsif ( $mpfiresettings{'ACTION'} eq ">" ){
142 }elsif ( $mpfiresettings{'ACTION'} eq "repeat" ){
144 }elsif ( $mpfiresettings{'ACTION'} eq "shuffle" ){
148 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
151 <table width='95%' cellspacing='0'>
153 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='<<' /><input type='image' alt='$Lang::tr{'prev'}' title='$Lang::tr{'prev'}' src='/images/media-skip-backward.png' /></form></td>
154 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='x' /><input type='image' alt='$Lang::tr{'stop'}' title='$Lang::tr{'stop'}' src='/images/media-playback-stop.png' /></form></td>
155 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='|>' /><input type='image' alt='$Lang::tr{'toggle'}' title='$Lang::tr{'toggle'}' src='/images/media-resume.png' /></form></td>
156 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='>' /><input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' /></form></td>
157 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='playall' /><input type='image' alt='$Lang::tr{'play'} all' title='$Lang::tr{'play'} all' src='/images/media-playback-start-all.png' /></form></td>
158 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='>>' /><input type='image' alt='$Lang::tr{'next'}' title='$Lang::tr{'next'}' src='/images/media-skip-forward.png' /></form></td>
164 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='repeat' /><input type='image' alt='$Lang::tr{'repeat'}' title='$Lang::tr{'repeat'}' src='/images/media-repeat.png' /></form></td>
165 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='--' /><input type='image' alt='$Lang::tr{'voldown10'}' title='$Lang::tr{'voldown10'}' src='/images/audio-volume-low-red.png' /></form></td>
166 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='-' /><input type='image' alt='$Lang::tr{'voldown5'}' title='$Lang::tr{'voldown5'}' src='/images/audio-volume-low.png' /></form></td>
167 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='+' /><input type='image' alt='$Lang::tr{'volup5'}' title='$Lang::tr{'volup5'}' src='/images/audio-volume-high.png' /></form></td>
168 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='++' /><input type='image' alt='$Lang::tr{'volup10'}' title='$Lang::tr{'volup10'}' src='/images/audio-volume-high-red.png' /></form></td>
169 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}?control'><input type='hidden' name='ACTION' value='shuffle' /><input type='image' alt='$Lang::tr{'shuffle'}' title='$Lang::tr{'shuffle'}' src='/images/media-shuffle.png' /></form></td>
178 # just a little subpage to handle automatic page refresh on demand ( 1 sec )
180 &Header
::openbox
( 'Waiting', 1, "<meta http-equiv='refresh' content='1;' />" );
181 print "<center><img src='/images/clock.gif' alt='' /><br/><font color='red'>$Lang::tr{'pagerefresh'}</font></center>";
185 # if the mpd is updating his database because of user interaction then the cgi
186 # should display that the mpd is unavailable, and refresh the status every 5 seconds
188 &Header
::openpage
($Lang::tr
{'mpfire'}, 1,);
189 &Header
::openbigbox
('100%', 'left', '', $errormessage);
190 &Header
::openbox
( 'Waiting', 5, "<meta http-equiv='refresh' content='5;' />" );
191 print "<center><img src='/images/clock.gif' alt='' /><br/><font color='red'>Database is updating, please be patient.</font></center>";
193 &Header
::closebigbox
();
194 &Header
::closepage
();
198 if ( $mpfiresettings{'PAGE'} eq "" ){$mpfiresettings{'PAGE'} = "1";}
200 &Header
::getcgihash
(\
%mpfiresettings);
201 &Header
::openpage
($Lang::tr
{'mpfire'}, 1,);
202 &Header
::openbigbox
('100%', 'left', '', $errormessage);
204 ############################################################################################################################
205 ######################################## Scanne Verzeichnisse nach Mp3 Dateien #############################################
207 if ( $mpfiresettings{'ACTION'} eq "scan" ){
209 # on keypress scan the given directory and store the path to the mpd config
210 &General
::readhash
("${General::swroot}/mpfire/settings", \
%mpfiresettings);
211 &Header
::getcgihash
(\
%mpfiresettings);
212 delete $mpfiresettings{'__CGI__'};delete $mpfiresettings{'x'};delete $mpfiresettings{'y'};
213 &General
::writehash
("${General::swroot}/mpfire/settings", \
%mpfiresettings);
215 open(DATEI
, "<${General::swroot}/mpfire/mpd.conf") || die "Datei nicht gefunden";
216 my @Zeilen = <DATEI
>;
219 open(DATEI
, ">${General::swroot}/mpfire/mpd.conf") || die "Datei nicht gefunden";
221 if ( $_ =~ /music_directory/){
222 print DATEI
"music_directory \"".$mpfiresettings{'MUSICDIR'}."\"\n";
231 }elsif ( $mpfiresettings{'ACTION'} eq "playweb" ){
232 $message=system("/usr/local/bin/mpfirectrl","playweb","\"$mpfiresettings{'FILE'}\"","2>/dev/null");
233 }elsif ( $mpfiresettings{'ACTION'} eq "playlist" ){
235 }elsif ( $mpfiresettings{'ACTION'} eq "emptyplaylist" ){
236 # on keypress clear the playlist
237 $mpd->playlist->clear();
238 }elsif ( $mpfiresettings{'ACTION'} eq "addtoplaylist" ){
239 $mpd->playlist->add($mpfiresettings{'FILE'});
240 }elsif ( $mpfiresettings{'ACTION'} eq "playalbum" ){
241 # on keypress play the selected albums
242 my @select = split(/\|/,$mpfiresettings{'album'});
243 $mpd->playlist->clear();
245 foreach ($mpd->collection->filenames_by_album($_)){
247 $mpd->playlist->add($_);
252 }elsif ( $mpfiresettings{'ACTION'} eq "playartist" ){
253 # on keypress play the selected artist
254 my @select = split(/\|/,$mpfiresettings{'artist'});
255 $mpd->playlist->clear();
257 foreach ($mpd->collection->filenames_by_artist($_)){
259 $mpd->playlist->add($_);
264 }elsif ( $mpfiresettings{'ACTION'} eq "playyear" ){
265 # on keypress play the selected year
266 my @select = split(/\|/,$mpfiresettings{'year'});
267 $mpd->playlist->clear();
269 foreach ($mpd->collection->filenames_by_year($_)){
271 $mpd->playlist->add($_);
276 }elsif ( $mpfiresettings{'ACTION'} eq "playgenre" ){
277 # on keypress play the selected genre
278 my @select = split(/\|/,$mpfiresettings{'genre'});
279 $mpd->playlist->clear();
281 foreach ($mpd->collection->filenames_by_genre($_)){
283 $mpd->playlist->add($_);
288 }elsif ( $mpfiresettings{'ACTION'} eq ">" ){
289 $mpd->playlist->clear();
290 $mpd->playlist->add($mpfiresettings{'FILE'});
294 if ( $mpfiresettings{'SEARCH'} eq "artist" && $mpfiresettings{'SEARCHITEM'} ne "" ){
295 foreach ($mpd->collection->songs_with_artist_partial_filename($mpfiresettings{'SEARCHITEM'})){
300 }elsif ( $mpfiresettings{'SEARCH'} eq "title" && $mpfiresettings{'SEARCHITEM'} ne "" ){
301 foreach ($mpd->collection->songs_with_title_partial_filename($mpfiresettings{'SEARCHITEM'})){
306 }elsif ( $mpfiresettings{'SEARCH'} eq "album" && $mpfiresettings{'SEARCHITEM'} ne "" ){
307 foreach ($mpd->collection->songs_with_album_partial_filename($mpfiresettings{'SEARCHITEM'})){
313 @songs = $mpd->collection->all_items_simple();
317 ############################################################################################################################
318 ################################### Aufbau der HTML Seite fr globale Sambaeinstellungen ####################################
320 $mpfiresettings{'MUSICDIR'} = "/";
321 &General
::readhash
("${General::swroot}/mpfire/settings", \
%mpfiresettings);
323 ############################################################################################################################
324 ########################################### rekursiv nach neuen Mp3s Scannen ##############################################ä
326 if ( $message ne '0' ){
327 print "<font color='red'>An Error occured while launching the command</font>";
328 }elsif ( $message ne "" && $message ne '0' ){
329 print "<font color='red'>$message</font>";
332 &Header
::openbox
('100%', 'center', $Lang::tr
{'mpfire scanning'});
333 # box to enter the music directory and initiate the scan process
335 <form method='post' action='$ENV{'SCRIPT_NAME'}'>
336 <table width='95%' cellspacing='0'>
337 <tr bgcolor='$color{'color20'}'><td colspan='2' align='left'><b>$Lang::tr{'Scan for Files'}</b></td></tr>
338 <tr><td align='left' width='40%'>$Lang::tr{'Scan from Directory'}</td><td align='left'><input type='text' name='MUSICDIR' value='$mpfiresettings{'MUSICDIR'}' size="50" /></td></tr>
339 <tr><td align='center' colspan='2'><input type='hidden' name='ACTION' value='scan' /><input type='image' alt='$Lang::tr{'Scan for Files'}' title='$Lang::tr{'Scan for Files'}' src='/images/edit-find.png' /></td></tr>
346 &Header
::openbox
('100%', 'center', $Lang::tr
{'mpfire controls'});
347 # box for the two iframes showing the current playbar and the control buttons
349 <iframe height='85' width='685' src='/cgi-bin/mpfire.cgi?title' scrolling='no' frameborder='no' marginheight='0'></iframe>
350 <iframe height='50' width='685' src='/cgi-bin/mpfire.cgi?control' scrolling='no' frameborder='no' marginheight='0'></iframe>
353 print "<b>Songs:".$mpd->stats()->songs()."</b><br />";
357 &Header
::openbox
('100%', 'center', $Lang::tr
{'quick playlist'});
358 # box to quickly select artist, album, year or genre and play the selection
359 print "<table width='95%' cellspacing='0'>";
360 print "<tr><td align='center' bgcolor='$color{'color20'}'><b>$Lang::tr{'artist'} - ".$mpd->stats()->artists()."</b></td><td align='center' bgcolor='$color{'color20'}'><b>$Lang::tr{'album'} - ".$mpd->stats()->albums()."</b></td></tr>";
363 <tr><td align='center'>
364 <form method='post' action='$ENV{'SCRIPT_NAME'}'>
365 <select name='artist' size='8' multiple='multiple' style='width:300px;'>
369 foreach (sort($mpd->collection->all_artists())){
371 print "<option>".encode
('utf-8', $_)."</option>\n";
377 <input type='hidden' name='ACTION' value='playartist' />
378 <input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' />
381 <form method='post' action='$ENV{'SCRIPT_NAME'}'>
382 <select name='album' size='8' multiple='multiple' style='width:300px;'>
386 foreach (sort($mpd->collection->all_albums())){
388 print "<option>".encode
('utf-8', $_)."</option>\n";
394 <input type='hidden' name='ACTION' value='playalbum' />
395 <input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' />
398 <tr><td align='center' bgcolor='$color{'color20'}'><b>$Lang::tr{'year'}</b></td><td align='center' bgcolor='$color{'color20'}'><b>$Lang::tr{'genre'}</b></td></tr>
399 <tr><td align='center'>
400 <form method='post' action='$ENV{'SCRIPT_NAME'}'>
401 <select name='year' size='8' multiple='multiple' style='width:300px;'>
405 foreach (sort($mpd->collection->all_years())){
407 print "<option>$_</option>\n";
413 <input type='hidden' name='ACTION' value='playyear' />
414 <input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' />
417 <form method='post' action='$ENV{'SCRIPT_NAME'}'>
418 <select name='genre' size='8' multiple='multiple' style='width:300px;'>
422 foreach (sort($mpd->collection->all_genre())){
424 print "<option>$_</option>\n";
430 <input type='hidden' name='ACTION' value='playgenre' />
431 <input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' />
439 &Header
::openbox
('100%', 'center', $Lang::tr
{'mpfire search'});
440 # box to quickly search artist, album or title
442 <form method='post' action='$ENV{'SCRIPT_NAME'}#$Lang::tr{'mpfire songs'}'>
443 <table width='95%' cellspacing='0'>
445 <td align='right' width='33%'>$Lang::tr{'artist'}</td>
446 <td align='center' width='33%'>$Lang::tr{'title'}</td>
447 <td align='left' width='33%'>$Lang::tr{'album'}</td>
450 <td align='right' width='33%'><input type='radio' name='SEARCH' value='artist' /></td>
451 <td align='center' width='33%'><input type='radio' name='SEARCH' value='title' checked='checked' /></td>
452 <td align='left' width='33%'><input type='radio' name='SEARCH' value='album' /></td>
455 <td align='center' colspan='3'><input type='text' name='SEARCHITEM' value='$mpfiresettings{'SEARCHITEM'}' size="50" /></td>
458 <td align='center' colspan='3'><input type='hidden' name='ACTION' value='search' /><input type='image' alt='$Lang::tr{'Scan for Songs'}' title='$Lang::tr{'Scan for Songs'}' src='/images/edit-find.png' /></td>
466 &Header
::openbox
('100%', 'center', $Lang::tr
{'mpfire songs'});
468 <a id='$Lang::tr{'mpfire songs'}' name='$Lang::tr{'mpfire songs'}'></a>
469 <table width='95%' cellspacing='3'>
470 <tr bgcolor='$color{'color20'}'><td colspan='4' align='left'><b>$Lang::tr{'Existing Files'}</b></td></tr>
473 if ( $#songs > 100 ){
474 print "<tr><td align='center' colspan='4'><br/>$Lang::tr{'Pages'}<br/><form method='post' action='$ENV{'SCRIPT_NAME'}'><input type='submit' name='PAGE' value='all' /><br/>";
475 my $pages =(int($#songs/100)+1);
476 for(my $i = 1; $i <= $pages; $i++){
477 print "<input type='submit' name='PAGE' value='$i' />";
483 print "</form></td></tr>";
486 <tr><td align='center'></td>
487 <td align='center'><b>$Lang::tr{'artist'}<br/>$Lang::tr{'title'}</b></td>
488 <td align='center'><b>$Lang::tr{'number'}</b></td>
489 <td align='center'><b>$Lang::tr{'album'}</b></td>
493 my $lines=0;my $i=0;my $begin;my $end;
494 if ( $mpfiresettings{'PAGE'} eq 'all' ){
498 $begin=(($mpfiresettings{'PAGE'}-1) * 100);
499 $end=(($mpfiresettings{'PAGE'} * 100)-1);
502 if (!($i >= $begin && $i <= $end)){
503 #print $begin."->".$i."<-".$end."\n";
506 my @song = split(/\=/,$mpd->collection->song($_));
507 @song = reverse @song;
510 print "<tr bgcolor='$color{'color20'}'>";
512 print "<tr bgcolor='$color{'color22'}'>";
515 <td align='center' style="white-space:nowrap;">
516 <form method='post' action='$ENV{'SCRIPT_NAME'}#$Lang::tr{'mpfire songs'}'>
517 <input type='hidden' name='ACTION' value='addtoplaylist' />
518 <input type='hidden' name='FILE' value="$_" />
519 <input type='hidden' name='PAGE' value='$mpfiresettings{'PAGE'}' />
520 <input type='hidden' name='SEARCH' value='$mpfiresettings{'SEARCH'}' />
521 <input type='hidden' name='SEARCHITEM' value='$mpfiresettings{'SEARCHITEM'}' />
522 <input type='image' alt='$Lang::tr{'add'}' title='$Lang::tr{'add'}' src='/images/list-add.png' />
524 <form method='post' action='$ENV{'SCRIPT_NAME'}#$Lang::tr{'mpfire songs'}'>
525 <input type='hidden' name='ACTION' value='>' />
526 <input type='hidden' name='FILE' value="$_" />
527 <input type='hidden' name='PAGE' value='$mpfiresettings{'PAGE'}' />
528 <input type='hidden' name='SEARCH' value='$mpfiresettings{'SEARCH'}' />
529 <input type='hidden' name='SEARCHITEM' value='$mpfiresettings{'SEARCHITEM'}' />
530 <input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' />
535 print "<td align='center'>".encode
('utf-8', $song[0])."<br/>".encode
('utf-8', $song[1])."</td>";
536 print "<td align='center'>".encode
('utf-8', $song[2])."</td>";
537 print "<td align='center'>".encode
('utf-8', $song[3])."</td>";
545 &Header
::openbox
('100%', 'center', $Lang::tr
{'mpfire playlist'});
546 # box to show the current playlist given from mpc system command
547 my @playlist = `mpc playlist 2>/dev/null`;
550 <table width='95%' cellspacing='0'>
551 <tr bgcolor='$color{'color20'}'><td colspan='2' align='left'><b>$Lang::tr{'current playlist'}</b></td></tr>
552 <tr><td align='center' colspan='2' ><textarea cols='100' rows='10' name='playlist' style='font-size:11px;width:650px;' readonly='readonly'>
557 $_=~s/&/&\;/g;;print $_;
561 </textarea></td></tr><tr>
563 <form method='post' action='$ENV{'SCRIPT_NAME'}'>
564 <input type='hidden' name='ACTION' value='emptyplaylist' />
565 <input type='image' alt='$Lang::tr{'clear playlist'}' title='$Lang::tr{'clear playlist'}' src='/images/user-trash.png' />
569 <form method='post' action='$ENV{'SCRIPT_NAME'}'>
570 <input type='hidden' name='ACTION' value='playlist' />
571 <input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' />
580 &Header
::openbox
('100%', 'center', $Lang::tr
{'mpfire webradio'});
581 # box to select some webradio´s to be played by one click
582 open(DATEI
, "<${General::swroot}/mpfire/webradio") || die "Could not open playlist";
583 my @webradio = <DATEI
>;
587 <table width='95%' cellspacing='0'>
588 <tr bgcolor='$color{'color20'}'><td colspan='9' align='left'><b>$Lang::tr{'webradio playlist'}</b></td></tr>
589 <tr><td align='left'>Stream</td><td colspan='2'></td></tr>
595 my @stream = split(/\|/,$_);
599 print "<tr bgcolor='$color{'color22'}'>";
603 chomp $stream[1];chomp $stream[2];
605 <td align='left'><a href='$stream[2]' target='_blank'>$stream[1]</a></td>
606 <td align='center'><form method='post' action='$ENV{'SCRIPT_NAME'}'><input type='hidden' name='FILE' value='$stream[0]' /><input type='hidden' name='ACTION' value='playweb' /><input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' align='middle' /></form></td>
614 print "<tr bgcolor='$color{'color22'}'>";
620 <td align='center' colspan='2'><form method='post' action='$ENV{'SCRIPT_NAME'}'><br />http://<input type=text name='FILE' value='www.meineradiourl:1234' size='75' />
621 <input type='hidden' name='ACTION' value='playweb' /><input type='image' alt='$Lang::tr{'play'}' title='$Lang::tr{'play'}' src='/images/media-playback-start.png' align='top' /></form></td>
627 &Header
::closebigbox
();
628 &Header
::closepage
();