This plugin adds oEmbed support for Imperavi's Redactor via Iframely API. It providers responsive rich media and image embeds via Iframely API endpoint, that supports over 1800 publishers and summary cards for the rest of the web.
You will get YouTube, Twitter, Facebook, Tumblr, Vimeo, SoundCloud, Flickr, Google Maps, GfyCat, Giphy, Imgur, Vimeo - all the usual suspects plus thousands more.
You will need to define oEmbed API endpoint in your settings, see below. For Iframely version, get your API key at iframely.com
Check out the simple plugin's demo on http://itteco.github.io/redactor-oembed/.
Get embeds through the dialog via 'Embed' button in Redactor's toolbar. The plugin also tries to recognize http links on a separate in editor as author types it.
<!-- Setup iframely redactor plugin. -->
<script src="redactor_iframely_plugin.js"></script>
<!-- Call Redactor -->
<script type="text/javascript">
$(document).ready(function() {
$('#redactor').redactor({
// Add 'iframely' to plugins.
plugins: ['iframely'],
// Setup your iframely endpoint path. The sample is given for cloud version.
oembedEndpoint: '//iframe.ly/api/oembed?api_key={YOUR API KEY HERE}'
});
});
</script>
Get your Iframely API key at iframely.com. You can also configure any other API parameters in your oembedEndpoint.
To fix Redactor styles issues when you stroke backspace, configure oembedEndpoint
with &omit_css=1
and add requires Iframely styles to your page yourself:
This plugin is licensed under MIT. Imperavi's Redactor has own license.
Feel free to submit an issue or fork and submit pull-requests with enhancements or fixes.