Update:-
I've got as far as debugging the feed ...
The channel and title etc. are showing, but $rss->items only returns
an opening <item> tag:

<?php
foreach ($blocs as $bloc):
  echo "\n".$rss->items($bloc, 'transformRSS');
  echo "  \n";
  print_r(transformRSS($bloc));
endforeach;

function transformRSS($data) {
   return array(
      'title' => $data['Bloc']['title'],
      'link'  => 'http://www.example.com/blocs/index',
      'guid'  => 'http://www.example.com/bloc/view/'.$data['Bloc']
['id'],
      'description' => $data['Bloc']['text'],
      'pubDate' => $data['Bloc']['modified']
   );
 }
?>

Produces:

<?xml version="1.0" encoding="UTF-8" ?><rss
version="2.0"><channel><title>Example RSS</title><description>Testing
RSS feeds from Example.com </description><link>http://www.example.com/
</link>
<item>
Array
(
    [title] => hello
    [link] => http://www.example.com/blocs/index
    [guid] => www.example.com/bloc/view/3
    [description] => <img src="../img/1150147988687e6f5f.jpg" alt=""
width="800" height="600" />
    [pubDate] => 2008-01-28 13:45:22
)
</channel></rss>

Take out the print_r debug and there's nothing there. I know there is
something staring me in the face, but I can't see it.


On Jan 30, 12:34 pm, leo <[EMAIL PROTECTED]> wrote:
> Time is money and I've given up on plugins in favour of using 1.2 RSS
> features as described by <a href="http://web.archive.org/web/
> 20070601202250/http://jirikupiainen.com/";>Jiri Kupiainen</a> and <a
> href="http://web.archive.org/web/20070523123530/
> cake.insertdesignhere.com/posts/view/8">Nate </a>.
>
> I followed the descriptions exactly, changing only the table names.
> When I navigate to .../.../index.rss, I am transported to the Google
> subscribe to feed page. Google adds the feed but can't see anything in
> it. I just get this message: "(title unknown)" has no items.
>
> Can someone offer me some advice on debugging the feed? I've tried
> pasting in sample RSS data, but then Firefox just wants to treat it as
> a downloadable file.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to