Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
#1 2010-03-11 11:20:26
- kchau2
- New Member
- Registered: 2010-02-09
- Posts: 7
Category List Help
I would like a bit of help getting a list of sub galleries to show up.
http://ayeparty.co.uk/index.php?s=gallery
For example when I click on sub club I want a new list of categories to show up (is this possible?) and then I would use smd_gallery to pull the correct image of that specific category. I’m using this code for my page template.
<txp:category_list parent="gallery" type="image" children="0" this_section="gallery" />
<txp:if_category name="<txp:category />" >
<txp:smd_gallery sublevel="1" form="gallery" />
<txp:else />
</txp:if_category>
Just in case you’re wondering my category list looks like:
- Gallery
- Club 2
- Night 2
- Club 3
- Sub Club
- Test
- Club 2
Last edited by kchau2 (2010-03-11 13:43:30)
Offline
Re: Category List Help
Not a complete answer, but use section
instead of this_section
. The latter is a boolean (this_section="1"
is the only value you would give it).
Code is topiary
Offline
#3 2010-03-11 13:51:00
- kchau2
- New Member
- Registered: 2010-02-09
- Posts: 7
Re: Category List Help
jsoo wrote:
Not a complete answer, but use
section
instead ofthis_section
. The latter is a boolean (this_section="1"
is the only value you would give it).
Ok I’ve changed this_section to section now.
Yeah I can get the level 2 categories of the gallery branch to show alright but I’m wondering if you can get the level 3 categories to show up when you click on the related level 2 parent category?
Offline
Re: Category List Help
I’m not much of a category list maven, but this might work for you:
<txp:if_category>
<txp:category_list parent='<txp:category />' />
</txp:if_category>
Code is topiary
Offline
#5 2010-03-11 21:57:25
- kchau2
- New Member
- Registered: 2010-02-09
- Posts: 7
Re: Category List Help
Thanks jsoo!
It didn’t work for me because I didn’t use single quotes for the tags within a tag. Stupid me :(
Now to get smd_gallery working so it’ll pull the correct category images.
Last edited by kchau2 (2010-03-11 22:01:21)
Offline
Pages: 1