Modify

Ticket #238 (closed feature: fixed)

Opened 6 years ago

Last modified 5 years ago

Include social networking bookmarklets

Reported by: vik Owned by:
Priority: minor Milestone: 4.1
Component: SocialSoftware Severity:
Keywords: Cc:
Who will test this: And

Description

Include the ability for users to easily add a video or other item to their social network (facebook, twitter, etc). The product collective.plonebookmarklets seems to do this.

Nicer still would be the ability to embed videos in facebook (and other social networks?) like youtube videos are currently. This should be relatively easy with facebook's FBML and the flv tag.

Attachments

Change History

comment:1 Changed 6 years ago by vik

Info on getting video embedding working in facebook can be found at  http://www.facebook.com/share_partners.php and  http://forum.developers.facebook.com/viewtopic.php?id=32464

Basically what's needed is a <link> tag (and optionally some <meta> tags in the video's page pointing to the flash video url, as well as a whitelist request to facebook. The full link for a playable swf object would look like:  http://prod-flv.engagemedia.org/FlowPlayer.swf?config={playList:[{url:'http://www.engagemedia.org/Members//JamieMUA/videos/Grand_Victory_ITF_V4.mpg/thumbnailImage_large',type:'jpg',overlayId:'play'},{url:'http://prod-flv.engagemedia.org//JamieMUA/videos/Grand_Victory_ITF_V4-550b0d66e7bb63492002802598f92150.flv'}],autoPlay:false,autoBuffering:false,loop:false,fullScreenScriptURL:'http://prod-flv.engagemedia.org//fullscreen.js'} (no spaces or newlines), while it may or may not be possible to use the straight flv file and use video/x-flv as the video type...

I have send the following message to facebook developer's help to get engagemedia.org whitelisted to embedded playback:

We run a video-sharing website  http://www.engagemedia.org and would like to have videos playable in facebook like youtube et al currently do. Our flv/swf files are currently served from prod-flv.engagemedia.org. Can you please whitelist both domains (www.engagemedia.org and prod-flv.engagemedia.org)?

Also, regarding setting up meta tags on our site to make this work, is it possible to link directly to an flv file, or do you need an swf for embedding? Our files are hosted as flv, with a swf player configured for each piece of content. I make a link for the swf-enabled file, but it becomes a very long URL, and a direct link to the flv would be simpler. i.e. what are the acceptable values for the video_type meta tag, and is video/x-flv one of them?

comment:2 Changed 5 years ago by vik

Here's some code that could be retrofitted into a plumi 0.2.x install to generate some of the required info for the above. This could then be pulled into the HTML HEAD element using the right template. It's an ugly hack, and would be much nicer if the following info could be easily and seamlessly gleaned from plone or indytube:

  • flowplayer url
  • flowplayer config string
  • video height
  • video width
  • mime type.


Good news is that facebook now embeds video from engagemedia: try linking to  http://www.engagemedia.org/Members/vik/fbtest2.html to see it in action.

from HTMLParser import HTMLParser
class flvincParser(HTMLParser):
    def handle_starttag(self, tag, attrs):
        if (tag == 'object'):
            for i in attrs:
                if (i[0] == 'type'):
                    self.mimetype = i[1]
                elif (i[0] == 'data'):
                    self.swfurl = i[1]
                elif (i[0] == 'width'):
                    self.width = i[1]
                elif (i[0] == 'height'):
                    self.height = i[1]
        elif (tag == 'param'):
            if (attrs[0][1] == 'flashvars'):
                self.flashvars = attrs[1][1].replace(' ', '') #get rid of all whitespace

f=flvincParser()
f.feed(self.getIndyTubeHTML())

comment:3 Changed 5 years ago by and

  • Status changed from new to closed
  • Resolution set to fixed
  • Who will test this set to And

This has already been added in the 3.0 release. Ticking off.

View

Add a comment

Modify Ticket

Action
as closed
The resolution will be deleted. Next status will be 'reopened'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.