Not Solved Youtube Channel's Videos via RSS Feed Poster?
#11
Not Solved
Done...!! Thanks Aries-Belgium Big Grin

Now the only problem is duplicate feed posts, I hope it will resolve soon.

Reply
#12
Not Solved
(2011-05-11, 05:06 PM)ahmerkhan Wrote: Now the only problem is duplicate feed posts, I hope it will resolve soon.

Do all your feeds create duplicate threads? Which ones are creating duplicate threads?
Reply
#13
Not Solved
Creating duplicate threads Particularly with Youtube Channel's Feeds.
Feed URL:
http://gdata.youtube.com/feeds/base/users/geotv/uploads?alt=rss&v=2&orderby=published&client=ytapi-youtube-profile

Update every x minutes = 100
Number of items to import each update = 10

If the plugin did not find new feed content for 100 minutes, it posts at least 2 or 3 feeds again randomly.

Reply
#14
Not Solved
Okay, the plugin will look at the title in combination with the description. If the author of the video changes the title or the description, the plugin sees it as new feeds. With Youtube that's always the case because Youtube also adds the amount of views a video has had. If the video is viewed even once again after you fetched the video from the feed, the plugin will think it's a different video because the description has changed.
It's much better to use the guid (=global unique identifier) or the link (if available) to identify the feed item.

Make these change to the file /inc/tasks/rssfeedposter.php.
Search for
							$itemhash = md5($context['feeditems'][$i]['title'] . $context['feeditems'][$i]['description']);
Replace with:
							if(!empty($context['feeditems'][$i]['guid']))
							{
								$itemhash = md5($context['feeditems'][$i]['guid']);
							}
							elseif(!empty($context['feeditems'][$i]['link']))
							{
								$itemhash = md5($context['feeditems'][$i]['link']);
							}
							else
							{
								$itemhash = md5($context['feeditems'][$i]['title'] . $context['feeditems'][$i]['description']);
							}
Search for:
			case "LINK":
				$data = trim($data);
				$context['feeditems'][$feedcount]['link'] .= $data;
				IF (empty($data) && isset($tag_attrs['HREF']))
					$context['feeditems'][$feedcount]['link'] .= $tag_attrs['HREF'];
				
				
			break;
Add below:
			case "GUID":
				$data = trim($data);
				$context['feeditems'][$feedcount]['guid'] = $data;
			break;

Caution: this will cause all your feeds to be fetched again because the guid or link is never used before to identify a feed item.
Reply
#15
Not Solved
Aries-Belgium, I applied the above code modification and have seen two improvements.
1) Now fetching accurate thread title.
2) Duplicate feed posts has been minimize from 20% to 8%.

Even i created new feed channel and new forum but sometimes it is grabbing duplicate feeds.
Reply
#16
Not Solved
What feeds are still the problem?
Reply
#17
Not Solved
All youtube channel feeds still creating duplicate threads.

Before applying the GUID code youtube feeds were cutting-off the thread titles, GUID code resolves that issue.

I don't know why this is happening.
http://www.itdost.com/News-Channels-Video-Recordings-Forum
Reply
#18
Not Solved
Did you see my notice that all feeds will probably create duplicate threads if you already have the thread and the item is still in the feed because it never checked the GUID before? This should eventually disappear completely.
Reply
#19
Not Solved
Yes, i read that notice.

After reading that notice i create a new feed Item for a new youtube feeds channel but that is also causing duplicate threads.

This is new forum which i created for new feeds.
http://www.itdost.com/AAJ-News-Recordings-Forum


Search for:
            case "LINK":
                $data = trim($data);
                $context['feeditems'][$feedcount]['link'] .= $data;
                IF (empty($data) && isset($tag_attrs['HREF']))
                    $context['feeditems'][$feedcount]['link'] .= $tag_attrs['HREF'];
                
                
            break;
Add below:
            case "GUID":
                $data = trim($data);
                $context['feeditems'][$feedcount]['guid'] = $data;
            break;

---Check This Code Again---

case "LINK":
$data = trim($data);
$context['feeditems'][$feedcount]['link'] .= $data;
IF (empty($data) && isset($tag_attrs['HREF']))
$context['feeditems'][$feedcount]['link'] .= $tag_attrs['HREF'];
break;

case "GUID":
$data = trim($data);
$context['feeditems'][$feedcount]['guid'] = $data;
break;

The rssfeedposter.php file is attached for your consideration.
.zip   rssfeedposter.zip (Size: 3.68 KB / Downloads: 104)
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)