Last modified: 2013-07-23 16:50:06 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T53892, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 51892 - "error" class if #language can't parse a code
"error" class if #language can't parse a code
Status: NEW
Product: MediaWiki
Classification: Unclassified
Internationalization (Other open bugs)
unspecified
All All
: Low enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
http://en.wikipedia.org/w/index.php?t...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-23 16:49 UTC by T. H. Kelly (Pink&)
Modified: 2013-07-23 16:50 UTC (History)
6 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description T. H. Kelly (Pink&) 2013-07-23 16:49:39 UTC
Lately I've been working on some templates using the #language magic word, and I've wanted to write in fallbacks if someone specifies an invalid or unsupported code. Currently, I have to do this with the markup {{#ifeq:{{#language:{{{1}}}}}|{{{1}}}||<text to display>}}, which is somewhat cumbersome. So, my suggestion is that instead of simply returning the same thing someone input when the language code doesn't work, we also wrap it in <span class="error"></span>. That way, you'd be able to do fallbacks with the slightly simpler {{#iferror:{{#language:{{{1}}}}}||<text to display>}}.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links