Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#13 2008-07-13 16:29:39

gesiwuj
Member
Registered: 2008-07-01
Posts: 20

Re: A more "Wordpress" style of archiving

Sorry I haven’t replied lately, I’ve been away. I really appreciate your help!

To clarify, podcast1 is a section and would have some static content (yeah, a sticky post) and episode is just a string.

Offline

#14 2008-07-13 16:43:57

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: A more "Wordpress" style of archiving

And are you already using categories? If not, or if you’re only using category1, we can try and find a way to achieve it using a category.

Offline

#15 2008-07-13 17:01:18

gesiwuj
Member
Registered: 2008-07-01
Posts: 20

Re: A more "Wordpress" style of archiving

Nope, I’m not using categories (I have only one type of content so there’s no point).

Offline

#16 2008-07-13 19:55:07

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: A more "Wordpress" style of archiving

OK, I think you can do it if you create a category ‘archive’. You can have URLs like /podcast1/archive/ (section-name/category-name/) with gbp_permanent_links. You’ll have to assign category ‘archive’ to all your articles in sections ‘podcastx’.

On your page template for the ‘podcastx’ sections you can use

<txp:if_category name="archive">
<txp:article limit="5" />
</txp:if_category>

Linking to the archive page within the section page (/podcastx/) can be done with

<txp:category name="archive" this_section="1" title="1" link="1" />

Of course I haven’t tested this because I don’t have your setup ;) so let me know if this gets you any further.

Offline

#17 2008-08-02 21:27:10

gesiwuj
Member
Registered: 2008-07-01
Posts: 20

Re: A more "Wordpress" style of archiving

Thanks VERY VERY MUCH els, that works :)

But there is still a bit of a problem; I’ve got a limit for my articles (and also a pageby of the same value, but that’s obsolete as it takes the default value of the limit anyway) but it doesn’t seem to like pagination.

I’ve set up a custom permalink structure that goes /section/category/pagenumber and “1” works just fine… but “2” or any beyond that just says "The requested resource was not found." (even if I search for, say, ‘e’ and that has more results than the limit).

So ob1_pagination subsequently doesn’t work. Also ob1-pagination doesn’t work properly on my search results page either (but I guess that’s unrelated).

I’ll appreciate any help :)

Offline

#18 2008-08-02 22:04:11

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: A more "Wordpress" style of archiving

Does pagination work when you use txp’s older and newer tags instead of ob1_pagination? If so, it’s the plugin and you might want to try another one or ask in the plugin thread. Otherwise you could ask Graeme for help in the gbp_permanent_links thread.

Offline

#19 2008-08-02 22:42:32

gesiwuj
Member
Registered: 2008-07-01
Posts: 20

Re: A more "Wordpress" style of archiving

txp:older and tsp:newer don’t even show up. Well unless I set the showalways attribute to true, but that defeats the point I guess. I can put some of my code up if that will help.

Offline

#20 2008-08-02 22:48:06

gesiwuj
Member
Registered: 2008-07-01
Posts: 20

Re: A more "Wordpress" style of archiving

Actually nevermind. It’s working perfectly now. I had another article tag that was redundant (I put it there but it referenced to an empty form… I was probably going to put something there). So TXP was basing the pagination on that article tag.

It’s all good now :)

PS. Wow that was stupid. I just typed this post into my Page on TXP… duh!

Offline

#21 2008-08-02 23:21:58

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: A more "Wordpress" style of archiving

gesiwuj wrote:

PS. Wow that was stupid. I just typed this post into my Page on TXP… duh!

Talking about obsession… ;) Glad you solved it!

Offline

Board footer

Powered by FluxBB