| View previous topic :: View next topic |
| Author |
Message |
C.R.T. New Poster

Joined: 28 Apr 2006 Posts: 36
     votes: 1
|
Posted: Wed May 10, 2006 3:58 Post subject: [PLUGIN] Audio/Video player with RSS enclosure hack |
|
|
What does it do:
It allows users to insert Dewplayer (for playing mp3) and Windows Media Player (for wmv, mpeg etc) in their posts. It is possible to use other audio/video players by changing the configuration file. By applying the RSS enclosure hack, it is also possible to make these media files detectable and dowloadable by podcasting/vodcasting catcher software.
How to install:
1. If you want to use Dewplayer, download and upload it to your server.
2. Download the attached zip file.
3. Change the "http://your/blog/dewplayer.swf" parts in _mediaplayer.conf.php to wherever you placed Dewplayer.
4. Place the files in these locations:
_mediaplayer.conf.php in plugins
_mediaplayer.renderer.php in plugins/renderer
_mediaplayer.toolbar.php in plugins/toolbar
5. Activate the plugin as you normally would.
Once installed and activated, a toolbar will be added to the editing area. Simply enter the media file URL in the "Audio/Video" text box and click "Add".
To use other audio/video players:
In _mediaplayer.conf.php, change the values of audio_player_html and video_player_html to the HTML code for displaying your choice of player. Use _FILE_ as the placeholder for the media file location.
To enable RSS enclosure:
Backup your xmlsrv/rss2.php and replace it with the rss2.php in the attached zip file.
This RSS hack is largely based on the excellent work of turbo2ltr, but it does not require CURL.
This plugin is developed and tested on v0.9.0.11.
Enjoy! Comments welcomed.
See here for v1.8 plugin
Last edited by C.R.T. on Sun Aug 27, 2006 5:15; edited 1 time in total |
|
| Back to top |
|
 |
starpause New Poster

Joined: 20 Jun 2006 Posts: 1  
|
Posted: Tue Jun 20, 2006 18:38 Post subject: |
|
|
just for reference, here's the dewplayer page bablefished to english.
now, i've got dew player working, and the plugin seems to work, but the rss2.php replacement fails to render a feed. instead, i get this error:
| Code: |
404 Not Found
b2evolution cannot resolve the requested URL. |
i'm using b2evo v 0.9.1
any suggestions? need any more info? thanks for helping people podcast with b2evolution, dewplayer, this mediaplayer, and the fact that you can easily upload to b2evolution makes a great combo.
as soon as i have this rss biznetz worked out
edit: i'm accessing this url to get the error: http://mp3death.us/a2g/xmlsrv/rss2.php?blog=2
edit2: i added this line to the 4ss2.php included in mediaplayer.zip
| Code: |
/**
* Initialize everything:
*/
$resolve_extra_path = false; // We don't want extra path resolution on this page
|
then the rss2.php worked and i at least see an enclosure in there. haven't tried hitting the url as a podcast yet  _________________ lobit labia: http://mp3death.us/ |
|
| Back to top |
|
 |
C.R.T. New Poster

Joined: 28 Apr 2006 Posts: 36
     votes: 1
|
Posted: Tue Jun 20, 2006 23:15 Post subject: |
|
|
| I guess the $resolve_extra_path is something new in v0.9.1. Thanks for making it work on v0.9.1! (I should have upgraded my b2evo but I guess I'll wait a little while longer for the final Phoenix release) |
|
| Back to top |
|
 |
Nick New Poster

Joined: 09 Aug 2006 Posts: 10
      
|
Posted: Wed Aug 09, 2006 18:36 Post subject: |
|
|
| Is this also a valid option for version v1.8? |
|
| Back to top |
|
 |
C.R.T. New Poster

Joined: 28 Apr 2006 Posts: 36
     votes: 1
|
Posted: Wed Aug 09, 2006 21:27 Post subject: |
|
|
| It does not work for v1.8 yet. I have only recently started to upgrade my b2evo to v1.8, and it is my plan to make this a 1.8 plugin. |
|
| Back to top |
|
 |
mikih New Poster

Joined: 26 Aug 2006 Posts: 5
       
|
Posted: Sat Aug 26, 2006 11:03 Post subject: status? |
|
|
hello,
have you done it? I need that plugin asap. If you need help, give me feedback.
Mikih |
|
| Back to top |
|
 |
C.R.T. New Poster

Joined: 28 Apr 2006 Posts: 36
     votes: 1
|
Posted: Sun Aug 27, 2006 5:08 Post subject: |
|
|
Here you go, the 1.8 plugin.
Some slight variations to its usage:
1. After you installed the plugin, you would have to go to the plugin admin page to tell it what file extensions to handle and how to render. This information was hard coded in the previous version. With this version, you can add/change the types of players easily without hacking the code.
If you want to use Dewplayer and Windows Media Player as in the previous version, enter these values for the plugin setting:
File types:
.mp3
HTML:
| Code: |
<object type="application/x-shockwave-flash" data="http://www.yoururl.com/blogs/dewplayer.swf?mp3=_FILE_" width="200" height="20"><param name="movie" value="http://www.yoururl.com/blogs/dewplayer.swf?mp3=_FILE_" /></object>
|
File types:
.wmv .mpg .mpeg
HTML:
| Code: |
| <embed type="application/x-mplayer2" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" src="_FILE_" width=360 height=300 name="MediaPlayer" autostart="0" ShowStatusBar=1 ShowControls=1 ></embed> |
2. To enable RSS enclosure, you can replace the main.php in the "skins/_rss2" folder with the one in the zip file, or you can place the entire "_rss2_mplayer" folder in "skins". If you choose to do the latter, you would have to hack your skin to make the RSS2 link look like so:
| Code: |
| http://www.yoururl.com/blogs/yourblog.php?tempskin=_rss2_mplayer |
I have not tested this thoroughly yet. If you find any problem please let me know.
Thanks.
v1.8.1 updated on Nov 3, 2006: Minor bug fix to resolve "merge_array" problem on some PHP version.
Last edited by C.R.T. on Fri Nov 03, 2006 8:44; edited 1 time in total |
|
| Back to top |
|
 |
mikih New Poster

Joined: 26 Aug 2006 Posts: 5
       
|
Posted: Sun Aug 27, 2006 8:27 Post subject: |
|
|
hello,
thank you very much! that is really great. I`m new in the b2core api but i will try to extend it like die file manager so that you can choice between image tag or media tag.
Thanks Mikih |
|
| Back to top |
|
 |
poopoo New Poster

Joined: 28 Aug 2006 Posts: 30
    
|
Posted: Tue Aug 29, 2006 19:10 Post subject: |
|
|
yes, I like this also, I like the fact that hides the files.
So, Is there any way to even better hide the location of the files?
or maybe a bit off topic but, is it possible to not alow direct access to the media folder...yet still use the player? |
|
| Back to top |
|
 |
gbrusella New Poster

Joined: 14 Sep 2006 Posts: 15
 
|
Posted: Tue Oct 17, 2006 12:19 Post subject: |
|
|
For QT movies use:
| Code: |
| <embed src="_FILE_" Pluginspage="http://www.apple.com/quicktime/" width="317" height="258" CONTROLLER=true LOOP=false AUTOPLAY=false name="slideshow"></embed> |
|
|
| Back to top |
|
 |
C.R.T. New Poster

Joined: 28 Apr 2006 Posts: 36
     votes: 1
|
Posted: Thu Oct 19, 2006 22:01 Post subject: |
|
|
I use this to embed Flash:
| Code: |
<OBJECT classid="clsid: D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" WIDTH="100%" HEIGHT="300" ALIGN="">
<PARAM NAME=movie VALUE="_FILE_"><PARAM NAME=name VALUE=false><PARAM NAME=quality VALUE=high><PARAM NAME=scale VALUE=noscale><PARAM NAME=bgcolor VALUE=#FFFFFF>
<EMBED src="_FILE_" menu=false quality=high scale=noscale bgcolor=#FFFFFF WIDTH="100%" HEIGHT="300" ALIGN="" TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">
</EMBED>
</OBJECT> |
You might need to modify the width, height and bgcolor. |
|
| Back to top |
|
 |
rcxAsh New Poster

Joined: 01 Sep 2005 Posts: 19
    
|
Posted: Sat Oct 21, 2006 12:49 Post subject: |
|
|
I just upgraded to 1.8.2 and decided to try this plugin out.
I'm having some issues though.. the plugin inserts a comment into my blog entry, but when I publish the entry, the comment just stays a comment. It is not rendered as the html I entered in the settings panel.
I'm not sure what I'm missing. |
|
| Back to top |
|
 |
C.R.T. New Poster

Joined: 28 Apr 2006 Posts: 36
     votes: 1
|
Posted: Sun Oct 22, 2006 0:30 Post subject: |
|
|
Hi rcxAsh,
Have you checked whether the "Apply rendering" setting in "App Settings, Plugins" is set to "always"?
I am running it on 1.8.1 and have not upgraded to 1.8.2 yet. If this is a common issue for 1.8.2 I will have to fix it later. |
|
| Back to top |
|
 |
rcxAsh New Poster

Joined: 01 Sep 2005 Posts: 19
    
|
Posted: Sun Oct 22, 2006 0:50 Post subject: |
|
|
Thanks, C.R.T., that seemed to do the trick!
This is a really neat plugin!  |
|
| Back to top |
|
 |
werner New Poster

Joined: 24 Oct 2006 Posts: 2  
|
Posted: Tue Oct 24, 2006 4:14 Post subject: Add button not working |
|
|
Hi
I'm running 1.8.2 with the MediaPlayer installed as above and everthing looks fine, I go to the Post tab and above then content I see the
Audio/Video: Add
But when I click on add nothing happens and the javascript console in firefox tells me
mplayer_add is not defined
any ideas whats going on ???
thx werner |
|
| Back to top |
|
 |
|