Anyone have the support code for Blip.tv

rl - June 13, 2008 - 17:22
Project:Video Filter
Version:6.x-2.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:closed
Description

I am interested in using this with Blip.tv. Has anyone done this and if yes. can you post the code?

Thanks

Rich

#1

mkrakowiak - June 28, 2008 - 01:58
Version:6.x-2.4» 5.x-2.4
Category:support request» feature request

I would be happy to see a filter for Blip.tv, too.

#2

mkrakowiak - June 30, 2008 - 01:04
Assigned to:Anonymous» mkrakowiak
Status:active» patch (to be ported)

OK, this is not a perfect solution, but it works. This code needs to be added into the video_filter.codecs.inc file:

<?php
$codecs
['bliptv'] = array(
 
'name' => t('Blip.tv'),
 
'callback' => 'video_filter_bliptv',
 
// http: // cpj.blip.tv/#1036772
 
'regexp' => '/.*\.blip\.tv\/#([0-9]+)/',
 
'ratio' => 400 / 255,
);


function
video_filter_bliptv($video) {
 
$output = '';
   
 
$output .= '<embed src="http://blip.tv/scripts/flash/showplayer.swf?enablejs=true&file=http%3A%2F%2Fblip%2Etv%2Frss%2Fflash%2F'.$video['codec']['matches'][1].';%3Freferrer%3Dblip%2Etv%26source%3D1&showplayerpath=http%3A%2F%2Fblip%2Etv%2Fscripts%2Fflash%2Fshowplayer%2Eswf" quality="best" width="400" height="255" name="showplayer" type="application/x-shockwave-flash"></embed>';
   
  return
$output;   
}
?>

Now, this is important:
Once you're on a blip.tv page where your video is, you have to click on "Visit show page" on the right sidebar, click on the video of your choice, and then copy the URL from address bar. This is required because permalinks created by blip.tv are NOT the right links to videos. You can check that by taking a look at the "embed this video" code. The URL that you should embed looks like this: http://membername.blip.tv/#1234567

#3

JohnnyMoney - July 25, 2008 - 07:26

Sorry tried your solution and is not working for me.
Does one add this code to the end of the file? If so it screws my site, cannot see it at all. I notice the original file begins with <?php but has no closing php tag. If I add your code to the end then the file has the ending php tag. is that correct?

#4

mkrakowiak - July 26, 2008 - 08:51

It should work if you replace the original video_filter.codecs.inc file with the one attached here (certainly, unzip it first).

AttachmentSize
video_filter.codecs.inc_.zip 1.49 KB

#5

JohnnyMoney - July 26, 2008 - 11:35

Thanks, I confirm that this now works for Blip.

Unfortunately neither Blip nor Vimeo embedded videos in my Drupal site allow the Full Screen Toggle.
The only one that allows this without taking me to their site is Revver.

#6

mkrakowiak - July 28, 2008 - 12:41

I'm not sure about Vimeo, but Blip provides a full screen toggle. And this works right from user's website.

#7

JohnnyMoney - July 30, 2008 - 17:49

Well, the full screen toggle wasn't working on my site using the video_filter module so now I have removed this module and simply embedding the videos with the embed code from Blip makes them work perfectly and do toggle full screen.

#8

blackdog - March 15, 2009 - 22:29
Status:patch (to be ported)» active

Please roll a proper patch - http://drupal.org/patch/create

#9

mkrakowiak - March 19, 2009 - 03:52
Version:5.x-2.4» 5.x-2.x-dev
Status:active» patch (to be ported)

Here's a patch for Blip.tv support for D5.

The filter accepts URLs like http://username.blip.tv/#1036772

AttachmentSize
video_filter5.x-2.x-dev-blip_support.patch 1.16 KB

#10

blackdog - March 19, 2009 - 09:59
Status:patch (to be ported)» needs review

Will test this later today. Thanks mkrakowiak!

#11

blackdog - March 19, 2009 - 20:57
Status:needs review» needs work

I don't really like how this looks. Blip has some strange ways of embedding videos, video id don't match with the id in the URL, and while this solution does work, it feels a bit hackish.

#12

blackdog - March 19, 2009 - 21:03

If someone still wants to use this, here's an updated patch that allows fullscreen and uses height/width default settings.

AttachmentSize
270279_video_filter_bliptv.patch 1.47 KB

#13

mkrakowiak - March 19, 2009 - 22:50
Status:needs work» needs review

Yes, it is hackish - because Blip uses two kinds of links: one with the username and the other one without. If you try embedding a Blip video with the latter URL, you will probably embed... some other video, not the one you want.
Thanks for your work on the module, blackdog.

#14

adresaklumea - May 22, 2009 - 09:55

How to embed with this [video:http://blip.tv/file/2140870] ? which regex is good ?

#15

blackdog - May 22, 2009 - 12:02
Status:needs review» postponed

How to embed with this [video:http://blip.tv/file/2140870] ? which regex is good ?

Short answer, you can't. The embed code that blip.tv uses for that file is some sort of randomized string, which we can't use. If you need to embed blip.tv videos, see comment #2 in this issue, and you'll need the patch from #12.

I'm gonna set this to postponed until we can figure out an easy way to instruct users how to embed blip.tv videos, or until someone figures out a way to use this module to embed all videos from blip.tv, without the need for instructions.

#16

adresaklumea - May 24, 2009 - 08:48

Embedded Media Field is suporting [video:http://blip.tv/file/2140870] , can't It's metod be implemented in this module ?

#17

blackdog - May 25, 2009 - 07:08

I'll take a look to see how emfield has solved it. Thanks.

#18

Freso - July 15, 2009 - 08:42
Version:5.x-2.x-dev» 6.x-2.x-dev

Seems like they use the page id to fetch an RSS feed and do some API calls to get the needed information.

http://cvs.drupal.org/viewvc.py/drupal/contributions/modules/emfield/con...

Also, let's get this in 6.x-2.x first and then backport to 5.x-2.x if needed. :)

#19

jtsnow - July 28, 2009 - 13:56
Status:postponed» needs review

I've adapted the code from emfield to work with video_filter. Works like a charm. Here is the patch.

AttachmentSize
270279_video_filter_bliptv-19.patch 2.67 KB

#20

jtsnow - July 28, 2009 - 13:58

Not sure on the ratio setting in that patch. That may need tweaking.

#21

blackdog - July 31, 2009 - 09:30

Great work jtsnow! I'll take a further look at this a.s.a.p. Thanks!

#22

blackdog - July 31, 2009 - 20:02

Committed as is (http://drupal.org/cvs?commit=245574).

Blip.tv seems to use different ratios for different players/videos, so I left it as in the patch for now.

Thanks jtsnow!

#23

blackdog - July 31, 2009 - 20:13
Assigned to:mkrakowiak» Anonymous
Status:needs review» fixed

#24

System Message - August 14, 2009 - 20:20
Status:fixed» closed

Automatically closed -- issue fixed for 2 weeks with no activity.

#25

mkrakowiak - August 20, 2009 - 18:10

Blackdog, sorry to be late with the review. It works perfect now. Thank you and thanks jtsnow!

 
 

Drupal is a registered trademark of Dries Buytaert.