141 lines
4.6 KiB
PHP
141 lines
4.6 KiB
PHP
<?php
|
||
|
||
/**
|
||
* This is NOT a freeware, use is subject to license terms
|
||
* 应用名称: 『凹凸曼』播放音乐 商业组件版V2.1.0
|
||
* 下载地址: https://addon.dismall.com/plugins/apoyl_music.html
|
||
* 应用开发者: 凹凸曼
|
||
* 开发者QQ: 3489214354
|
||
* 更新日期: 202505302218
|
||
* 授权域名: www.shitangsweet.com
|
||
* 授权码: 2025053014KC48S3x0sI
|
||
* 未经应用程序开发者/所有者的书面许可,不得进行反向工程、反向汇编、反向编译等,不得擅自复制、修改、链接、转载、汇编、发表、出版、发展与之有关的衍生产品、作品等
|
||
*/
|
||
|
||
/**
|
||
* [liyuanchao] (C)2019-2099 http://www.apoyl.com
|
||
* This is NOT a freeware, use is subject to license terms
|
||
*
|
||
* $Id: music.class.php 2024-07 liyuanchao(凹凸曼) $
|
||
*/
|
||
if (! defined('IN_DISCUZ')) {
|
||
exit('Access Denied');
|
||
}
|
||
|
||
class plugin_apoyl_music
|
||
{
|
||
|
||
public function global_cpnav_extra1(){
|
||
global $_G;
|
||
$re='';
|
||
$cache = $_G['cache']['plugin']['apoyl_music'];
|
||
if($cache['openportal']){
|
||
$file=$this->_fileapoylv2('portalpcmp3apoyl');
|
||
if($file)
|
||
include $file;
|
||
}
|
||
return $re;
|
||
}
|
||
|
||
public function discuzcode($value)
|
||
{
|
||
global $_G,$controslist;
|
||
$cache = $_G['cache']['plugin']['apoyl_music'];
|
||
$message = $_G['discuzcodemessage'];
|
||
|
||
$controslist=' ';
|
||
if($cache['hidedown']){
|
||
$file=$this->_fileapoylv2('hidedownmusic');
|
||
if($file)
|
||
include $file;
|
||
|
||
}
|
||
|
||
if ($cache['openoss'] && $cache['ossurl']){
|
||
$file=$this->_fileapoylv2('ossmp3pcapoyl');
|
||
if($file)
|
||
include $file;
|
||
}
|
||
|
||
if ($cache['openmp3'] || $cache['openogg']){
|
||
$file=$this->_fileapoylv2('mp3pcapoyl');
|
||
if($file)
|
||
include $file;
|
||
}
|
||
|
||
if($cache['openwmp3']){
|
||
$file=$this->_fileapoylv2('wmp3apoyl');
|
||
if($file)
|
||
include $file;
|
||
|
||
}
|
||
$_G['discuzcodemessage'] = $message;
|
||
}
|
||
|
||
protected function _fileapoylv2($filename)
|
||
{
|
||
$fileapoyl = dirname(__FILE__) .'/components/' . $filename . '.php';
|
||
if (file_exists($fileapoyl))
|
||
return $fileapoyl;
|
||
return '';
|
||
}
|
||
}
|
||
class plugin_apoyl_music_forum extends plugin_apoyl_music{
|
||
|
||
public function viewthread_bottom_output($a)
|
||
{
|
||
global $_G, $postlist;
|
||
$cache = $_G['cache']['plugin']['apoyl_music'];
|
||
$return = '';
|
||
if($cache['hidedown']){
|
||
$file=$this->_fileapoylv2('hidedown');
|
||
if($file)
|
||
include $file;
|
||
}
|
||
|
||
return $return;
|
||
|
||
}
|
||
public function index_nav_extra_output($a){
|
||
global $_G;
|
||
$re='';
|
||
$cache = $_G['cache']['plugin']['apoyl_music'];
|
||
$file=$this->_fileapoylv2('bgpcmp3apoyl');
|
||
if($file)
|
||
include $file;
|
||
|
||
return $re;
|
||
|
||
}
|
||
public function guide_nav_extra_output($a){
|
||
global $_G;
|
||
$re='';
|
||
$cache = $_G['cache']['plugin']['apoyl_music'];
|
||
|
||
$file=$this->_fileapoylv2('guidehotmp3apoyl');
|
||
if($file)
|
||
include $file;
|
||
|
||
|
||
return $re;
|
||
}
|
||
}
|
||
class plugin_apoyl_music_portal extends plugin_apoyl_music{
|
||
public function view_lyopa_output($a){
|
||
global $_G,$content;
|
||
$cache = $_G['cache']['plugin']['apoyl_music'];
|
||
$file=$this->_fileapoylv2('articlepcmp3apoyl');
|
||
if($file)
|
||
include $file;
|
||
|
||
if($cache['openwarticlemp3']){
|
||
$file=$this->_fileapoylv2('warticlemp3apoyl');
|
||
if($file)
|
||
include $file;
|
||
|
||
}
|
||
}
|
||
|
||
}
|
||
|
||
?>
|