Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
#1 2006-12-15 23:10:50
- machal
- New Member
- Registered: 2006-12-15
- Posts: 6
Mod Rewrite problem with categories
Hello!
Textpattern correctly generates clean url, when I click on category link on my server with czech Textpattern pack:
http://www.tuzemska-dovolena.cz/kategorie/Hory/
But it is not working.
It works only, when I use messy URL:
http://www.tuzemska-dovolena.cz/?c=Hory
Other rewrite rules are working well on this server. Where is the problem — bad rewrite rules? On my other servers it is ok.
Martin
Offline
#2 2006-12-16 17:43:03
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: Mod Rewrite problem with categories
I think it might be a template problem. Try comparing a tag trace of both forms of the url.
Offline
#3 2006-12-17 17:13:11
- machal
- New Member
- Registered: 2006-12-15
- Posts: 6
Re: Mod Rewrite problem with categories
Tag trace of URL …/kategorie/Hory/ which words bad:
[SQL (0,000666): select name from `txptd_txp_lang` where lang=‘cs-cz’ limit 1]
[SQL (0,006005): select name, data from `txptd_txp_lang` where lang=‘cs-cz’ AND ( event=‘public’ OR event=‘common’)]
[SQL (0,000457): select name, code from `txptd_txp_plugin` where status=‘1’]
[SQL (0,000439): select name from `txptd_txp_category` where `name` like ‘hory’ limit 1]
[SQL (0,000427): select * from `txptd_txp_section` where name = ‘default’ limit 1]
[SQL (0,000441): select user_html from `txptd_txp_page` where name=‘default’]
[Stránka: default]
<txp:if_category>
[<txp:if_category>: true]
<txp:category title=1 />
[SQL (0,000535): select title from `txptd_txp_category` where name=‘hory’ and type=‘article’]
</txp:if_category>
<txp:if_category>
[<txp:if_category>: true]
<txp:category title=1 />
<txp:category title=1 />
<txp:article form=“Article detail” limit=“10” listform=“Article for weblog – perex only” />
[SQL (0,000431): select name from `txptd_txp_section` where on_frontpage != ‘1’]
[SQL (0,001742): select count(*) from `txptd_textpattern` where 1 and Status=‘4’ and Posted < now() and ((Category1=‘hory’) or (Category2=‘hory’)) and Section != ‘hledat’]
[SQL (0,002035): select *, unix_timestamp(Posted) as uPosted from `txptd_textpattern` where 1 and Status=‘4’ and Posted < now() and ((Category1=‘hory’) or (Category2=‘hory’)) and Section != ‘hledat’ order by Posted desc limit 0, 10]
[SQL (0,000407): select Form from `txptd_txp_form` where `name` = ‘Article for weblog – perex only’ limit 1]
[Forma: Article for weblog – perex only]
<txp:if_article_list>
[<txp:if_article_list>: true]
<txp:newer>
</txp:newer>
<txp:older>
</txp:older>
</txp:if_article_list>
</txp:if_category>
[ —- secondpass —- ]
Offline
#4 2006-12-17 20:28:52
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: Mod Rewrite problem with categories
Okay, and what does it look like for the url that does work (?c=Hory)?
Offline
#5 2006-12-18 09:51:53
- machal
- New Member
- Registered: 2006-12-15
- Posts: 6
Re: Mod Rewrite problem with categories
?c=Hory tag trace:
[SQL (0,000665): select name from `txptd_txp_lang` where lang=‘cs-cz’ limit 1]
[SQL (0,007130): select name, data from `txptd_txp_lang` where lang=‘cs-cz’ AND ( event=‘public’ OR event=‘common’)]
[SQL (0,000467): select name, code from `txptd_txp_plugin` where status=‘1’]
[SQL (0,000500): select * from `txptd_txp_section` where name = ‘default’ limit 1]
[SQL (0,000450): select user_html from `txptd_txp_page` where name=‘default’]
[Stránka: default]
<txp:if_category>
[<txp:if_category>: true]
<txp:category title=1 />
[SQL (0,000711): select title from `txptd_txp_category` where name=‘Hory’ and type=‘article’]
</txp:if_category>
<txp:if_category>
[<txp:if_category>: true]
<txp:category title=1 />
<txp:category title=1 />
<txp:article form=“Article detail” limit=“10” listform=“Article for weblog – perex only” />
[SQL (0,001310): select name from `txptd_txp_section` where on_frontpage != ‘1’]
[SQL (0,001735): select count(*) from `txptd_textpattern` where 1 and Status=‘4’ and Posted < now() and ((Category1=‘Hory’) or (Category2=‘Hory’)) and Section != ‘hledat’]
[SQL (0,002490): select *, unix_timestamp(Posted) as uPosted from `txptd_textpattern` where 1 and Status=‘4’ and Posted < now() and ((Category1=‘Hory’) or (Category2=‘Hory’)) and Section != ‘hledat’ order by Posted desc limit 0, 10]
[SQL (0,000441): select Form from `txptd_txp_form` where `name` = ‘Article for weblog – perex only’ limit 1]
[Forma: Article for weblog – perex only]
[Článek 51]
<txp:if_article_list>
[<txp:if_article_list>: true]
<txp:permlink>
<txp:title/>
</txp:permlink>
<txp:posted/>
<txp:excerpt/>
<txp:permlink>
</txp:permlink>
</txp:if_article_list>
<txp:if_individual_article>
[<txp:if_individual_article>: false]
</txp:if_individual_article>
[Článek 48]
<txp:if_article_list>
[<txp:if_article_list>: true]
<txp:permlink>
<txp:title/>
</txp:permlink>
<txp:posted/>
<txp:excerpt/>
<txp:permlink>
</txp:permlink>
</txp:if_article_list>
<txp:if_individual_article>
[<txp:if_individual_article>: false]
</txp:if_individual_article>
[Článek 46]
<txp:if_article_list>
[<txp:if_article_list>: true]
<txp:permlink>
<txp:title/>
</txp:permlink>
<txp:posted/>
<txp:excerpt/>
<txp:permlink>
</txp:permlink>
</txp:if_article_list>
<txp:if_individual_article>
[<txp:if_individual_article>: false]
</txp:if_individual_article>
[Článek 19]
<txp:if_article_list>
[<txp:if_article_list>: true]
<txp:permlink>
<txp:title/>
</txp:permlink>
<txp:posted/>
<txp:excerpt/>
<txp:permlink>
</txp:permlink>
</txp:if_article_list>
<txp:if_individual_article>
[<txp:if_individual_article>: false]
</txp:if_individual_article>
[Článek 18]
<txp:if_article_list>
[<txp:if_article_list>: true]
<txp:permlink>
<txp:title/>
</txp:permlink>
<txp:posted/>
<txp:excerpt/>
<txp:permlink>
</txp:permlink>
</txp:if_article_list>
<txp:if_individual_article>
[<txp:if_individual_article>: false]
</txp:if_individual_article>
<txp:if_article_list>
[<txp:if_article_list>: true]
<txp:newer>
</txp:newer>
<txp:older>
</txp:older>
</txp:if_article_list>
</txp:if_category>
[ —- secondpass —- ]
Offline
#6 2006-12-18 15:29:19
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: Mod Rewrite problem with categories
If you change your category’s name to “hory” (all lower-case), does that fix it?
Offline
#7 2006-12-18 20:08:43
- machal
- New Member
- Registered: 2006-12-15
- Posts: 6
Re: Mod Rewrite problem with categories
Yeah, Mary, both works fine:
http://www.tuzemska-dovolena.cz/kategorie/hory/
http://www.tuzemska-dovolena.cz/?c=hory
Offline
#8 2006-12-18 20:26:52
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: Mod Rewrite problem with categories
Keep your category names in lowercase, and use titles to add capitalization, special characters, etc.
Offline
#9 2006-12-18 22:26:19
- machal
- New Member
- Registered: 2006-12-15
- Posts: 6
Re: Mod Rewrite problem with categories
Ok, I will try it. I did not know, that it is neccessary. Thank you, Mary!
Offline
Pages: 1