本人不是转载 。但是首发在
校内PT(nexusphp)架设6V在线播放教程
http://www.v6player.org/forum/forum.php?mod=viewthread&tid=32&fromuid=129
{:1_94:}
对于有一定基础的朋友可能看的更明白
因为本校是校内PT不对外访问,故没办法给各位访问验证
言归正传
对于nexusphp架设的网站
1. Details.php修改
在原来的行为菜单代码后(start attachment block 注释前),加上v6player的代码,
/*********************6vdplayer**************************/
//搜索(在最前面16行左右)
$res = sql_query("SELECT torrents.temp+torrents.mod_temp as final_temp,torrents.title_image,torrents.ygp,torrents.editlock,torrents.editlockid,torrents.cache_stamp, torrents.sp_state, torrents.url, torrents.dburl, torrents.small_descr, torrents.seeders, torrents.banned, torrents.leechers, torrents.info_hash, torrents.filename, nfo, LENGTH(torrents.nfo) AS nfosz, torrents.last_action, torrents.name, torrents.owner, torrents.save_as, torrents.descr, torrents.visible, torrents.size, torrents.added, torrents.views, torrents.hits, torrents.times_completed, torrents.id, torrents.type, torrents.numfiles, torrents.anonymous, categories.name AS cat_name, sources.name AS source_name, media.name AS medium_name, codecs.name AS codec_name, standards.name AS standard_name, processings.name AS processing_name, teams.name AS team_name, audiocds.name AS audiocd_name FROM torrents LEFT JOIN categories ON torrents.category = categories.id LEFT JOIN sources ON torrents.source = sources.id LEFT JOIN media ON torrents.medium = media.id LEFT JOIN codecs ON torrents.codec = codecs.id LEFT JOIN standards ON torrents.standard = standards.id LEFT JOIN processings ON torrents.processing = processings.id LEFT JOIN teams ON torrents.team = teams.id LEFT JOIN audiocds ON torrents.audiocd = audiocds.id WHERE torrents.id = $id LIMIT 1")
or sqlerr();
改为
$res = sql_query("SELECT torrents.category,torrents.temp+torrents.mod_temp as final_temp,torrents.title_image,torrents.ygp,torrents.editlock,torrents.editlockid,torrents.cache_stamp, torrents.sp_state, torrents.url, torrents.dburl, torrents.small_descr, torrents.seeders, torrents.banned, torrents.leechers, torrents.info_hash, torrents.filename, nfo, LENGTH(torrents.nfo) AS nfosz, torrents.last_action, torrents.name, torrents.owner, torrents.save_as, torrents.descr, torrents.visible, torrents.size, torrents.added, torrents.views, torrents.hits, torrents.times_completed, torrents.id, torrents.type, torrents.numfiles, torrents.anonymous, categories.name AS cat_name, sources.name AS source_name, media.name AS medium_name, codecs.name AS codec_name, standards.name AS standard_name, processings.name AS processing_name, teams.name AS team_name, audiocds.name AS audiocd_name FROM torrents LEFT JOIN categories ON torrents.category = categories.id LEFT JOIN sources ON torrents.source = sources.id LEFT JOIN media ON torrents.medium = media.id LEFT JOIN codecs ON torrents.codec = codecs.id LEFT JOIN standards ON torrents.standard = standards.id LEFT JOIN processings ON torrents.processing = processings.id LEFT JOIN teams ON torrents.team = teams.id LEFT JOIN audiocds ON torrents.audiocd = audiocds.id WHERE torrents.id = $id LIMIT 1")
or sqlerr();
//如果对于某等级以上用户可见的话还可以添加 if(get_user_class() >= UC_STAFFLEADER)
//401和408这里是判断资源类别的,对于非视频类资源就可以除外了,要在以上修改过$res 才有用哦!
if($row['category'] == '401' || $row['category'] == '408'){
$v6button = "| ".
"<script type=\"text/javascript\">function play(){window.location.href='6xvod://{$id}&ty=1&ro=1&id={$id}&ua={$CURUSER['passkey']}';}</script>".
"<img height='14px' src=\"pic/v6player.gif\"/>".
"<a href=\"v6player.php?id={$id}&u={$CURUSER['passkey']}\" target=\"_blank\"><b><font class=\"small\"> 直接播放</font></b></a>";
}else {
$v6button = "";
}
/*********************6vdplayer**************************/
改动紧接着下方的tr函数,在最后加上.$v6button
tr($lang_details['row_action'], $download. ($owned == 1 ? "<$editlink><img class=\"dt_edit\" src=\"pic/trans.gif\" alt=\"edit\" /> <b><font class=\"small\">".$lang_details['text_edit_torrent'] . "</font></b></a> | " : "").
(get_user_class() >= $askreseed_class && $row[seeders] == 0 ? "<a title=\"".$lang_details['title_ask_for_reseed']."\" href=\"takereseed.php?reseedid=$id\"><img class=\"dt_reseed\" src=\"pic/trans.gif\" alt=\"reseed\"> <b><font cla
ss=\"small\">".$lang_details['text_ask_for_reseed'] ."</font></b></a> | " : "") . "<a title=\"".$lang_details['title_report_torrent']."\" href=\"report.php?torrent=$id\"><img class=\"dt_report\" src=\"pic/trans.gif\" alt=\"repo
rt\" /> <b><font class=\"small\">".$lang_details['text_report_torrent']."</font></b></a> ".$v6button, 1);
// ---------------- start attachment block -------------------//
2. pic文件夹下放v6player.gif 和 v6playerad.gif
3. 编辑v6player.php 将网址替换为自己网站地址
4.编辑v6player.php 替换其中网站网址为你自己的
5. 将v6player.php放到根目录下
6. 望多多宣传
7.如有意向请加QQ群:108533467 注明:nexusphp直播
所需附件下载:
点击下载播放器: http://www.v6player.org/update/v6player1.02_ipv4.exe
此版本为默认ipv4线路,如有ipv6需要请在设置面板里设置 还可访问: http://www.v6player.org
效果图:
播放器设置需注意:
1.设置下载目录为较大硬盘目录
2.需同意v6播放器绑定影音播放文件
3.右键可下载字幕,支持拖曳
|