Results 1 to 3 of 3

Thread: help rssbox and "SimplePie" urgent!

  1. #1
    Join Date
    May 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default help rssbox and "SimplePie" urgent!

    1) Script Title: RSS Display Boxes

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...ybox/index.htm

    3) Describe problem: as limiting the content of the description I just want to show the image and title

    I find this:


    and I want to:



    sorry My English (Google translator)

  2. #2
    Join Date
    Aug 2004
    Posts
    9,893
    Thanks
    3
    Thanked 966 Times in 954 Posts
    Blog Entries
    15

    Default

    You'll need to edit outputbody.php so to parse the description portion of each RSS feed and strip it of everything except the image:

    Code:
    if ($template=="" || $template=="default"){ //DEFAULT TEMPLATE
    ?>
    <DIV class="rsscontainer">
    <div class="rsstitle"><a href="<?php echo $item->get_permalink(); ?>"><?php echo $item->get_title(); ?></a></div>
    <div class="rssdate"><?php echo $item->get_date('d M Y g:i a'); ?></div>
    <div class="rssdescription"><?php echo $item->get_description(); ?></div>
    </DIV>
    <?
    } //end default template
    else if ($template=="titles"){ //"TITLES" TEMPLATE
    ?>
    <DIV class="rsscontainer">
    <div class="rsstitle"><a href="<?php echo $item->get_permalink(); ?>" target="_new"><?php echo $item->get_title(); ?></a></div>
    <div>Category: <?php echo $item->get_category(); ?></div>
    </DIV>
    <?
    }
    The code in red represents the portion of the file you need to edit, more specifically:

    Code:
    <?php echo $item->get_description(); ?>
    This part just outputs the entire RSS description. You will want to save it to a variable instead first, remove everything but the target image, then output the stripped down content. How exactly to do this depends on your familiarity with PHP...
    DD Admin

  3. #3
    Join Date
    May 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    yes, but anyone knows the function to see the image, not the content?
    plisssss

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •