Strikethough wiki filtering is used by some wiki applications and particularly useful when indicating modifications or completed tasks.

After looking at various wikis with strikethrough syntax, it is common to indicate strikethrough text with the use of '-' on both sides of text a user wishes to strike.

Is there interest in adding strikethrough syntax to this module, perhaps with the following?

    // strikethrough
    $tmpline = preg_replace("|(-)(.*?)(-)|",
                 "<strike>\\2</strike>", $tmpline);

Comments

veridicus’s picture

Good idea. I'll look into adding something that generates a DEL tag (S and STRIKE are deprecated in HTML4.01 and XHTML 1.0)

carl ditzler’s picture

A discussion on the dokuwiki about strikethrough syntax is interesting. Comments on Dokuwiki supported use of a single-hyphen for strikethrough, through Dokuwiki selected <del> for wiki markup. I'm not sure agree, personally, with having wiki markup the same as XHTML markup, by selecting <del>. Wiki syntax is generally not the same as HTML or XHTML markup; part of the objective of wiki syntax is to offer a user with syntax friendlier than HTML/XHTML.

carl ditzler’s picture

Reading through the Dokuwiki discussion, there is mention of addiing <ins> with <del>. Makes sense. Perhaps this would be a companion with strikethrough?

veridicus’s picture

The STRIKE (and S) tag is officially leaving HTML. So I won't output it because it'll break HTML/XHTML strict compatibility for many sites (most new themes are being written XHTML 1.0 Strict). DEL is more descriptive and anyone can change their CSS to make it display text as strike-through if not done automatically.

I plan on using one or two hyphens on both side of phrases to tag them DEL. I will never use html-like tags for wiki text because it defeats the purpose of using it. Also I want all HTML output as is so it can be easily displayed to readers just like code.

highermath’s picture

Version: 4.5.x-1.x-dev » 2.x-dev
Issue summary: View changes
Status: Active » Closed (won't fix)

Obsolete