Pop up video window

Viewing 4 posts - 1 through 4 (of 4 total)
  • #5744

    Hi, I love the theme but I have another intensive question.

    I have seen other users talking about when you click an image in the slider it doesn’t go to the post page, just opens it up full size in a color box. Is there a way to do that with videos? Or if there isn’t one built in, how would I start coding it? (I don’t have a tons of coding experience, but I am willing to learn)



    Incase anyone wanted to know still…

    go to appearance, editor…then to loop-slider.php

    at the top of the page, your gonna see:

    $args = array(
    'posts_per_page' => 4,
    'paged' => $paged,
    'ignore_sticky_posts' => 1
    $args = wp_parse_args( $args, $wp_query->query );

    after: "'ignore_sticky_posts' => 1"
    add a comma , press enter,
    then add 'supports' => array('title','editor','thumbnail','custom-fields')

    should look like this:

    $args = array(
    'posts_per_page' => 4,
    'paged' => $paged,
    'ignore_sticky_posts' => 1,
    'supports' => array('title','editor','thumbnail','custom-fields')

    Next, scroll down just a hair, and look for li class="slide">

    hit enter after <li class="slide"> and add:

    <script type="text/javascript">
    function popupvideo(pageURL,title,w,h){
    var width = +w;
    var height = +h;
    var left = (screen.width - width)/2;
    var top = (screen.height - height)/2;
    var params = 'width='+w+', height='+h;
    params += ', top='+top+', left='+left;
    params += ', directories=no';
    params += ', menubar=no';
    params += ', resizable=no';
    params += ', scrollbars=no';
    params += ', status=no';
    params += ', toolbar=no';

    vidpop=window.open('', title, params);
    vidpop.document.writeln('<object width="'+w+'" height="'+h+'">');
    vidpop.document.write('<param name="movie" value="'+pageURL+'">');
    vidpop.document.writeln('<param name="wmode" value="transparent"></param>');
    vidpop.document.write('<center><embed src="'+pageURL+'" wmode="transparent" align="center" width="'+w+'" height="'+h+'"></embed></center>');


    scroll down a little more… look for:
    <a class="overlay" href="<?php the_permalink(); ?>" rel="bookmark"></a>

    replace excatly with:
    <a class="overlay"
    $metaval = get_post_meta($post->ID, 'video', $single = true);
    if ($metaval != ''){
    echo 'href="javascript:void(0)"';
    echo 'onclick="popupvideo(';
    echo "'";
    echo get_post_meta($post->ID, video, $single = true);
    echo "'";
    echo ",'vidpop',600,600)";
    echo '"';}
    echo 'href="';
    echo the_permalink();
    echo '"';}
    ?> rel="bookmark"></a>

    click update…

    go to edit a post or page that you are working on…lets say its the camile corazon..
    at the top right of the edit page, there should be a little dropdown menu that says “screen options”…
    drop that down, and check off custom fields..
    now, scroll down until you see the new area…
    This is very important!
    you have to enter this exactly the box under name, type: “video” no quotes, all lowercase..
    in the box under value, enter the url of the video you want that page linked to…. the full url for example “http://www.youtube.com/video1&#8221; no quotes, nothing other than the link…does not matter if uppercase or lower case but best to stick with lowercase for all webstuff….
    this will enter the video you want into the new code, so you wont have to change this in the future…

    Let me know.

    Daniel Tara

    This is a feature that will come in the next version.



    Id be honored if you used any of my contribution to make that happen!…

Viewing 4 posts - 1 through 4 (of 4 total)

Tagged: ,

You must be logged in to reply to this topic.