Override title text and formatting from page markup
Closed, ResolvedPublic


Author: dunc_harris

Some pages, e.g. pH, eBay, have titles that are rendered wrongly by the software
because the first letter shouldn't be capitalised, or are at a different place
because of the limitations of the url, e.g. C++. This could be solved by adding
to the page:


This could be extended to including italicisation for books, films, bands, etc


[[Title:''The Beatles'']]

The only problem I can think of with this is the C++ page which needs to be
linked to with [[C Plus Plus|C++]] and that this would be less obvious if this
was implemented.

Version: unspecified
Severity: enhancement

bzimport set Reference to bz496.
bzimport added a subscriber: Unknown Object (MLST).
bzimport created this task.Sep 15 2004, 1:17 PM

dunc_harris wrote:

The ability to format differently e.g. for ships

[[Title:HMS ''Invincible'' (R05)]]

would be good.

rowan.collins wrote:

From a (somewhat off-topic) comment I made on bug 337:
"I wonder if a mechanism to display the page's title (in
the HTML output) as something different from its name (in the database) could be
created, which showed the real name (as needed for linking to the article)
<p><small>[Article title: C_sharp]</small></p>
Except I'm not sure how to label the second line so that it would make sense to
inexperienced users. My thought is that this could be a magic word at the
beginning of the article: '#TITLE C#'; similarly, one could use '#TITLE h2g2' to
display the lower-case leading letter on a wiki where this was otherwise not

And Alan Barrett's reply:
"Perhaps "To link to this article, use [[C sharp]]." Put it as close to the H1
heading as possible, and use a stylesheet to hide it in print media.

See [[:en:Template:Wrongtitle]] and [[:en:Wikipedia:Naming conventions
(technical restrictions)]]
(and the corresponding talk pages) for relevant discussion."

rowan.collins wrote:

I see somebody has created a patch - see bug 2118 - for an "LCFIRST" magic
word which covers the easy cases of titles with all lower-case on an otherwise
automatically upper-casing wiki. The simplifying point being that these titles
can be linked to in either way anyway, so it is a purely presentational matter.

dunc_harris wrote:

Well I've seen Wiktionary's gone over lower case, is it possible for the developers to manually move mis-
capitalised titles over? This would deal with most of them. See bug 2713 where I've explained this a bit
more detail.

gangleri wrote:

Please take a look at bug 337 comment 22.

best regards reinhardt [[user:gangleri]]

gangleri wrote:

Please take a look at bug 2118 comment 15.

best regards reinhardt [[user:gangleri]]

Wiki.Melancholie wrote:

See Bug 2118 comment #24 for a JavaScript workaround for this issue.

ayg wrote:

*** Bug 7237 has been marked as a duplicate of this bug. ***

robchur wrote:

The title itself can now be overridden using DISPLAYTITLE, where the desired title normalises to the same title as the page being rendered.

I'm not sure whether we want to be able to override title formatting, as well, although it's not going to affect linking...

ayg wrote:

Would probably be useful for, e.g., chemical formulas, equations, etc. Don't see why not.

rick.blasingim wrote:

I'd like to have the option of using display titles that don't normalize. We had some nice features worked out with templates that would append things like "Stub", "Draft", "Final" to the display title. We also had a template for user pages to change the display title from something like "user:Doe, John" to simply "John Doe". The subtext "link to this article as..." was sufficient for identifying the real title. I can see why you might not want this on a public wiki, but I think it has use in private wikis.

How about a configuration setting $wgEnableScaryDisplayTitle to enable display titles that don't normalize?

rememberthedot wrote:

This feature has been available for a while now via the DISPLAYTITLE magic word, see http://meta.wikimedia.org/wiki/Help:Magic_words#Miscellany

I'm closing this bug as FIXED.

rick.blasingim wrote:

It may be proper to close this "bug" since the software is behaving as intended, but I'm going to open it one more time because it isn't behaving as several of the comments would like. The desired functionality is to allow display titles that don't normalize. So yes, "iPod" and "eBay" are fine for "IPod" and "EBay", but "C++" isn't fine for "C plus plus". A few versions ago, the displytitle magic word did allow non-normalizing display titles. I think the desire is to get back to that (or at least have the option).

TheDJ added a comment.May 28 2008, 8:04 PM

There is a reason the javascript code to change the title is still used on en.wikipedia. sub/superscript (very common in astronomy and chemistry topics) and C++ etc. should really be handled some way in the core. As a matter of fact, brion even suggested it should be like that: http://en.wikipedia.org/w/index.php?title=MediaWiki_talk%3ACommon.js&diff=214858584&oldid=214794296

brion added a comment.Dec 30 2008, 2:27 AM

Duping this to bug 12998 which has some active patch work in development.

  • This bug has been marked as a duplicate of bug 12998 ***

Add Comment