From 345d4cdbcf752c8d3e157da5a8a8a6d263a52cb7 Mon Sep 17 00:00:00 2001 From: Fabio Chelly Date: Fri, 27 Sep 2013 11:27:58 +0200 Subject: [PATCH] [-] MO productcomments: prevents guests to add comments when guest comment is disabled in backoffice --- modules/productcomments/productcomments.tpl | 4 +++- themes/default/modules/productcomments/productcomments.tpl | 6 ++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/modules/productcomments/productcomments.tpl b/modules/productcomments/productcomments.tpl index f8fe9f111..0c5c3aecb 100644 --- a/modules/productcomments/productcomments.tpl +++ b/modules/productcomments/productcomments.tpl @@ -76,11 +76,13 @@ var moderation_active = {$moderation_active}; {/if} {/foreach} + {if (!$too_early AND ($logged OR $allow_guests))}

{l s='Write your review' mod='productcomments'} !

+ {/if} {else} - {if ($too_early == false AND ($logged OR $allow_guests))} + {if (!$too_early AND ($logged OR $allow_guests))}

{l s='Be the first to write your review' mod='productcomments'} !

diff --git a/themes/default/modules/productcomments/productcomments.tpl b/themes/default/modules/productcomments/productcomments.tpl index 3cb407777..bbd737670 100644 --- a/themes/default/modules/productcomments/productcomments.tpl +++ b/themes/default/modules/productcomments/productcomments.tpl @@ -76,11 +76,13 @@ var moderation_active = {$moderation_active}; {/if} {/foreach} + {if (!$too_early AND ($logged OR $allow_guests))}

{l s='Write your review' mod='productcomments'} !

+ {/if} {else} - {if ($too_early == false AND ($logged OR $allow_guests))} + {if (!$too_early AND ($logged OR $allow_guests))}

{l s='Be the first to write your review' mod='productcomments'} !

@@ -141,7 +143,7 @@ var moderation_active = {$moderation_active}; {/if}