Eric Pierce wrote:
Apologies if this has been brought up before, but I
am
curious about the status of automatic replacement of
dashes in the wikitext (in particular -- and ---) with
HTML-entity versions that many users seem to like so
much (ndash and mdash). I noticed that a while back
(February 2004) such a conversion was implemented, but
apparently reverted due to undesirable breakage. Any
way it could be reinstated? I may look into it once I
get familiar with the code.
That conversion consisted of two lines of code:
$text = str_replace( "---", "—", $text );
$text = str_replace( "--", "–", $text );
These were inserted near the start of the wikitext->HTML transformation.
The biggest problem in my mind was that it breaks links. Perhaps the way
to avoid this would be to act on HTML instead of wikitext, and to only
replace dashes which occur outside HTML tags.
The current status is that I have other things to do and nobody else has
volunteered.
-- Tim Starling