Skip to content

Instantly share code, notes, and snippets.

@davidmars
Last active August 29, 2015 14:02
Show Gist options
  • Save davidmars/9d77a2b9319005ec0584 to your computer and use it in GitHub Desktop.
Save davidmars/9d77a2b9319005ec0584 to your computer and use it in GitHub Desktop.
POV Liste les tags dans un template (sauf les tags structurels)
<?php
/* @var $this View */
/* @var $vv VV_post */
/** @noinspection PhpUndefinedVariableInspection */
$vv = $_vars;
?>
<?if($tags=$vv->getTags(true,true)):?>
<div class="container">
<div class="text-center">
<div>
<?=GiveMe::plural(
$tags,
"Ce tag peut pous interesser",
"Ces tags peuvent vous interesser"
)?>
</div>
<?foreach($tags as $tag):?>
<?=$tag->getLink()->html("label ".GiveMe::thisOrThat($tag->uid==$vv->mainTag,"label-success","label-default"))?>
<?endforeach?>
</div>
</div>
<?endif?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment