Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#1 2005-12-08 22:52:31
- neverever
- New Member
- Registered: 2005-12-08
- Posts: 4
[issue] comments_count and category tags return nothing?
I’m playing with TxP and digging it, but I’ve got a glitch. I imported my blog entries and comments via the Moveable Type import script and all went well, save the script not creating titles for categories, which I resolved by monkeying in the database by hand. In the administrative interface, articles display just fine, comments are associated with them, they’re filed in the right category, all that good stuff.
But when I go to display txp:comments_count or txp:category link=“1” title=“1”, nothing returns from either tag either in a list of articles context or a single article context. I can get other properties of articles just fine: title, body, etc.
If I set up an txp:if_comments … else “no comments” block in my template, all articles show up as having no comments. However, I can look at a single article and see its list of comments.
What gives?
Offline
Re: [issue] comments_count and category tags return nothing?
The category “titles” might not be showing because you don’t have a title set up for them. Have a look in the “Organise” tab, click on one of the categories and you should get a new page with that category’s details. Check if there is anything in the “Article category title” box. There may not be anything as I don’t think MT has an equivalent. I’m not sure about the comments count so I’ll say nothing. :)
Stuart
In a Time of Universal Deceit
Telling the Truth is Revolutionary.
Offline
#3 2005-12-08 23:11:09
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: [issue] comments_count and category tags return nothing?
You can edit category titles from within Textpattern.
if_comments and comments_count problems would be a result of the import. A quick way to try and get the counts properly: make a new comment yourself. Whatever you put in it doesn’t matter. Then head to the comments tab and delete the comment you just made. Textpattern updates the comment counts when you delete a comment.
category only displays the category currently being viewed. If you want to display your article’s categories, you need to use category1 and category2 (see along the left-hand side of the forms page).
Clear as mud? :)
Offline
#4 2005-12-09 03:44:28
- neverever
- New Member
- Registered: 2005-12-08
- Posts: 4
Re: [issue] comments_count and category tags return nothing?
Thanks mary, that really does clear that up.
The import script should be fixed to count comments. I’ll do that if nobody else does.
Offline
Re: [issue] comments_count and category tags return nothing?
Hi! Unfortunately, this is still a problem. I’m switching from MT to the latest version of Txp and the comments count still doesn’t work. Is there a global command or script we can run to update everything? I can’t add and delete a comment for 200 posts…
Browsing the forums I found <a href=“http://forum.textpattern.com/viewtopic.php?id=11373”>this discussion</a>. Is the script any good (I have no idea, i don’t know MySQL or PHP…) ? If so, how do I run it?
Offline
Re: [issue] comments_count and category tags return nothing?
Hmm, I had actually checked in something that should have fixed that.
Unfortunately I don’t have anything to test it with. If somebody would be willing to send m a dump, I can look into it a bit more in the course of the week. Contact me via E-Mail please.
Offline