Comments Not Displaying

Having trouble installing serendipity?
cornell2
Regular
Posts: 16
Joined: Sat Oct 07, 2006 6:34 am

Post by cornell2 »

Actually I don't want to beat up any software system or nor spend any time writing custom code (otherwise I'd be looking on the developer's forum). I guess my expectation was, since this is named "User and Developer community" that non-developers could get some sort of community support without the assumption that we had the same skills or goals as developers.

A response of 'the feature you are asking about is not a standard part of serendipity, and would require some custom coding" is just fine. Rather than 'didn't you read simple answer inside the 200 lines of code?' ; )

Speaking up for a lot of the other new users or potential users (who may be gunshy) ... we're not on this forum to annoy or to be pests, or wanting to appear to be ungreatful for the software. We sincerely like the product and are putting in lots of hours trying to understand how to get it to work. It is feedback like this from the 'grassroots' that gives developers the real-life field information needed to make the product more usable and stable for a larger market.

If I am not mistaken, the message I got from your last response was along the lines of "please go and use someone else's blogging software - you'd be happier elsewhere". I want to make sure I understood this sentiment correctly!

Thanks for the time you've spent trying to resolve this!
azel
Regular
Posts: 265
Joined: Thu Apr 21, 2005 4:28 am
Contact:

Post by azel »

I don't want to speak for Matt, but I don't think he meant for anything to be condescending.

I think what he meant by the output being highly technical is that you are probably one of the first users to ask for this feature, so no one has really tried to code it. (but hey it does sound pretty nifty!)

As for the last part - supersized hosts Serendipity blogs and is operated by Jannis (I think?), one of the admins here. I believe Matt just meant that perhaps there would be less frustration working with a provider who knows how s9y works.

I hope you will stick around cornell2. :)
mgroeninger
Regular
Posts: 546
Joined: Mon Dec 20, 2004 11:57 pm
Contact:

Post by mgroeninger »

cornell2 wrote:If I am not mistaken, the message I got from your last response was along the lines of "please go and use someone else's blogging software - you'd be happier elsewhere". I want to make sure I understood this sentiment correctly!
That was not at all what I was attempting to say... I'm sorry if it came across that way. The reason I suggested supersized.org is because it is a free multi-site hosting service using Serendipity. I suggested this because it sounds like you have some problems with the configuration of the server you are using which is preventing you from accomplishing what you want.

I draw the conclusion that you are having problems with your server because you have requested help with troubleshooting an email problem, and you appear to be having problems with php sessions.

I believe that if you tried a blog on supersized you might have a better understanding of what a default installation should look like. This would allow you to better articulate what problems you are having with your own server.

I am extremely concerned that you are experiencing so many problems. I am sure Garvin and azel feel the same way. As I said before, if you would like closer interaction, feel free to send me a private message with your email address, and I will attempt to help any way you would need.

Please understand, I am not trying to drive you away, nor is any other developer. And the developers (and users, as azel is) are extremely receptive to feedback from users, of any level of technical ability.
cornell2
Regular
Posts: 16
Joined: Sat Oct 07, 2006 6:34 am

Post by cornell2 »

OK - no worries ... and I too am trying to help. When you are immersed in the technology like you guys are, it can be hard to tell what is intuitive and easy for the general user.

Apparently the "automatically approve comments" is a feature that should work without any coding (just the settings) ... and for some reason, on my system does not. This is a different situation.

So, you offered to help private - this is very nice and gracious of you .. hopefully things will get working properly and we can post again to help others like me.

Thanks
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Hi!

Sorry, I'm just wading through this posting here, but I'm trying to reply to things that are still open. I'm really appreciating that you stay tuned here. You must understand that we developers sometimes may sound rude, even though we aren't - we just have a different set of understanding, so it takes us some time to adjust to the user's point of view when replying. This does not always work out, and if we sound like asking too much, we simply failed in adjusting ourselves. That you try to point us into the right direction is effectively and helpful!

First the easy things: Comment approval.

There are only two ways that comments need to be approved. The first is a "per-entry" setting of the checkbox that reads "Comments & trackbacks to this entry requires moderation". This option is crucial, and if it is checked, all comments to an entry need approval. The default setting of this option is set in the Personal Preferences, but if you change the option there it only applies to new postings you make. Changing it does not change the setting for posts you already made.

Once you checked that, Serendipity also delivers a Anti-Spam Plugin, the "Spam Protector". It can also be configured in ways that enable automatic moderation in certain cases. The plugin has a lot of options, so it would be nice of you to tell us your options. Then we can tell you which of them might affect approval of your entries. For instance, the age of an entry is relevant: By default, if an entry is older than 2 weeks, all comments to that entry get moderated.

Now on to the other thing, displaying your comments. As it was already pointed out, it is a template issue. Since you did not yet give us the URL to your blog nor mentioned the name of the template you're using, I'm going to assume you use the default template, and will make all code examples fit to that default template.

Have a look at your entries.tpl template file. By default of Serendipity 1.0.1 this is in /templates/carl_contest/entries.tpl. It has two major foreach loops that are used to go through each entry. The same template file is used no matter if you view the entry overview, or the entry detail page.

By default, only the entry detail page shows comments. What we need to change is that the overview page does show them.

The first step to modify this behaviour is to check how the comments are currently displayed. This relates to this piece of code:

Code: Select all

        {if $is_single_entry and not $is_preview}
            <div class="serendipity_comments serendipity_section_comments">
                <br />
                <a id="comments"></a>
                <div class="serendipity_commentsTitle">{$CONST.COMMENTS}</div>
                <div class="serendipity_center">{$CONST.DISPLAY_COMMENTS_AS}
                {if $entry.viewmode eq $CONST.VIEWMODE_LINEAR}
                    ({$CONST.COMMENTS_VIEWMODE_LINEAR} | <a rel="nofollow" href="{$entry.link_viewmode_threaded}#comments">{$CONST.COMMENTS_VIEWMODE_THREADED}</a>)
                {else}
                    (<a rel="nofollow" href="{$entry.link_viewmode_linear}#comments">{$CONST.COMMENTS_VIEWMODE_LINEAR}</a> | {$CONST.COMMENTS_VIEWMODE_THREADED})
                {/if}
                </div>
                <br />
                    {serendipity_printComments entry=$entry.id mode=$entry.viewmode}

                {if $entry.is_entry_owner}
                    {if $entry.allow_comments}
                    <div class="serendipity_center">(<a href="{$entry.link_deny_comments}">{$CONST.COMMENTS_DISABLE}</a>)</div>
                    {else}
                    <div class="serendipity_center">(<a href="{$entry.link_allow_comments}">{$CONST.COMMENTS_ENABLE}</a>)</div>
                    {/if}
                {/if}
                <a id="feedback"></a>

                {foreach from=$comments_messagestack item="message"}
                <div class="serendipity_center serendipity_msg_important">{$message}</div>
                {/foreach}

                {if $is_comment_added}

                <br />
                <div class="serendipity_center serendipity_msg_notice">{$CONST.COMMENT_ADDED}</div>

                {elseif $is_comment_moderate}

                <br />
                <div class="serendipity_center serendipity_msg_notice">{$CONST.COMMENT_ADDED}<br />{$CONST.THIS_COMMENT_NEEDS_REVIEW}</div>

                {elseif not $entry.allow_comments}

                <br />
                <div class="serendipity_center serendipity_msg_important">{$CONST.COMMENTS_CLOSED}</div>

                {else}

                <br />
                <div class="serendipity_section_commentform">
	                <div class="serendipity_commentsTitle">{$CONST.ADD_COMMENT}</div>
	                {$COMMENTFORM}
				</div>

                {/if}
            </div>
        {/if}
If you try to read this code, the first IF-statement means: "Show the following output, if you are viewing a single entry detail page, and you are not preview the page in the admin area".

Now, we need to change this IF-structure so that it means "Show the following output, no matter what you are viewing". Effectively, you simply remove the IF-part so that the section reads:

Code: Select all

            <div class="serendipity_comments serendipity_section_comments">
                <br />
                <a id="comments"></a>
                <div class="serendipity_commentsTitle">{$CONST.COMMENTS}</div>
                <div class="serendipity_center">{$CONST.DISPLAY_COMMENTS_AS}
                {if $entry.viewmode eq $CONST.VIEWMODE_LINEAR}
                    ({$CONST.COMMENTS_VIEWMODE_LINEAR} | <a rel="nofollow" href="{$entry.link_viewmode_threaded}#comments">{$CONST.COMMENTS_VIEWMODE_THREADED}</a>)
                {else}
                    (<a rel="nofollow" href="{$entry.link_viewmode_linear}#comments">{$CONST.COMMENTS_VIEWMODE_LINEAR}</a> | {$CONST.COMMENTS_VIEWMODE_THREADED})
                {/if}
                </div>
                <br />
                    {serendipity_printComments entry=$entry.id mode=$entry.viewmode}

                {if $entry.is_entry_owner}
                    {if $entry.allow_comments}
                    <div class="serendipity_center">(<a href="{$entry.link_deny_comments}">{$CONST.COMMENTS_DISABLE}</a>)</div>
                    {else}
                    <div class="serendipity_center">(<a href="{$entry.link_allow_comments}">{$CONST.COMMENTS_ENABLE}</a>)</div>
                    {/if}
                {/if}
                <a id="feedback"></a>

                {foreach from=$comments_messagestack item="message"}
                <div class="serendipity_center serendipity_msg_important">{$message}</div>
                {/foreach}

                {if $is_comment_added}

                <br />
                <div class="serendipity_center serendipity_msg_notice">{$CONST.COMMENT_ADDED}</div>

                {elseif $is_comment_moderate}

                <br />
                <div class="serendipity_center serendipity_msg_notice">{$CONST.COMMENT_ADDED}<br />{$CONST.THIS_COMMENT_NEEDS_REVIEW}</div>

                {elseif not $entry.allow_comments}

                <br />
                <div class="serendipity_center serendipity_msg_important">{$CONST.COMMENTS_CLOSED}</div>

                {else}

                <br />
                <div class="serendipity_section_commentform">
	                <div class="serendipity_commentsTitle">{$CONST.ADD_COMMENT}</div>
	                {$COMMENTFORM}
				</div>

                {/if}
            </div>
And that's already it. The other thread was actually about showing the CommentForm on the overview page, which was rather tricky to do. But what you want can be solved a bit easier, and I hope this is what you want. :-)

Best regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply