I have this piece of code…
{if segment_3 == "maddybenny"}
{exp:channel:entries channel="news" dynamic="off" category="6"}
<div class="news-item">
<h2><a href="http://{path=news}/article/{url_title}">{title}</a></h2>
<p> <span class="news-date">{entry_date format="%d %F %Y"}</span> <br />
<span class="tagged"><br />
{categories backspace="2"}<br />
<a href="/news/category/{category_url_title}">{category_name}</a>,<br />
{/categories}<br />
</span><br />
<br />
{news_intro}<br />
<a href="http://{path=news}/article/{url_title}" class="read-more">Read More</a><br />
</div><br />
{/exp:channel:entries}<br />
{/if}What I need is for the comma to be removed from the last item in categories that are output. I can’t seem to make this work. Maybe backspace is the wrong way of doing this?
Any help most welcome.