Файл: users/profile/tape/components/user_music.php
Строк: 22
<?php
$music = DB::GET_STRING("SELECT `ID`,`NAME`,`ARTIST`,`USER_ID`,`ID_DIR` FROM `MUSIC` WHERE `ID` = '".$list['OBJECT_ID']."' LIMIT 1");
$account = DB::GET_STRING("SELECT `ID`,`SEX` FROM `USERS` WHERE `ID` = '".$list['OBJECT_ID_LIST']."' LIMIT 1");
$dir = DB::GET_STRING("SELECT `ID`,`NAME` FROM `MUSIC_DIR` WHERE `ID` = '".$music['ID_DIR']."' LIMIT 1");
USER::LOGIN($account['ID'], 1, 1);
IF (ISSET($dir['ID'])){
$dir_link = "<a href='/modules/?path=music§ion=users&id=".$music['USER_ID']."&dir=".$dir['ID']."'>".TEXT_ABSOLUTE($dir['NAME'])."</a>";
}ELSE{
$dir_link = "<a href='/modules/?path=music§ion=users&id=".$music['USER_ID']."'>".LG('Без альбома')."</a>";
}
IF ($account['SEX'] == 2){
ECHO " ".LG('добавила музыку в свой альбом').": ".$dir_link."";
}ELSE{
ECHO " ".LG('добавил музыку в свой альбом').": ".$dir_link."";
}
ECHO "<br /><span class='time'>".STIME($list['TIME'])."</span></br /></br />";
IF (!ISSET($music['ID'])){
ECHO "<font color='red'>".LG('Объект был удален')."</font>";
}ELSE{
ECHO "<table style='width: 100%;'><tr>";
ECHO "<td class='td-file'>";
?>
<button action="/system/AJAX/AlphaPlayer/session.php?path=<?=$music['USER_ID']?>&type=users&dir=<?=$music['ID_DIR']?>&id_music=<?=$music['ID']?>" id="play-status<?=$music['ID']?>" onclick="MusicPlay(<?=$music['ID']?>)" class="play-status-off play-button-style"><i class="fa fa-play fa-fw"></i></button>
<?
ECHO FILE::ICONS('mp3');
ECHO "</td>";
ECHO "<td class='td-file2'>";
ECHO "<b>".CROP_TEXT(TEXT_ABSOLUTE($music['NAME']), 0, 38)."</b><br />";
ECHO "<font color='#686C6F'><small>".CROP_TEXT(TEXT_ABSOLUTE($music['ARTIST']), 0, 38)."</small></font><br />";
ECHO "</td>";
ECHO "</tr></table>";
}
?>