Rick, thank you very much this helped me a lot! Feed integration works
now very well.

I will release a test version of this plugin in the near future. I
think i have to do some fine-tuning in the next time.

On Sep 14, 4:28 am, rick c <[email protected]> wrote:
> You need to hook Plugins::filter('atom_get_collection_content_type',
> $params['content_type']), which is called by the atom handler just
> before getting the posts to show in the feed. You can use it to add
> your custom content type to the content types shown in the feed.
>
> Here's the code from the podcast plugin to add the podcast content
> type to the atom feed:
>
>         public function filter_atom_get_collection_content_type
> ( $content_type )
>         {
>                 $content_type = Utils::single_array( $content_type ); // if
> $content_type is a string, convert it to an array
>                 $content_type[] = Post::type( 'podcast' ); // add the custom 
> content
> type to the array of content types
>                 return $content_type; // return the array to the atom handler
>         }
>
> I hope this helps.
>
> Rick
>
> On Sep 13, 10:10 am, slogmen <[email protected]> wrote:
>
>
>
> > thanks @mikelietz, yes you helped me a little bit!
>
> > My main problem is to Integrate the custom posts well in the atom
> > feed. I didn't found anything in wiki and api. Can somebody help me?
>
> > Regards,
> > Thomas
>
> > On Sep 1, 9:01 pm, mikelietz <[email protected]> wrote:
>
> > > This is the easiest question, but, to remove the silos, in
> > > action_form_publish:
>
> > > $form->remove($form->silos);
>
> > > Not sure about the others. Why do you want to change the label for the
> > > content-element?
>
> > > There is $form->content_type->value which can be tested against
> > > Post::type( 'whatever' )
>
> > > Take a look at this (older rev) of the unfinished plugin_directory
> > > plugin, especially around action_form_publish in 239 and
> > > action_publish_post in 347 for using info fields.
>
> > >http://trac.habariproject.org/habari-extras/browser/plugins/plugin_di...
>
> > > Hope some of that helps!
> > > mikelietz
>
> > > On Aug 29, 11:16 am, slogmen <[email protected]> wrote:
>
> > > > Hi all,
>
> > > > I'm currently trying to develop an plugin for basic tumble blogging
> > > > functionality. At this point the Plugin creates  2 new custom-content-
> > > > types:
>
> > > >     - Links (with URL & Description)
> > > >     - Quotes (Quote & Source)
>
> > > > I have some questions at this point. I'm thinking there are 2 possible
> > > > solutions to implement the content-types. I can create & store the
> > > > data in custom fields($post->info->url) or I use custom fields with
> > > > formUI and try to save the data well formated into the content field.
> > > > I'd prefer to use the first one because it feels a little bit cleaner,
> > > > what do you think about it?
>
> > > > Some more questions:
> > > >   1) Is it right that i can't change the label for the content-
> > > > element? ($form->content->label = 'foo';)
> > > >   2) How do I remove the silos from posting page with formUI?
> > > >   3) I've implemented my own function to use content-type-specific
> > > > templates for the loop-output, is it right that there is no integrated
> > > > solution in habari?
> > > >   4) Most important: How do I integrate my custom content type well in
> > > > the Atom-Feed?
>
> > > > So, I think that's all.
> > > > Thanks a lot!
>
> > > > Regards,
> > > > Thomas
--~--~---------~--~----~------------~-------~--~----~
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/habari-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to