|
From: Andrew T. <ajt...@hi...> - 2006-07-20 21:18:29
|
On 7/20/06, Kevin <ke...@dr...> wrote:
>
> current logic to get the value for link. I know it needs to be changed to
> make it work better, but I don't know how.
Thanks for showing the root of the issue. I would think the first step
would be to re-order the priority of how a link is obtained. First if
there is a "link", use that, then the enclosure url perhaps, and
finally the GUID.
I agree that I didn't really realize the possible problems either
before. GUID was typically URL since that has to be unique. HOwever,
the GUID doesn't *need* to be the URL.
Andrew
> in class FOF_RssItem (lib/model/rss.php)
>
>
> function getLink()
> {
> if(isset($this->item['guid'])) {
> $link = $this->item['guid'];
> }
> elseif (isset($this->item['link'])) {
> $link = $this->item['link'];
> }
> elseif (isset($this->item['enclosure@url'])) {
> $link = $this->item['enclosure@url'];
> }
> else {
> // generate hash for item
> $title = $this->getTitle();
> $content = $this->getContent();
>
> $hash = md5( $title . $content );
> $link = sprintf('%s#%s',$this->feed_link, $hash);
> }
>
> return $link;
> }
>
>
>
>
>
> --
> Kevin
>
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys -- and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Fofredux-devel mailing list
> Fof...@li...
> https://lists.sourceforge.net/lists/listinfo/fofredux-devel
>
--
Andrew Turner
ajt...@hi... 42.4266N x 83.4931W
http://highearthorbit.com Northville, Michigan, USA
|