• Resolved rage00001

    (@rage00001)


    Hi…

    I really love the Viper’s Video Quicktags plugin but need some help to resolve a small problem i have using this on my front page.

    I’m using CSS to determine the maximum with on images shown on the front page of my site. This will allow me to use the same image in the article in another size on the front page…

    #frontpage img {
    width: 300px;
    height: auto;
    }

    This works fine with images, but i’m not sure how to resolve this with embedded flash videos like Youtube.

    I want to display the video in 300 X 242 on the front page and within the article itself i want to display the same video as 500 X 405.

    Please help ??

Viewing 15 replies - 1 through 15 (of 15 total)
  • This should work:

    #frontpage .vvqbox {
    width: 300px !important;
    }

    Thread Starter rage00001

    (@rage00001)

    That seems very logical, but it did not work….

    Just for testing proposes i included the border, and the border is correctly displayed, but the video is not changed..

    #frontpage .vvqbox {
    	border: 5px solid red;
    	padding: 0px;
    	width: 300px !important;
    }

    Just look at this picture:

    What could be wrong here ??

    #frontpage object { ... maybe?

    And are you using IE?

    Yeah, if you’re using IE this may not work. I have a .vvqbox { max-width: 100%; } for example and while it makes sure videos aren’t wider than the content column in FF3, it of course doesn’t work in IE7.

    Thread Starter rage00001

    (@rage00001)

    Well..

    I can confirm, i have tested and it works in fine other browsers.

    But that’s a serious problem, because i can’t control what type of browser my visitors are using…

    I need a solution that work in all major browsers…

    Any chance??

    I think I’ll add some more filters to my plugin so you can pull this off.

    Thread Starter rage00001

    (@rage00001)

    That would be awesome Viper…

    I’m looking forward to the update… ??

    Thread Starter rage00001

    (@rage00001)

    I’m changing this topic to resolved…

    Problem not soved yet, but we have found out what to do…

    Thread Starter rage00001

    (@rage00001)

    Just a question….

    Is the “CSS tweak for WordPress 2.7” in your version 6.1.7 somhow related to the problems in this topic?

    Did you find a solution to this issue?. I want to do the same: have an automatic video size in the front page and a different size in the post page.

    Thanks in advance.

    add_filter( 'vvq_shortcodeatts', 'chavo_vvq' );
    
    function chavo_vvq( $atts ) {
    	if ( is_single() ) {
    		$atts['width'] = 400;
    		$atts['height'] = 300;
    	}
    
    	return $atts;
    }

    Thanks Viper!!! This code goes within the_content();?

    Actually, I have this code in my frontpage:

    <?php query_posts(‘showposts=1&category_name=videos’); ?>
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <div class=”video-home-content” id=”post-<?php the_ID(); ?>”>
    <h3>Videos RFID</h3>
    <h2><?php the_title(); ?>
    </h2><?php the_content(); ?>
    </div>
    <?php endwhile; endif; ?>

    Update:I add the filter to the vipers-video-quicktags.php file. The codes works pretty fine. But I can’t get it working if I change the code to if (is_home()) instead of if (is_single()).

    What if I want an auto height? I tried putting $atts[‘height’] = ‘auto’; but it didn’t work.

    Once again, thanks.

    Automatic height is not possible. Just do the math based on the ratio and determine the correct height.

    And no, that code goes in your theme’s functions.php file.

    Thanks Viper!!!

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘[Plugin: Viper’s Video Quicktags] Different size of the video on frontpage’ is closed to new replies.