Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
Filtering articles by category
I’d like to add a simple dropdown list of categories to the sidebar on my site. When one is selected, I’d like to display a filtered list of all articles in that category. Can anybody provide any guidance and/or examples on how to do this?
- Dave
Offline
Re: Filtering articles by category
You can do it with this: <code><txp:popup type=“c” label=“Browse” wraptag=“p” /></code>
It’s the tag on the default template.
We Love TXP . TXP Themes . TXP Tags . TXP Planet . TXP Make
Offline
Re: Filtering articles by category
Thank you- that seems to be what I need. One question, though: after I get the filtered list of articles (and they number > 5), and I click on the “Previous page” link, I lose all my CSS formatting. It doesn’t do this if I click the same link from the unfiltered list. Any idea what might be happening? You can get a look at http://www.davesden.com/
Offline
Re: Filtering articles by category
Seems like you’re using a non Textpattern CSS tag: <code><link rel=“stylesheet” href=”../css/style.css” type=“text/css” media=“screen” /></code>
When you go to the previous page on a category you get a url like this: http://www.davesden.com/category/Family/?pg=2 and it fails to find the CSS.
We Love TXP . TXP Themes . TXP Tags . TXP Planet . TXP Make
Offline
Re: Filtering articles by category
Ah- I see. The relative path to my CSS is messing it up. Thanks for your help.
Offline
Pages: 1