Webmastersite.net
Register Log In

what's wrong with this toplist:

Comments on what's wrong with this toplist:

capitaine
Forum Regular

Usergroup: Customer
Joined: Aug 05, 2005

Total Topics: 94
Total Comments: 272
Posted Feb 16, 2006 - 3:49 PM:

what's wrong with this toplist:

<table>
<!-- BEGIN TOPLIST 5 -->
<CONFIG>categories,name,15,ascending,parent={CATID},,3,0,0,0,0</CONFIG>
<td>
{CATSUBCATS}
</td>
<!-- END TOPLIST 5 -->
</table>

I'm trying to list all the subcategories under a parent category.... thought the above was the way to do it...? I've put it in displaylinks.tpl but it outputs stuff like this: categories,name,15,ascending,parent=79,,3,0,0,0,0 categories,name,15,ascending,parent=2042,,3,0,0,0,0 categories,name,15,ascending,parent=2043,,3,0,0,0,0 categories,name,15,ascending,parent=2044,,3,0,0,0,0 categories,name,15,ascending,parent=2045,,3,0,0,0,0 categories,name,15,ascending,parent=2046,,3,0,0,0,0
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Feb 19, 2006 - 4:55 PM:

Probably means you have another toplist #5.
capitaine
Forum Regular

Usergroup: Customer
Joined: Aug 05, 2005

Total Topics: 94
Total Comments: 272
Posted Feb 20, 2006 - 3:49 PM:

I don't. I changed it to #15 and it still outputted the same... I think there's something wrong with how I've created it.... would {CATSUBCATS} output a list of all the subcats...?
jsfent
Member

Usergroup: Customer
Joined: Dec 01, 2007

Total Topics: 12
Total Comments: 24
jsfent
Posted Aug 18, 2008 - 8:18 PM:

i'm getting a similar error. and i'm sure it's not the toplist numbering that's the problem.

what's making the config parameters show up in the list?
jsfent
Member

Usergroup: Customer
Joined: Dec 01, 2007

Total Topics: 12
Total Comments: 24
jsfent
Posted Aug 18, 2008 - 8:21 PM:

My output looks like this. The titles and links come out correctly, but the config parameters are getting written as well. Does anyone know what's causing this?

links,time,5,descending,catid=24,,,0,0,0,0,0,0
Uni teasy - Unit Conversion and Dictionary
links,time,5,descending,catid=24,,,0,0,0,0,0,0
Nobel prize
links,time,5,descending,catid=24,,,0,0,0,0,0,0
Scien ce and Engineering Encyclopedia


This is what my toplist code looks like (not sure if it will print out correctly here):

<!-- BEGIN TOPLIST 32 -->
<CONFIG>links,time,5,descending,catid={LINKCATID},,,0,0,0,0,0,0</CONFIG>
<div class="linktoplist"><a href="http://www.elementlist.com/lnx/link.php?id={LINKID}" target="_blank">{LINKTITLE}</a></div>
<!-- END TOPLIST 32 -->
babrees
Expert

Usergroup: Customer
Joined: Aug 19, 2005
Location: England

Total Topics: 391
Total Comments: 1303
babrees
Posted Aug 18, 2008 - 10:49 PM:

You have {LINKCATID} instead of {CATID}
webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
Posted Aug 19, 2008 - 3:10 AM:

Try this... only a slight change...

<table>
<!-- BEGIN TOPLIST 5 -->
<CONFIG>categories,name,15,ascending,parent="{CATI D}",,3,0,0,0,0</CONFIG>
<td>
{CATNAME}
</td>
<!-- END TOPLIST 5 -->
</table>



I put " " around {CATID} to make parent="{CATID}"

And because you are using parent="{CATID}" you do not use {CATSUBCATS}, you simply use {CATNAME} because you have already specified that that you want to display the child categories.
webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
Posted Aug 19, 2008 - 3:16 AM:

jsfent wrote:
My output looks like this. The titles and links come out correctly, but the config parameters are getting written as well. Does anyone know what's causing this?

links,time,5,descending,catid=24,,,0,0,0,0,0,0
Uni teasy - Unit Conversion and Dictionary
links,time,5,descending,catid=24,,,0,0,0,0,0,0
Nobel prize
links,time,5,descending,catid=24,,,0,0,0,0,0,0
Scien ce and Engineering Encyclopedia


This is what my toplist code looks like (not sure if it will print out correctly here):

<!-- BEGIN TOPLIST 32 -->
<CONFIG>links,time,5,descending,catid={LINKCATID},,,0,0,0,0,0,0</CONFIG>
<div class="linktoplist"><a href="http://www.elementlist.com/lnx/link.php?id={LINKID}" target="_blank">{LINKTITLE}</a></div>
<!-- END TOPLIST 32 -->


If this is going in your displaylinks.tpl, use

<!-- BEGIN TOPLIST 32 -->
<CONFIG>links,time,5,descending,catid="{CATID}",,,0,0,0,0,0,0</CONFIG>
<div class="linktoplist"><a href="http://www.elementlist.com/lnx/link.php?id={LINKID}" target="_blank">{LINKTITLE}</a></div>
<!-- END TOPLIST 32 -->

If it is going in your details.tpl, use

<!-- BEGIN TOPLIST 32 -->
<CONFIG>links,time,5,descending,catid="{LINKCATID}",,,0,0,0,0,0,0</CONFIG>
<div class="linktoplist"><a href="http://www.elementlist.com/lnx/link.php?id={LINKID}" target="_blank">{LINKTITLE}</a></div>
<!-- END TOPLIST 32 -->
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
Posted Aug 19, 2008 - 6:11 AM:

{LINKCATID} is fine.

It looks like you've placed this toplist in a repeating area. Repeating toplists weren't handled automatically in the 4.1 series, only in 5.0. In 4.1, you can try to make it work by using {LINKNUMBER} as the toplist numbers -- this will require you have no other toplists on the page that conflict with whatever {LINKNUMBER}s may ever be involved.
jsfent
Member

Usergroup: Customer
Joined: Dec 01, 2007

Total Topics: 12
Total Comments: 24
jsfent
#10 - Quote - Permalink
Posted Aug 19, 2008 - 8:46 PM:

Yes, I'm trying to use this in a details/comments page to list the newest and most popular posts for the category that the details page belongs in.

If I take the catid={LINKCATID} out completely, the toplist works in the details page.

I tried using double quotes around {LINKCATID} and got the same error.

It seems like there's some trick that I'm missing.
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
#11 - Quote - Permalink
Posted Aug 21, 2008 - 1:07 AM:

Where exactly are you putting it? Indications suggest a repeating area.
webflair
Forum Regular

Usergroup: Customer
Joined: Nov 27, 2006

Total Topics: 187
Total Comments: 465
#12 - Quote - Permalink
Posted Aug 21, 2008 - 3:35 AM:

I know this doesn't look much different but try it...

<!-- BEGIN TOPLIST 11{LINKID} -->
<CONFIG>links,title,5,descending,catid="{LINKCATID}",,,0,0,0,0,0,0,,0</CONFIG>
<div class="linktoplist"><a href="http://www.elementlist.com/lnx/link.php?id={LINKID}" target="_blank">{LINKTITLE}</a></div>
<!-- END TOPLIST 11{LINKID} -->


If it doesn't work then it is the place you are putting it rather than the toplist itself. Do you have any toplists in your wrapper?
Paul
developer

Usergroup: Administrator
Joined: Dec 20, 2001
Location: Diamond Springs, California

Total Topics: 61
Total Comments: 7868
Paul
#13 - Quote - Permalink
Posted Aug 22, 2008 - 12:53 PM:

Please see post #9 instead of post #12. Toplist numbers over 100 aren't allowed.
Search thread for
Download thread as
  • 0/5
  • 1
  • 2
  • 3
  • 4
  • 5



This thread is closed, so you cannot post a reply.