<?php
/************************************************************************/
/* Top Music: Administration Module */
/* ================================ */
/* */
/* Copyright (c) 2004 by SergiDs.com */
/* http://phpnuke.org */
/* */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License. */
/************************************************************************/
if (!eregi("admin.php", $_SERVER['PHP_SELF'])) { die ("Access Denied"); }
$aid = trim($aid);
$result = mysql_query("select radminsuper from ".$prefix."_authors where aid='$aid'");
list($radminsuper) = mysql_fetch_row($result);
if ($radminsuper==1) {
?>
<table border="0" align="center">
<tr>
<td scope="col"> </th>
<td scope="col"> </th>
<td scope="col"> </th>
</tr>
<tr>
<th scope="col"> </th>
<th scope="col">
<?php if($artistO->name!=""){
print _TOPMUSIC_ALBUMLISTOF.':'.$artistO->name;
} else {
print _TOPMUSIC_ORPHANALBUMS;
}?>
</th>
<th scope="col"> </th>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
</tr>
<tr>
<td> </td>
<td>
<table width="100%" border="0">
<tr>
<td scope="col" align="center">
<?php if($artistO->photo_file){ ?>
<img name="foto" src="modules/<?=_TOPMUSIC_MODULENAME?>/photos/<?=$artistO->photo_file?>" width="79" alt="<?=$artistO->name?>"></th>
<?php }elseif($artistO->photo){ ?>
<img name="foto" src="<?=$artistO->photo?>" width="79" alt="<?=$artistO->name?>"></th>
<?php }else{ ?>
<img name="foto" src="modules/<?=_TOPMUSIC_MODULENAME?>/photos/anonym.jpg" width="79" alt="<?=$artistO->name?>"></th>
<?php } ?>
<td scope="col">
<table border="0">
<form name="artistForm" id="artistForm" method="POST" action="admin.php?op=topmusic&action=listAlbum&idartist=<?=$artist?>">
<tr>
<td><strong><?=_TOPMUSIC_NAME?></strong>:</td>
<td>
<?php
$genericView=new GenericAdminView();
$temp_arr[0][0]="";
$temp_arr[0][1]=_TOPMUSIC_ORPHANALBUMS;
$artistList=array_merge($temp_arr,$artistList);
$genericView->printSelect("artist",$artistList,$artist,"document.getElementById('artistForm').action='admin.php?op=topmusic&action=listAlbum&idartist='+document.getElementById('artistForm').artist[document.getElementById('artistForm').artist.selectedIndex].value;document.getElementById('artistForm').submit()");
?>
</td>
</tr>
<tr>
<td align="left"><strong><?=($artistO->getDeadyear()!="")?_TOPMUSIC_YEARS:_TOPMUSIC_YEAR?>:</strong></td>
<td><?=$artistO->getBornyear()?><?=($artistO->getDeadyear()!="")?" - ".$artistO->getDeadyear():""?></td>
</tr>
<tr>
<td align="left"><strong><?=_TOPMUSIC_GENRE?>:</strong></td>
<td><?=$artistO->getGenrename()?></td>
</tr>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
</form>
</table></td>
</tr>
<tr>
<td> </td>
<td><a href="#" onClick="window.open('modules/<?=_TOPMUSIC_MODULENAME?>/admin/amazon_covers.php?idartist=<?=$artistO->id?>','getAlbumCovers','width=400,height=400,scrollbars=yes,statusbar=no')"><?=_TOPMUSIC_GETMISSINGALBUMCOVERS?></a> :: <a href="#" onClick="window.open('modules/<?=_TOPMUSIC_MODULENAME?>/admin/musicmoz_searchalbum.php?idartist=<?=$artistO->id?>','getAlbumMMoz','scrollbars=yes,width=400,height=400,statusbar=no')"><?=_TOPMUSIC_GETALBUMFROM?> MusicMoz</a></td>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<?php if(count($albumList)>0){ ?>
<tr>
<td colspan="2"><strong><?=_TOPMUSIC_LISTOFALBUMS?>:</strong></td>
</tr>
<tr>
<td colspan="2">
<?php
$albumView=new AlbumAdminView();
$albumView->printAlbumList($albumList);
?>
</td>
</tr>
<?php }else{ ?>
<tr>
<td colspan="2"><strong><?=_TOPMUSIC_LISTORPHANALBUMS?>:</strong></td>
</tr>
<tr>
<td colspan="2">
<?php
$albumView=new AlbumAdminView();
$albumView->printOrphanAlbumList($orphanAlbumList);
?>
</td>
</tr>
<?php } ?>
<tr>
<td> </td>
<td> </td>
</tr>
</table></td>
<td> </td>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
<?php
} else {
OpenTable();
echo "Access Denied";
CloseTable();
}
?>