Last modified: 2009-03-26 17:15:58 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 T9509, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 7509 - Don't hardcode separation strings, make them configurable
Don't hardcode separation strings, make them configurable
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
Internationalization (Other open bugs)
unspecified
All All
: Normal normal with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-10-06 21:44 UTC by Schnargel
Modified: 2009-03-26 17:15 UTC (History)
2 users (show)

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


Attachments

Description Schnargel 2006-10-06 21:44:53 UTC
Add a MediaWiki message to enable replacing the "|" as separation string.

MediaWiki currently displays an ASCII vertical bar to separate categories in articles and options on special pages. (The use of $7c for such purposes 
has its origin in the 1980s when ASCII graphics were state of the art.) Users might like to replace it by a middle dot, comma+<space>, an extended 
space, dash, or something else to match other lists in the wiki or just to make it more readable.

Same goes for the "<" which is used as back arrow for example on Spezial:Whatlinkshere and does not match the &larr; that is used in other places.
Comment 1 Raimond Spekking 2006-10-06 22:35:41 UTC
You can edit [[MediaWiki:catseparator]] to replace | with another separator. 

"<" has no MediaWiki message, at least I cannot find one.
Comment 2 Jimmy Collins 2006-10-06 23:14:29 UTC
1) Alredy exists: [[MediaWiki:catseparator]]

2) Added [[MediaWiki:whatlinkshere-barrow]] in r16824.
Comment 3 Schnargel 2006-10-07 06:29:49 UTC
Thanks, I did not see the MediaWiki:catseparator. But ...

1a) It would be nice to have a way to enter the full separation string including the surrounding spaces to enable a comma separated list ("cat1, 
cat2, cat3").

1b) The catseparator does not affect the separation bars on special pages (like "50 | 100 | 250 | 500").
grep "' | '" includes/*
should give an idea of where it is used.
Comment 4 Rob Church 2007-06-11 07:20:29 UTC
Er, no point?
Comment 5 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-06-11 07:28:32 UTC
It's a flaw in internationalization if there's any hardcoded punctuation or spacing at all.
Comment 6 Siebrand Mazeland 2008-09-14 10:17:59 UTC
I think that all above issues have been addressed. Any remaining issues? If no feedback is received within a month or so, this issue will be closed as FIXED.
Comment 7 Schnargel 2008-09-14 16:36:52 UTC
Would you care to explain how to configure the following hardcoded separation strings?

  grep "' | '" mediawiki-1.13.1/includes/*
includes/GlobalFunctions.php:	$nums = wfNumLink( $offset, 20, $title, $query ) . ' | ' .
includes/GlobalFunctions.php:	  wfNumLink( $offset, 50, $title, $query ) . ' | ' .
includes/GlobalFunctions.php:	  wfNumLink( $offset, 100, $title, $query ) . ' | ' .
includes/GlobalFunctions.php:	  wfNumLink( $offset, 250, $title, $query ) . ' | ' .
includes/Linker.php:			return ' (' . implode( ' | ', $items ) . ')';
includes/PageHistory.php:			$s .= ' (' . implode( ' | ', $tools ) . ')';
includes/Pager.php:		$limits = implode( ' | ', $limitLinks );
includes/Pager.php:				$extra .= ' | ';
includes/Pager.php:		$limits = implode( ' | ', $limitLinks );
includes/SearchPostgres.php:					$searchstring .= ' | ';
includes/Skin.php:			$s .= ' | ' . $disclaimer;
includes/Skin.php:			$s .= ' | ' . $privacy;
includes/Skin.php:			$s .= ' | ' . $this->makeKnownLinkObj( $wgTitle,
includes/Skin.php:			$s .= ' | '.$undelete;
includes/Skin.php:							$subpages .= ' | ';
includes/Skin.php:			  "returnto={$rt}" ) . ' | ' .
includes/Skin.php:		$s .= ' | ' . $this->makeKnownLink( wfMsgForContent( 'helppage' ),
includes/Skin.php:			$s .= ' | ' . Xml::element( 'a',
includes/Skin.php:			if ( ! $first ) { $s .= ' | '; }
includes/WatchlistEditor.php:			. $link . ' (' . implode( ' | ', $tools ) . ')' . '</li>';
includes/WatchlistEditor.php:		return implode( ' | ', $tools );

Comment 8 Siebrand Mazeland 2008-09-17 09:42:29 UTC
Fixed in r40953. Message "pipe-separator" was added. You should now be able to use a bullet as separator, for example.
Comment 9 Brion Vibber 2008-09-18 17:12:43 UTC
Reverted in r40997. This made the code harder to read and maintain and more prone to error by requiring the non-trivial formula to remember a funky message option _every dang time_ the standard pipe separator is to be used.
Comment 10 Siebrand Mazeland 2008-09-18 17:19:59 UTC
SO what do you suggestion,(In reply to comment #9)
> Reverted in r40997. This made the code harder to read and maintain and more
> prone to error by requiring the non-trivial formula to remember a funky message
> option _every dang time_ the standard pipe separator is to be used.
> 

So what do you suggest, Brion? WONTFIX, or what alternative for r40953?
Comment 11 Brion Vibber 2008-09-18 17:22:29 UTC
It's pretty much begging to be encapsulated into a Language method to take an array and make a list out of it. Comma-friendly and pipe-friendly versions, perhaps?
Comment 12 Brion Vibber 2008-09-19 19:00:00 UTC
I added a Language::commaList() function as an example; a pipe version to encapsulate the other message would be spiffy.
Comment 13 Siebrand Mazeland 2009-02-09 17:49:32 UTC
Fixed in r47046 Related commits are r47028, r47040, r47044. Originally committed as r40953, which was reverted in r40977, because if was too verbose. Language::pipeList, and Language::commaList should have resolved that.

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


Navigation
Links