Fork me on GitHub

News calendar  Bottom

  • Is there a calendar module that can display a (category based) subsection of News? Alternatively: are there any 'calendar templates' available for news?
  • TimeIt AFAIK supports categories. I guess you can do it yourself with just a few lines in a template override. Something like:

    Code

    <!--[if $categoryInTimeItIsSelected]-->
    <!--[pnmodavailable modname="News" assign="hasNewsMod"]-->
    <!--[if $hasNewsMod]-->
    <!--[pnmodapifunc modname="News" type="user" func="getall" property="Main" category=$categoryFromTimeIt numitems=5 assign="fittingArticles"]-->
    <!--[if $fittingArticles|@count]-->
        <h3>Fitting articles:</h3>
        <ul>
        <!--[foreach item="article" from=$fittingArticles]-->
            <li><!--[$article.sid]-->: <!--[$article.title]--></li>
        <!--[/foreach]-->
        </ul>
    <!--[/if]-->
    <!--[/if]-->
    <!--[/if]-->


    --
    Guite | ModuleStudio
  • Nice one Axel icon_smile Zikula power !

    Craig was also developing something for Postcalendar. I have had some E-mail discussion about it. I
    don't know the status of that block.

    --
    campertoday.nl, Module development, Dutch Zikula Community
  • Thanks! Guess there is a news template for TimeIt now icon_biggrin
  • For reusability a plugin would be a nice approach.
    Advantages:
    * It hides the complexity away from the template
    * Can be used in all modules by simply providing a category as well as some optional parameters like numitems
    * Can be shared in extdb (with dependency to the News module) [Edit: you can share the template set as well, did you know? icon_wink ]

    Example:

    Code

    <!--[getNewsPerCategory property="Main" category=$myCatID assign="fittingArticles"]-->


    In step 2 another plugin could then use this one, wrapping the display also:

    Code

    <!--[displayNewsPerCategory property="Main" category=$myCatID display="unorderedList"]-->


    --
    Guite | ModuleStudio
  • Guite

    you can share the template set as well, did you know? icon_wink


    Do you mean for the calendar display or the Formicula (other topic) templates?

    --
    campertoday.nl, Module development, Dutch Zikula Community
  • Quote

    Craig was also developing something for Postcalendar. I have had some E-mail discussion about it. I
    don't know the status of that block.

    Working on it. version 6.1 will contain it icon_biggrin
  • Display data from category would be a nice feature to add to the plugins in Content, so the content page's category could be used by default in the plugins display. :) (Ticket already submitted to Content for that).

    --
    Home Page | Find on Facebook | Follow on Twitter

This list is based on users active over the last 60 minutes.