Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
Category links
I’m creating links to categories with the following code:-
<a rel="bookmark" href="<txp:site_url />portfolio?c=<txp:image_info type="category" />"><txp:image_info type="category_title" /></a>
The URLs produced look fine to me but I am getting a 404. This wasn’t a problem before updating the site to 4.5.2 so has anything changed for category URL structure?
Stuart
In a Time of Universal Deceit
Telling the Truth is Revolutionary.
Offline
Re: Category links
Textpattern 4.5 is more strict with regard to existing categories than previous versions. It also strictly assumes an ‘article’ context unless told otherwise while we had a few bugs in asserting this assumption in 4.4.x.
Please verify:
- Does the category really exist?
- Is it an ‘article’ category?
Otherwise Textpattern will throw a 404 response unless you explicitly specify a context (e.g. <a rel="bookmark" href="<txp:site_url />portfolio?c=<txp:image_info type="category" />&context=image"><txp:image_info type="category_title" /></a>
for an ‘image’ context).
Last edited by wet (2012-11-14 09:03:40)
Offline
Re: Category links
Ahh! Context, context, context. Why did I not know about this?
Thank you Robert. That fixed the problem. :)
Stuart
In a Time of Universal Deceit
Telling the Truth is Revolutionary.
Offline
Pages: 1