Support Center

Recent questions

About Koken

This Help Center provides support for Koken, a free content management system designed for photographers, artists and designers.

Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

Boulevard - Video Album - Trying to define the height of my videos

Nico

Feb 09, 2015 10:45AM EST

Hi,

I have a slightly custom Boulevard Theme.
I'm using the Vimeo import plugin to create video albums.
I don't find a way to define the height of videos : with my pictures albums, the pictures height is equal to the wrap (album intro) height and everything's working great, but with videos, the wrap is taller than my videos and so it looks bad.
I tried to define height by adding <div height="xxx"></div> more or less around <koken:video /> but it's not working.
I tried to look for some video attributes in settings.css.lens but I didn't find anything.

For the moment the only way I could fix the video height was by using this jQuery script :
<script>

// Trouver les videos Vimeo
var $allVideos = $("iframe[src^='//player.vimeo.com']"),
// L element contenant les videos: ici body
$fluidEl = $("body");

// Trouver et sauvegarder le ration des dimensions de la video
$allVideos.each(function() {
$(this)
.data('aspectRatio', this.height / this.width)

// Supprimer les tailles en dur de la video
.removeAttr('height')
.removeAttr('width');

});

// Evenement : Quand la fenetre est redimensionnée
$(window).resize(function() {

var newWidth = $fluidEl.width() - 262;

// Redimensionner toutes les videos en fonction de leur ration
$allVideos.each(function() {

var $el = $(this);
$el
.width(newWidth)
.height(newWidth * $el.data('aspectRatio'));

});

}).resize();</script>

This script gave me exactly what I wanted, the video height is the same than the warp height, but 2 problems appear :
- If I have another video in the album after the first one, the second one frame is going over the first video (right side of the first video under left side of the second)
- I loose the dynamic resizing of contents if I reduce my window size : the video width is reducing the good way but height is getting stuck at original size so big black areas appear around the video frame and it's quite a mess.
This script was doing great on a static page with the exactly same video embedded with <iframe> stuff, but appears to be unable to help me for a dynamic video album.

So my questions are : is it possible to fix this video height problem in a video album ? How ? CSS, original page code, script ?
Or maybe it's possible to define somewhere the exact size (width x height) I need for every video ?
Actually I don't understand why everything's going well with pictures and not with videos, as they look to be treated the same way as an album by Boulevard...

Thanks

This question has received the maximum number of answers.

support@koken.me
http://assets3.desk.com/
false
koken
Loading
seconds ago
a minute ago
minutes ago
an hour ago
hours ago
a day ago
days ago
about
false
Invalid characters found
/customer/en/portal/articles/autocomplete