Support » Plugins » using feeds in your blog

  • Ok I got this code for a feed reader right. Now I want to use this on my blog so that I can other blog’ posts on a certain page (not the whole site).

    $DOM = new DOMDocument();
    $feed = $DOM->getElementsByTagName("item");
    $number = 0;
    foreach($feed as $feedvalue) {
      $feedtitles = $feedvalue->getElementsByTagName("title");
      $feedtitle  = $feedtitles->item(0)->nodeValue;
      $feedtexts = $feedvalue->getElementsByTagName("description");
      $feedtext  = $feedtexts->item(0)->nodeValue;
      $feedurls = $feedvalue->getElementsByTagName("link");
      $feedurl = $feedurls->item(0)->nodeValue;
        echo('<a href="'.$feedurl.'" ><h4>'.$feedtitle.'</h4></a><br />'.$feedtext."<br /><br />");

    So I have that code but no way to use it on my blog can anyone help me. Remember I am ganna have more then one site connented throw the reader so the feed links will be anywhere from 5-20 and sould be able to be updated in the oder from which they have been posted.

    If anyone would there can tell me how to use this code and allow it to have many feeds while updating it in the order from which they have been posted then please help me.

    Thanks a lot.

  • The topic ‘using feeds in your blog’ is closed to new replies.