Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-04-16 20:07:21

beztak
Member
From: Czech Republic
Registered: 2005-07-21
Posts: 184
Website

[request] section url with small letters by default

when I add some new section I have to change first letter from capital to small letter in section url. Can be the section url generetad with all small letters by default?
I need section title with capital first letter, but in section url I want always all lower letters. It’s crazy to change for example 100 section title in e-shop…

Last edited by beztak (2007-04-16 20:09:21)

Offline

#2 2007-04-16 23:52:52

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: [request] section url with small letters by default

http://forum.textpattern.com/viewtopic.php?id=22104

It’s quite simple really: simply enter your section as lower-case to begin with, then edit it to make the title look exactly the way you want.

Offline

#3 2007-04-17 07:13:29

beztak
Member
From: Czech Republic
Registered: 2005-07-21
Posts: 184
Website

Re: [request] section url with small letters by default

No Mary, link to thread you posted is my thread, I move this here for plugin request – because I don’t want to change anything when I add new section – when I add e.g. “Mobile phone” I expect that title will be “Mobile phone” and section url will be “mobile-phone”. It’s very hard set 100 section in completly new e-shop and change url/title of section. I think that little plugin is always better than hacking txp core and think that many people forget to change section and category url to lower case and using upper case in names…

Offline

#4 2007-04-24 22:44:47

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: [request] section url with small letters by default

I think it’s weird to begin with that the url doesn’t default to lower case, any reason why this is? I also have to make my sections lower case to force this, which is annoying. Then, when I want to display the section somewhere on the page, with <txp:page_url type="s"/>, it is in the lower case. What point is there to the section “title” (as opposed to the section “name”)? I haven’t found it used anywhere yet, in my experience.

IMO, the url should be in lower-case by default, just like article titles, and pretty much every other url on the entire internet.

Offline

#5 2007-04-25 01:09:23

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: [request] section url with small letters by default

…any reason why this is?

It has to do with languages other than English, and what the core PHP functions support. In the future we’ll be including code that makes use of a PHP extension which better supports that sort of thing. The extension is not always supported by various hosts, so for them it would fallback to the old-style of not touching anything.

Then, when I want to display the section somewhere… it is in the lower case.

You use section to display section titles.

What point is there to the section “title” (as opposed to the section “name”)?

“name” is used in the url and internally. “title” is for humans.

Offline

#6 2007-04-25 16:03:22

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: [request] section url with small letters by default

I guess I missed the <txp:section> tag entirely, so that displays the section “title” right? I guess its not big deal that we have to make the “name” lower case so that the url follows suit, as long as we can use the section “title” to display it on a page, and have it be capitalized there, or even spelled differently, or whatever you want it to be.

Offline

#7 2007-04-26 03:28:14

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: [request] section url with small letters by default

Yes. It can link to the section and/or display the section’s name or title.

Offline

Board footer

Powered by FluxBB