This is how actually youtube videos are embedded into elkarte:
https://www.youtube.com/watch?v=M7FIvfx5J10
Is there a way to display embedded video like this?
In elk_jquery_embed.js:
args = handler(m[2], tag, false);
args = handler(m[2], tag, true);
FA MALEEE!!! O_O
Thank you! Problem solved!
Just realize that embedding the video from the start vs just showing a preview image does have additional overhead for the end user. Meaning it will slow a page load, more videos on a page, the more it has to fetch to be ready.
@Spuds , can we replace the border ( not very cute in my opinion ) and replace it with a base preview image ?
The easiest way to do that is with the custom.css file in your themes base css directory.
.elk_videoheader {
display: none;
}
.elk_video {
border: none;
}
add the above to that file and the border and header will go away.
Thanks
@Spuds . Is there any specific use for that frame ?
No not really
The header allows to slide hide the video, that could be done other ways as well. The "issue" is that the header is a fixed width and really should be dynamically set based on the size of the video that gets embedded. But with a fixed width it looks pretty silly without the border around the video.
imo, that frame is just to advice users that there is a video, otherwise without the controls from youtube could seem a normal image embedded
Could probably just overlay the play icon on the image as well.
bug?
[center]https://www.youtube.com/watch?v=M7FIvfx5J10[/center]
no effect (center)
You can try changing the css, not sure if it will have other side effects. So change .elk_videoheader to
.elk_videoheader {
padding: 0 4px 0 6px;
/* max-width: 98%; */
/* width: 630px; */
border: 1px solid;
}
and .elk_video to
.elk_video {
display: block;
max-height: 480px;
/* width: 640px; */
height: auto;
border: 1px solid;
border-top: 0;
}
probably not the effect / result you are after though.
Sorry to necro this thread, but recently found myself having to do the same thing (alignment of embedded video) the best solution i found was to change display: block; to display: inline-block; on the elk_video containers (including videoheader) and now it works with alignment bbc.