Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Streamable Embed
#1
[Image: L8pjmDG.jpg]

The following will allow your users to embed Streamable videos in their posts.

Regular Expression:
\[streamable\](https:\/\/(?:www\.|(?!www))(streamable)\.com/([a-z0-9]+))\[/streamable\]

Replacement:
<div style="width:100%;height:0px;position:relative;padding-bottom:56.250%;"><iframe src="https://streamable.com/s/$3/votbir" frameborder="0" width="100%" height="100%" allowfullscreen style="width:100%;height:100%;position:absolute;left:0px;top:0px;overflow:hidden;"></iframe></div>

Test Value:
[streamable]https://streamable.com/rlt9h[/streamable]

To allow users to set auto play and mute options you will need to adapt the code.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)