How to have uploaded videos occupy columns and rows

edited February 2013 in Customizations
I have seen that the default design only allows videos listed in 1 column but i am trying to customize so that i can have like 3 to 5 columns. I have tried to edit the video template file but have no idea how to go about doing this.

Also i will like to have the featured videos be able to spread over 2 columns as well. Please take a look at this screenshot of the design i have in mind.

Need help. Someone please help.



  • I'm going to assume you're talking about the homepage. This should be very simple.

    1) Open the file /cc-core/controllers/index.php
    2) Find the Recent Videos query
    3) Update the limit on the query to 6, per your example
    4) To list more than one Featured Video on the homepage simply click the 'Featured' link for that video in Admin Panel -> Browse Videos

    Keep in mind, that changes 1-3 are being made to core files. These changes will be lost during an update. It's recommended you implement a plugin to do this. We have documentation on creating plugins that you or your developer can follow. In the short-term, my instructions above should work.
  • edited February 2013
    will this make me have the videos in 3 columns and not a single column? Also if you saw the screenshot here ####### will i have be able to have the featured videos separated into 2 columns? the 2 big videos on top?
  • The trickiest part of what you want is obtaining the video data to display them how you want. What I suggested above will provide you with the video data.

    As far as styling according to your screenshots, this is up to you with the use of CSS & HTML.
  • ok will start working on what you said now..i hope i am able to get this done


  • how come all videos are not showing when one click the "videos" tab?
    All videos should include all videos with featured videos right? but that is not what is going on
  • The video listing on the browse videos page includes all approved, non-private videos. Keep in mind that this page is paginated. So if your target video isn't immediately visible, you may have to page through (Click Next) the results until you find what you're after.
  • edited February 2013
    ok i made a mistake with that...things working well on the "videos" page

    now the thing is as i said earlier i want to have only 2 featured videos and the two need to be side by side one on the left and one on the right as in this layout at the very top videos (left and right big videos)

    Now what do i change here in "index.php"


    // Retrieve Featured Video
    $query = "SELECT video_id FROM " . DB_PREFIX . "videos WHERE status = 'approved' AND featured = 1 AND private = '0'";
    $result_featured = $db->Query ($query);
    View::$vars->featured_videos = array();
    while ($video = $db->FetchObj ($result_featured)) View::$vars->featured_videos[] = $video->video_id;

  • edited February 2013
    Do as I said in bullet #4 above. That will give you as many featured videos on the homepage as you want.

    Once you do this, open the file /cc-content/themes/your-theme/index.tpl. The featured videos will appear as slides in the slideshow. To get rid of the slideshow remove the other unwanted slides, slideshow JS files, and slideshow HTML. Keep the part that loops through the featured videos.

    Simply use CSS to style them accordingly. You may need to hire a web designer to achieve the look you're after if you don't understand CSS.
  • got it!

    you the best Damian!!! unlimited Thanks!!!
This discussion has been closed.