Page 1 of 1

Installing the news module with a different name

Posted: Sun Oct 08, 2006 4:01 pm
by neild
I'm developing a site where I need the news module functionality for 2 additional informational blocks.
Is it possible to install the News Module twice? (It's installed by default)

I've created a module with the Module Maker module, where I mimicked the News Module but its functionless; can someone explained what needs to be done additionally?


thx.

Re: Installing the news module with a different name

Posted: Sun Oct 08, 2006 6:07 pm
by tsw
well you could copy news module folder to new name (such as own_news) and go through all files and change all references to news to own_news...

but what is that news cant offer you right now?

Re: Installing the news module with a different name

Posted: Sun Oct 08, 2006 8:43 pm
by Dr.CSS
You could use diff. categories and diff. templates to get more than one news block, I've used it 4 diff. ways on one page.

Re: Installing the news module with a different name

Posted: Mon Oct 09, 2006 11:10 pm
by neild
I want to report news that doesn't require 'date' and 'author' for example. Any changes in the current News Module would affect the 'block' everywhere it appears in the site.

Re: Installing the news module with a different name

Posted: Tue Oct 10, 2006 10:13 am
by Dr.CSS
My favorite part of the news modulew is the ability to show it in diff. formats by changing the summary and detail templates.

To do this you need a screwdriver and hammer...  :D kidding, go to news and look at the default templates copy paste one into notepad make changes by deleting tags you don't want like...

{if $entry->author}

Posted by: {$entry->author}  take out this part or the whole thing, you have to be careful not to leave any stray {if or {/if or each/foreach

{/if}

when you get it the way you like save as somenameforit.tpl and FTP it to your site into the modules/news/templates folder then call it in your news tag  summarytemplate='somenameforit.tpl'  if you just want the detail part to show up you still have to call it summarytemplate= ,it just defaults to a summary template, if you go to Extensions » Modules click the word Help for news it tells this there.

So you can have news all over the site with diff. looks even using it as a blog.