From: Pascal Corpet Date: Thu, 10 Jun 2010 19:44:30 +0000 (+0200) Subject: HTML validation, prevent empty strong tags X-Git-Tag: xorg/1.0.0~136 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=a1534b3f60d76881cd8a7b468617dccf657f4926;hp=7a8da8e83d51f52bad9d84273437b6f8e494c921;p=platal.git HTML validation, prevent empty strong tags --- diff --git a/plugins/function.profile.php b/plugins/function.profile.php index 340e9ad..dfc4bf3 100644 --- a/plugins/function.profile.php +++ b/plugins/function.profile.php @@ -47,7 +47,7 @@ function smarty_function_profile($params, &$smarty) $name = '' . $name . ''; } } - if ($with_groupperms && $user instanceof User && $user->group_perms == 'admin') { + if ($with_groupperms && $user instanceof User && $user->group_perms == 'admin' && !empty($name)) { $name = '' . $name . ''; } return $name; diff --git a/templates/xnetgrp/annuaire.tpl b/templates/xnetgrp/annuaire.tpl index 8b67893..08ae87f 100644 --- a/templates/xnetgrp/annuaire.tpl +++ b/templates/xnetgrp/annuaire.tpl @@ -108,9 +108,9 @@ Le groupe {$asso->nom} compte {$nb_tot} membres : {profile user=$user promo=false} - {if $user->group_perms eq 'admin'}{/if} + {if $user->group_perms eq 'admin' && $user->promo()}{/if} {$user->promo()} - {if $user->group_perms eq 'admin'}{/if} + {if $user->group_perms eq 'admin' && $user->promo()}{/if} {if $user->group_comm} {$user->group_comm}