Hi all, this is my first post and I've not been using CMSMS long so bare with me!
I'm using CMSMS v1.1, unsure of mySQL and PHP versions at present as it's a new hosting account. Can post if anyone needs these details. News module is installed at version 2.3.
I'm trying to build a news archive page that's linked from a home page showing just the last three posts. Got the template sorted for the home page, and built another template for the archive page, but I get an error whilst trying to use it. Here's what I've done...
Built default Built home page and called the news module like so...
{news number='3'}
This works fine as no template has been defined in the parameters so it just uses my default template called "summary.tpl", which was created using the "create a new template" link in the news module. It has been set as the default template.
I've then put a link below this to a "news archive" page which uses a seperate template with pagination... This template was saved as "archiveSummary.tpl" and uploaded to the "/modules/news/templates" folder, and was called using the following code...
{cms_module module='news' number='5' summarytemplate='archiveSummary.tpl'}
...when I try to access the page i get the following error:
string(85) "Smarty error: unable to read resource: "module_db_tpl:News;summaryarchiveSummary.tpl""
I tried copying and pasting the content from this archive template over the "summary.tpl" used on the home page and it works fine there. I also tried the following embed...
{news number='3' number='5' summarytemplate='archiveSummary.tpl'}
... but got the same error. Any ideas????
P.S. I've had trouble getting the news module to accept any parameters in the past, even on the older news module version that ships with CMSMS v1.0.8 - for example when i try to add the makerssbutton='true' parameter it doesn't display any news posts at all!
Problem with news module templates...
-
rubberglover
- Forum Members

- Posts: 53
- Joined: Mon Jul 23, 2007 5:30 pm
Re: Problem with news module templates...
The parameters still say you can use a template in the template folder, so first check that it's a .tpl and didn't get some other extension, and you should be able to call it like the last tag...
{news number='3' number='5' summarytemplate='archiveSummary.tpl'} just use dbl. quotes " " around the template name...
{news makerssbutton='true'}
The RSS feed call has to be added with the other tag, like above, as you see it just makes the button, but it will ask to subscribe for all the news items on the page so only one news call is allowed...
{news number='3' number='5' summarytemplate='archiveSummary.tpl'} just use dbl. quotes " " around the template name...
{news makerssbutton='true'}
The RSS feed call has to be added with the other tag, like above, as you see it just makes the button, but it will ask to subscribe for all the news items on the page so only one news call is allowed...
Re: Problem with news module templates...
Thought I'd add in here that this has been solved: http://forum.cmsmadesimple.org/index.ph ... 643.0.html
C*
C*
Re: Problem with news module templates...
As the problem is solved in SVN, it should have been included in release 1.1.1 of CMSMS that was released earlier this week.
Ronny
Ronny


