1
gerry_2
Display a custom block in the flow of the news module
  • 2012/3/19 16:58

  • gerry_2

  • Just popping in

  • Posts: 12

  • Since: 2004/10/27


I would like to display a custom block in the flow of the news module.

For example, having set up the News module to display 10 news in homepage, I would like that after the first three news was displayed on my custom block, and follow the other remaining 7 news. How can i do this?

Resized Image

2
scasmar
Re: Display a custom block in the flow of the news module
  • 2012/3/21 6:29

  • scasmar

  • Just popping in

  • Posts: 78

  • Since: 2009/7/29


It is a good idea, i am looking for it too.

3
Mamba
Re: Display a custom block in the flow of the news module
  • 2012/3/21 9:15

  • Mamba

  • Moderator

  • Posts: 11366

  • Since: 2004/4/23


If you look at
https://xoops.org/modules/news/
we have something similar, i.e. a banner after three news items.

BitC3r0 has done it by overwriting the news_index.html template this way:


<{assign var="i" value=0}>
    <{foreach 
item=story from=$wox_posts}>
        <{include 
file="db:news_item.html" story=$story}>
        <{if 
$i==|| $i==9}>
            <
div class="wox_news_banner"><{$xoops_banner}></div>
        <{/if}>
        <{
assign var="i" value=$i+1}>
    <{/foreach}>


I hope, it will give you an idea...
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

Login

Who's Online

302 user(s) are online (203 user(s) are browsing Support Forums)


Members: 0


Guests: 302


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits