By MechaLynx
Description
Currently we only have a Flash-based option for audio and video inclusion. These snippets fix that by providing an HTML5-based alternative (which should really be the default by now).
Code
You can create audio and video embeds like this:
[[include :snippets:html5player
|type=audio
|url=audio file url
]]
If you want the file to play automatically, do it this way:
[[include :snippets:html5player
|type=video
|url=video file url
|autoplay=true
]]
type should be "video" or "audio".
autoplay is optional and only takes the value "true" if you use it. It's off by default.
Due to how the audio and video elements are implemented, they are not stylable this way, but this embed can of course be extended to provide a custom layout which can be styled.
In action
Thanks to tsangk for this great snippet: conditional-blocks
text above inserted with:
[[include :snippets:if START |unique=1|type=equal|var1=%%name%%|var2=conditional-blocks]]
**##red|Thanks to tsangk for this great snippet:##** [[[code:conditional-blocks]]]
[[include :snippets:if END]]
Other snippets posted by MechaLynx
Rate this solution
If you think this solution is useful — rate it up!
sorry, but how can i resize/force the video window to new height, width ?
thx !!!
Awesome ! Thank you for sharing this code. I'm still learning wikidot, but it doesn't look that hard !
Just found this and it's great! How simple yet perfect
And the autoplay feature is amazing
That's pretty good! Just saw this, after receiving an edit notification today :)
~ Shane (Wikidot Community Admin - Volunteer)
Wikidot: Wikidot Editor, Official Docs
Other: YouTube (gaming, primarily Minecraft)
Yeah I noticed my tags were incomplete :P thanks!
Thanks for this new standard!
Service is my success. My webtips:www.blender.org (Open source), Wikidot-Handbook.
Sie können fragen und mitwirken in der deutschsprachigen » User-Gemeinschaft für WikidotNutzer oder
im deutschen » Wikidot Handbuch ?