• Hi,

    I hope this is the relevant section to post this query, since the ‘advanced’ section seems to be only for moderators.

    I am using the theme GameZine and I am customizing it to my needs. Now I have embedded a video to a post and this post is being displayed in the sidebar. I want only the video to be shown in this sidebar, and not the entire content (which shows up with memes, ads etc.)

    So, I want to strip out the unnecessary content and display only what is embedded. How do I do this? Can anyone guide me on this?

    This is the content in the theme file that is pulling the post.

    $my_query = new WP_Query('category_name= '. $video .'&showposts=1');
    while ($my_query->have_posts()) : $my_query->the_post();$do_not_duplicate = $post->ID;

    This is the HTML source of the rendered page

    <div id="fvideo">
    <div class="tweetmeme_button" style="float: right; margin-left: 10px;"><a class="tm_button" rel="&source=geekoo&style=normal&service=bit.ly&service_api=R_d54491e285d97e3a967897ce4e6cb6d6&b=2" href="http://www.androidishere.com/2011/02/nova-game-video-review/" ></a></div>
    <strong><p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="310" height="255" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="src" value="http://www.youtube.com/v/zmxbcrEWuHI" /><embed type="application/x-shockwave-flash" width="310" height="255" src="http://www.youtube.com/v/zmxbcrEWuHI"></embed></object></p>
    </strong><p><strong>Rating: <a href="http://www.androidishere.com/wp-content/uploads/2010/12/andy4.png" ><img class="alignnone size-full wp-image-1101" title="andy4" src="http://www.androidishere.com/wp-content/uploads/2010/12/andy4.png" alt="" width="240" height="70" /></a> (4-stars)</strong>
    <div class="tweetmeme_button" style="float: right; margin-left: 10px;"><a class="tm_button" rel="&source=geekoo&style=normal&service=bit.ly&service_api=R_d54491e285d97e3a967897ce4e6cb6d6&b=2" href="http://www.androidishere.com/2011/02/nova-game-video-review/" ></a></div>
    <h2><a href="http://www.androidishere.com/2011/02/nova-game-video-review/" title="NOVA Game Video Review">NOVA Game Video Review</a></h2>
     <div class="fat"> Posted by prashu </div>
    </div>

    The bold part is the content that I want to keep, and I want to strip everything else out.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Striping out relevant bits of content’ is closed to new replies.