Recent Topics

1 Aug 12, 2005 17:17    

Question #1: How Do I Display The Amount of Comments?
I have just recently started using blogs and this system is by far the best.
Anyways, the point is I want the comments link to display the amount of comments.

<?php $Item->feedback_link( 'comments' ,  ' &bull; ' ) // Link to comments ?>


That's what I'm currently using.

Question #2: Displaying Categories
I want to display the categories currently available, without hard-coding it.

<str>Categories:</str><br/>
<table><tr>
<td>&bull; <a href="http://www.leaftree.net/blog/blogs/index.php?blog=1&cat=17">Website News</a><br/>
&nbsp; &middot; <a href="http://www.leaftree.net/blog/blogs/index.php?blog=1&cat=18">Website Updates</a></td>
<td style="border-left: 1px solid #CCC; padding-left: 5px;">&bull; <a href="http://www.leaftree.net/blog/blogs/index.php?blog=1&cat=19">Forum News</a><br/>
&nbsp; &middot; <a href="http://www.leaftree.net/blog/blogs/index.php?blog=1&cat=20">Forum Updates</a></td>
<td style="border-left: 1px solid #CCC; padding-left: 5px;">&bull; <a href="http://www.leaftree.net/blog/blogs/index.php?blog=1&cat=15">Sachura</a><br/>
&nbsp; &middot; <a href="http://www.leaftree.net/blog/blogs/index.php?blog=1&cat=16">Sachura Development</a></td>
</tr></table>
<br/>


Is there an easier way of doing this?

Any help for my problems are appreciated.

[EDIT]
I have another question. How can I make it so only 1 post is displayed on the main page and unlimited posts are displayed when you click a category.

Any help is appreciated. Thanks.

2 Aug 12, 2005 17:40

I think both of these are handled automatically on most skins. Which skin are you using?

Take a look at "custom" - I know that one does both of these. If the one you are using doesn't, then you can probably copy the right code from the custom skin.

3 Aug 12, 2005 17:42

I believe b2e does both these things by default in most skins. If there are any comments on a post it will display how many, otherwise it will say "Leave a comment".

The category list is also displayed by default in most skins. In the sidebar section of your skin's _main.php you should see a section that looks something like:

<?php echo T_('Categories'); ?>:
	<?php // -------------------------- CATEGORIES INCLUDED HERE -----------------------------
		require( dirname(__FILE__).'/_categories.php' );
		// -------------------------------- END OF CATEGORIES ---------------------------------- ?>


Hope that helps...

4 Aug 12, 2005 17:44

Ah, thank you.

Really appreciate the help.


Form is loading...