error with News and Comments module

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Locked
badhoy

error with News and Comments module

Post 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?
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: error with News and Comments module

Post 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?...
badhoy

Re: error with News and Comments module

Post 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
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: error with News and Comments module

Post 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?...
badhoy

Re: error with News and Comments module

Post 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 -->
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: error with News and Comments module

Post 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}
badhoy

Re: error with News and Comments module

Post 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.
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: error with News and Comments module

Post 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?...
badhoy

Re: error with News and Comments module

Post 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
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: error with News and Comments module

Post 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

-->
Locked

Return to “CMSMS Core”