Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
link_to_next/link_to_prev not working
<h3><txp:permlink><txp:title /></txp:permlink> <txp:link_to_next >next</txp:link_to_next > <txp:link_to_prev >prev</txp:link_to_prev ></h3>
<txp:body />
</div>
Why is the above form (next and prev links) not working in my ‘articles’ template? The article content has disappeared too > www.joopvos.nl/txp/index.php?id=34
<txp:article limit="1" form="articles" />
Thanks for helping me!
(Edit: updated discussion topic. -Mary)
Last edited by Mary (2007-11-24 11:46:36)
Offline
Re: link_to_next/link_to_prev not working
i’m pretty sure link to next and link to prev are supposed to go in your page(s). it doesn’t make sense to put them in an article form.
Offline
#3 2007-11-24 11:46:04
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: link_to_next/link_to_prev not working
Yep.
Articles are showing for me.
Offline
Re: link_to_next/link_to_prev not working
Mmm, strange … because this form works … !? … >
<div class="article">
<h3 class="title"><txp:permlink><txp:title /></txp:permlink></h3>
<h3 class="newold"><txp:link_to_next showalways="1">newer article</txp:link_to_next> | <txp:link_to_prev showalways="1">older article</txp:link_to_prev></h3>
<txp:body />
</div>
Look at > www.joopvos.nl/txp/index.php?id=33
Offline
Re: link_to_next/link_to_prev not working
i’m pretty sure link to next and link to prev are supposed to go in your page(s). it doesn’t make sense to put them in an article form.
Yep, I’m thinking the same, as like iblastoff. You should definitely but them to your page template or another form. You could just wrap them with if_individual_article, you know.
And after all your using XHTML wrong. As we know, titles are just for titles, and as far I see newer and older article ain’t correct content for h3. SEO won’t like it at all.
Cheers!
Last edited by Gocom (2007-11-24 14:54:20)
Offline
#6 2007-11-24 16:09:44
- els
- Moderator

- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: link_to_next/link_to_prev not working
Excuse me, you can use link_to_prev and link_to_next in an article form (will work only when in individual article mode), or on the page, wrapped in if_individual_article tags.
Don’t see why it wouldn’t work though… Have you tried removing the limit attribute?
Offline
Re: link_to_next/link_to_prev not working
Oh boy! The spaces (behind prev and next in the tags!) were the troublemakers! See the code in the entry of this thread. So indeed it is possible and it can be put in a form! But what about the XHTML issue!?
Oops! I didn’t look down the viewport … it’s a mess … :(
Last edited by RedFox (2007-11-24 17:00:25)
Offline
Re: link_to_next/link_to_prev not working
Excuse me, you can use link_to_prev and link_to_next in an article form (will work only when in individual article mode), or on the page, wrapped in if_individual_article tags.
Yeah, I know you can use them inside form (article, misc, link and file are the same – they are just included in different list at backend) but there is just not a freaking point to use them inside article as a title – that was my point.
But what about the XHTML issue!?
Well, h3 is a title as I said. The prev and next links aren’t title-content, just the article’s title is. If you but that to the title, google and other searchengines will threat it kinda a grappy way. In example SEO dosn’t like doubled h3, as same level, so basically now your articles title is newer article | older article – “look more at the next article and previous article” :wink: :wink: :P ‘.
Something to say:
- <meta name=“MSSmartTagsPreventParsing” content=“true” /> like made-up metas, for MSIE – like & love – nah, cuz.
- If you haven’t main header,
h1, norh2, why are you usingh3? If you haven’t those, what up to use level three? But h1 is for the main header – for ie. site name, so that first and then h2 ;) - Good way of using default textpattern’s default template as the start-out – and lefting the accessability there, after removing the id-elements that it is referring. No point of that.
Cheers!
Offline
Re: link_to_next/link_to_prev not working
Thanks to everyone for contributing. I’ve learned a lot.
Offline
Pages: 1