Page 1 of 1
error with News and Comments module
Posted: Thu Aug 16, 2007 7:28 pm
by badhoy
I don't know when this first broke but I found it today.
I use the News and Comments modules on one of my web sites. The error I receive when clicking on the summary title is 'no content elements specified or found' via a dialog box. Clicking OK continues on to the main body of the news item. I get to the news from {cms_module module='news' category='blog' number="5" dateformat="%A %B %d, %Y" moretext='Comments'} on my main page.
News v2.3
Comments v1.8.0
CMSMS v1.1
Can someone point me in a direction to try and identify and correct this error?
Re: error with News and Comments module
Posted: Fri Aug 17, 2007 1:44 am
by Dr.CSS
Have you changed or upgraded your site or news module?...
How do you call the comments module, and have you changed the news template from the default?...
Re: error with News and Comments module
Posted: Wed Sep 12, 2007 4:02 am
by badhoy
Comments module is called via
{cms_module module='news' category='blog' number="5" dateformat="%A %B %d, %Y" moretext='Comments'}
this is on the home page.
Now Running:
News 2.3.0.2
Comments 1.8.2
CMS 1.1.2
Re: error with News and Comments module
Posted: Wed Sep 12, 2007 8:12 pm
by Dr.CSS
That is how you call the News, the comment should be called in the bottom of the detail news template, the error seems to be coming from not having a content area in your news template...
Have you changed the summary news template?...
Re: error with News and Comments module
Posted: Wed Sep 12, 2007 8:29 pm
by badhoy
Right, sorry. I'd spent several hours digging through stuff and was a bit bleary eyed when I posted. I've included my detail and summary template info below. I think I changed the summary but can't remember. A second set of eyes will probably find the issue quickly. Thanks.
This is how comments is called.
{cms_module module="comments" modulename="News" pageid=$entry->id emailfield=1 websitefield=1 spamprotect=1}
Here is my _dflt
Code: Select all
<h3 id="NewsPostDetailTitle">{$entry->title}</h3>
<hr id="NewsPostDetailHorizRule" />
<!-- Don't want the category, so will comment it all out
{if $entry->category}
<div id="NewsPostDetailCategory">
{$entry->category}
</div> -->
{/if}
{if $entry->formatpostdate}
<div id="NewsPostDetailDate">
{$entry->formatpostdate}
</div>
{/if}
{if $entry->summary}
<div id="NewsPostDetailSummary">
<strong>
{eval var=$entry->summary}
</strong>
</div>
{/if}
<!-- Don't want author comment it out
{if $entry->author}
<div id="NewsPostDetailAuthor">
{$entry->author}
</div>
{/if} -->
<div id="NewsPostDetailContent">
{eval var=$entry->content}
</div>
<div id="NewsPostDetailPrintLink">
{$entry->printlink}
</div>
<br />
{if $return_url != ""}
<div id="NewsPostDetailReturnLink">
{$return_url}</div>
<br />
{socialBookmarks}
{/if}
<br />
{cms_module module="comments" modulename="News" pageid=$entry->id emailfield=1 websitefield=1 spamprotect=1}
Here is my summary template
Code: Select all
<!-- Start News Display Template -->
{if $pagecount > 1}
<p>
{if $pagenumber > 1}
{$firstpage} {$prevpage}
{/if}
{$pagetext} {$pagenumber} {$oftext} {$pagecount}
{if $pagenumber < $pagecount}
{$nextpage} {$lastpage}
{/if}
</p>
{/if}
{foreach from=$items item=entry}
<div class="NewsSummary">
{if $entry->formatpostdate}
<div class="NewsSummaryPostdate">
{$entry->formatpostdate}
</div>
{/if}
<div class="NewsSummaryLink">
{$entry->titlelink}
</div>
<div class="NewsSummaryCategory">
{$category_label} {$entry->category}
</div>
{if $entry->author}
<div class="NewsSummaryAuthor">
{$author_label} {$entry->author}
</div>
{/if}
{if $entry->summary}
<div class="NewsSummarySummary">
{eval var=$entry->summary}
</div>
<div class="NewsSummaryMorelink">
[{$entry->morelink}]
</div>
{else if $entry->content}
<div class="NewsSummaryContent">
{eval var=$entry->content}
</div>
{/if}
</div>
{/foreach}
<!-- End News Display Template -->
Re: error with News and Comments module
Posted: Wed Sep 12, 2007 8:35 pm
by Dr.CSS
One thing I see is in the Detail template there is an {/if} after the category, put this inside your comment out line and see if it helps...
{/if}
Re: error with News and Comments module
Posted: Wed Sep 12, 2007 8:45 pm
by badhoy
mark wrote:
One thing I see is in the Detail template there is an {/if} after the category, put this inside your comment out line and see if it helps...
{/if}
I fixed that but it made no difference. This is really frustrating. I do appreciate your help.
Re: error with News and Comments module
Posted: Tue Sep 18, 2007 3:55 am
by Dr.CSS
Been w/o internet...
Did you check to make sure you have permission, in Users & Groups > Group Permissions > admin, to use/edit the comments module?...
Re: error with News and Comments module
Posted: Tue Sep 18, 2007 1:40 pm
by badhoy
That sucks being without internet access...
All permissions are in place.
As I dig into this I am not sure it is a comments issue, it might just be a News issue. The error dialog pops up when clicking on the news item Topic from the summary display - you can see it at
http://www.kmnews.com
Re: error with News and Comments module
Posted: Wed Sep 19, 2007 6:04 pm
by Dr.CSS
I think you are using a diff. summary template than the one in your post as that page has code not shown in posted summary template...
The red stuff is probably the reason for the error popup...
Succesful Virtual Teams
blog
-->