diff --git a/addons/oembed/jquery.oembed.js b/addons/oembed/jquery.oembed.js index 07ed993a5..496d689af 100755 --- a/addons/oembed/jquery.oembed.js +++ b/addons/oembed/jquery.oembed.js @@ -949,54 +949,6 @@ new $.fn.oembed.OEmbedProvider("polar", "rich", ["polarb\\.com/.+"], "http://assets-polarb-com.a.ssl.fastly.net/api/v4/publishers/unknown/embedded_polls/iframe?poll_id=$1", {templateRegex: /.*polarb\.com\/polls\/(\w+).*/, embedtag: {tag: 'iframe', width: 480, height: 360 }, nocache: 1}), new $.fn.oembed.OEmbedProvider("ponga", "rich", ["ponga\\.com/.+"], "https://www.ponga.com/embedded?id=$1", {templateRegex: [/.*ponga\.com\/embedded\?id=(\w+).*/, /.*ponga\.com\/(\w+).*/], embedtag: {tag: 'iframe', width: 480, height: 360 }, nocache: 1}), - //Use Open Graph Where applicable - new $.fn.oembed.OEmbedProvider("opengraph", "rich", [".*"], null, - { - yql: { - xpath: "//meta|//title|//link", - from: 'html', - datareturn: function (results) { - if (!results['og:title'] && results['title'] && results['description']) - results['og:title'] = results['title']; - - if (!results['og:title'] && !results['title']) - return false; - - var code = $('

'); - if (results['og:video']) { - var embed = $(''); - embed.attr('type', results['og:video:type'] || "application/x-shockwave-flash") - .css('max-height', settings.maxHeight || 'auto') - .css('max-width', settings.maxWidth || 'auto'); - if (results['og:video:width']) - embed.attr('width', results['og:video:width']); - if (results['og:video:height']) - embed.attr('height', results['og:video:height']); - code.append(embed); - } else if (results['og:image']) { - var img = $(''); - img.css('max-height', settings.maxHeight || 'auto').css('max-width', settings.maxWidth || 'auto'); - if (results['og:image:width']) - img.attr('width', results['og:image:width']); - if (results['og:image:height']) - img.attr('height', results['og:image:height']); - code.append(img); - } - - if (results['og:title']) - code.append('' + results['og:title'] + '
'); - - if (results['og:description']) - code.append(results['og:description'] + '
'); - else if (results['description']) - code.append(results['description'] + '
'); - - return code; - } - } - } - ) - ]; })(jQuery); //This is needed for gravatar :(