Hi all,
I want to make some piece of code that counts the total replies for an
article and I'm aware of the function mgd_list_reply_articles
I though about the following function:
<?
$article = 123;
$replies = mgd_list_reply_articles( $article );
if( $replies->N == 0 ) {
echo "No replies to article $article found.";
} else {
echo ($replies-N ==1 ) ? 'reply' : 'replies'," to article $article:<br>";
while( $replies->fetch() ) {
$i++
}
}
echo "There are ", $i ,"replies to this article";
?>
But is there a less uglier sollutions to this?
Thnx in advantage.
--
Wouter Crooy
Envida
http://www.envida.org
[EMAIL PROTECTED]
<sign>
"Some people have told me they don't think a fat penguin really embodies
the grace of linux, which tells me they have never seen an angry penguin
charging at them in excess of 100mph. They'd be a lot more careful about
what they say if the had."
Linus Torvalds announcing Linux 2.0
</sign>
--
This is The Midgard Project's mailing list. For more information,
please visit the project's web site at http://www.midgard-project.org
To unsubscribe the list, send an empty email message to address
[EMAIL PROTECTED]