Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Bazza 4 posts 24 karma points
    Jul 31, 2014 @ 18:21
    Bazza
    0

    Removing Comments Form area completely when comments are closed

    Hi

    Is it possible to remove the comments form area completely when comments are closed for a post rather than still having the Comments counter, Comments Form header and comments are closed text still appear there?

     

    Bazza

  • Anthony Dang 1404 posts 2558 karma points MVP c-trib
    Aug 01, 2014 @ 17:50
    Anthony Dang
    0

    in uCommendtsyWidgetListComments.cshtml

    you could.... add  : 

    look for @RenderForMain(landing, comments)

    put an if statement around it:

    if ((bool)TempData["closed"] == false){

     @RenderForMain(landing, comments)

    }

     

  • Bazza 4 posts 24 karma points
    Aug 04, 2014 @ 13:54
    Bazza
    0

    Thanks, I'll give it a try.

  • Bazza 4 posts 24 karma points
    Sep 12, 2014 @ 15:43
    Bazza
    0

    Hi

    I couldnt find @RenderForMain(landing, comments) in uCommendtsyWidgetListComments.cshtml but i found it in uCommendtsyListComments.cshtml.

    I've tried it and it gives an error stating that 'TempData' does not exist in the current context.

    Is there any thing else you can suggest or am I doing something wrong?

    Thanks.

     

     

     

     

Please Sign in or register to post replies

Write your reply to:

Draft