форум vBSupport.ru > vBulletin > vBulletin 3.8.x > Вопросы по vBulletin 3.8
  • »
VBsupport перешел с домена .ORG на родной .RU Ура! Пожалуйста, обновите свои закладки - VBsupport.ru
 
 
 
 
TTR123
Простоузер
Default HTML5 MP3/MP4 Attachment Player
0

https://www.vbulletin.org/forum/showthread.php?t=314704
Есть хак для 3.8.11?
Поиском ничего не удалось найти.
Bot
Yandex Bot Yandex Bot is online now
 
Join Date: 05.05.2005
Реклама на форуме А что у нас тут интересного? =)
 
 
kerk
k0t
 
kerk's Avatar
Default
0

а по ссылке из темы не дает скачать?
там же вроде все подробно расписано и показано, где и что редактировать
 
 
TTR123
Простоузер
Default
0

Only licensed members can download files

Не дает к сожалению ссылку на файл.
 
 
kerk
k0t
 
kerk's Avatar
Default
2

For some reason, i enjoy working with all different players from around the net, like in what ways can a video/audio player help in the ways of vbulletin 3, to completely one day have vb3 players all compatible with HTML5 with the flash fall back. well, after testing with many HTML5 players, it seems, for this mod, so far mediaelement comes out on top. mind you, lets get one thing strait, at this stage, you just cannot please every single browser or device. but, this is at least, a great start for attachments in threads/posts using HTML5 with flash fall back. and mediaelement is updating all the time, so maybe, in the end, this player will work for everything, fingers crossed!

This is a very strait forward install of a HTML5/Flash Fallback Player uploaded in your MP3/MP4 uploaded attachments to threads/posts.

How to install:

1. upload the attached zip to your forums root.
2. in your postbit_attachment template, add this code to the very bottom:
Code:
<!-- Embed Player MP4 -->
<if condition="$attachment[attachmentextension] == mp4">
<if condition="$show['member']">
<div><video width="320" height="240" poster="/mediaelement/build/bg.png" controls="controls" preload="none">
    <source type="video/mp4" src="attachment.php?$session[sessionurl]attachmentid=$attachment[attachmentid]&amp;d=$attachment[dateline]" />
    <object width="320" height="240" type="application/x-shockwave-flash" data="/mediaelement/build/flashmediaelement.swf">
        <param name="movie" value="/mediaelement/build/flashmediaelement.swf" />
        <param name="flashvars" value="controls=true&file=attachment.php?$session[sessionurl]attachmentid=$attachment[attachmentid]&amp;d=$attachment[dateline]" />
        <!-- Image as a last resort -->
        <img src="/mediaelement/build/bg.png" width="320" height="240" title="No video playback capabilities" />
    </object>
</video></div><br />
</if></if>
<!-- /Embed Player MP4 -->

<!-- Embed Player MP3 -->
<if condition="$attachment[attachmentextension] == mp3">
<if condition="$show['member']">
<div><audio width="320" height="30" controls="controls" preload="none">
<source type="audio/mp3" src="attachment.php?$session[sessionurl]attachmentid=$attachment[attachmentid]&amp;d=$attachment[dateline]" />
    <object width="320" height="30" type="application/x-shockwave-flash" data="/mediaelement/build/flashmediaelement.swf">
        <param name="movie" value="/mediaelement/build/flashmediaelement.swf" />
        <param name="flashvars" value="controls=true&file=attachment.php?$session[sessionurl]attachmentid=$attachment[attachmentid]&amp;d=$attachment[dateline]" />
    </object>
</audio></div><br />
</if></if>
<!-- /Embed Player MP3 -->
3.Add this code to the bottom of your Headinclude Template: Note, Full URL is needed to support Safari.

Code:
<script src="http://www.YOURSITE.com/mediaelement/build/jquery.js" type="text/javascript">
</script>
<script src="http://www.YOURSITE.com/mediaelement/build/mediaelement-and-player.min.js" type="text/javascript">
</script>
<link rel="stylesheet" href="http://www.YOURSITE.com/mediaelement/build/mediaelementplayer.css" type="text/css" />
4.Add this code to the bottom of your Footer Template:
Code:
<script type="text/javascript">
//<![CDATA[
// using jQuery
$('video,audio').mediaelementplayer();
//]]>
</script>
5.Upload the attached mp4.gif to your images/attach folder.

6.Add New Extension for MP3/MP4 Attachments. See Read Me Text on how to do this.
http://rgho.st/8wGVSpPqC
 
 
TTR123
Простоузер
Default
0

Большое спасибо!
 
 
TTR123
Простоузер
Default
0

Не подскажете.
Всё сделал по инструкции но ошибок не было. просто не работает.
 
 
Kurbatov
Эксперт
vBSponsor
 
Kurbatov's Avatar
Default
1

Может быть протокол у Вас на сайте https, а в скрипте указан http, вот и не отображает.
 
 
TTR123
Простоузер
Default
0

http: протокол.

Какой же кривой 3.8.11
 
 
Hobot
Эксперт
 
Hobot's Avatar
Default
1

а вот это сделано?
Quote:
How to create New Extension in your Admincp for Attachment MP3/MP4.

Goto Attachments>>Attachment Manager>>Add New Extension.
For MP3, add the following.
===========================================
Extension: mp3
Max Filesize: set at your max upload size
Maximum Width: 0
Maximum Height: 0
Mime Type & Headers: Content-type: audio/mp3
Display thumbnail for this type?: no
Open this attachment in a new browser window?: no
Enabled: yes
Save.
===========================================
For MP4, Add another New Extension.
===========================================
Extension: mp4
Max Filesize: set at your max upload size
Maximum Width: 0
Maximum Height: 0
Mime Type & Headers: Content-type: video/mp4
Display thumbnail for this type?: no
Open this attachment in a new browser window?: no
Enabled: yes
Save.
===========================================

This is the same for VB3 and VB4.
 
 
TTR123
Простоузер
Default
0

@Hobot, угу.



 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off




All times are GMT +4. The time now is 10:18 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Loading...