On Sat, 31 Jul 2004 14:10:06 +0100
Timwi <timwi(a)gmx.net> wrote:
Emmanuel Engelhart wrote:
Small patch.
Maybe not the best solution, but simple and not very dirty.
Makes a merge of correct template args to recover entire wikilinks [[(...)]]
It has a little bug:
Suppose you have something like
{{template|var1=Here is a [[link]] and here is [[link|another]].}}
Your patch would not work properly in this case. Please could you change
this:
+ if((strpos($args[$i], "[[") !== false) && (strpos($args[$i],
"]]") ===
false) ) {
in such a way that it essentially says "if number of '[['s in $args[$i]
greater than number of ']]'s"?
Additionally, please use tabs at the beginning of lines, and please use
'diff -u' to create your patches.
True, new version correcting this bug.
Emmanuel
--
-------------------------------------------------------------------------
La noirceur porte plusieurs masques, aucun n'est aussi dangeureux que
celui de la vertu.
-------------------------------------------------------------------------
Emmanuel Engelhart ICQ UIN : 53388731 TEL (+49)(0)6.22.15.88.03.31