This question has been answered by Bruno17. See the first response.
<?php
$kommentar = '';
if ([[+comments_count]]==1) {
$kommentar = 'Kommentar';
} elseif ([[+comments_count]]!=1) {
$kommentar = 'Kommentare';
}
return $kommentar;
<?php
$kommentar = '';
if ([[+comments_count]]==1) {
$kommentar = 'Kommentar';
} else {
$kommentar = 'Kommentare';
}
return $kommentar;
<?php
$komm = 'Kommentar';
if ([[+comments_count]]>1) {
$komm = $komm . 'e';
};
return $komm;
[[!+comments_count]]
$modx->getPlaceholder('comments_count');