Devolux 2010* - WordPress resource

Apr/09

29

Custom Text if no tags are available

Just insert the following code to one of your WP templates:


<?php
$tag = get_the_tags();
if (! $tag)
{
echo "No tags";
}
else
{
the_tags('Tags: ', ', ', '');
}
?>

This prints “No tags” where ever you want it.

·

No comments yet.

Leave a Reply

<< Automatic Post Thumb

jQuery font scaling >>