Recent Changes - Search:

Cookbook

PmWiki

pmwiki.org

TitleCased

Summary: Site customizeable title case of titles.
Version: 1.0, December 13, 2005
Prerequisites: at least 2.1-Beta14
Status: stable
Maintainer: BenWilson, PageNaming
Categories:

Question

When I have a title for a page, I want it to only capitalize the words that are supposed to be capitalized in my language.

Answer

This recipe does just that. You assign the words you don't want upper cased, and this script does the rest. The list of lower cased words comprises common English words. For what its worth, the "rule" for lower casing is all articles (a, an, the), conjunctions (e.g. and, but), and prepositions of less than five letters (e.g. we lower case "from" but not "Until"). The list is not comprehensive.

Attach:titlecased-1.0.phpΔ

include_once("$FarmD/Cookbook/titlecased.php");

Notes

  • This recipe was last tested on PmWiki version: 2.1-Beta14
  • This recipe, version v1.0 was installed here December 13, 2005

Releases

  • v1.0 - Originally written, based on an earlier discussion with others on the discusion list. I've used this for months now Dec 13, 2005 BenWilson

Comments

See Also

Contributors


Edit - History - Print - Recent Changes - Search
Page last modified on June 21, 2007, at 06:43 AM