I believe that making the match for } non-greedy as below would match
just the one table, but I've not tried it.
s/\{\|.+?\|\?}//gs
/Sam
-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of
Christensen, Courtney
Sent: 06 August 2009 21:05
To: MediaWiki announcements and site admin list
Subject: Re: [Mediawiki-l] REGEXP for wiki tables
Benct Philip Jonsson wrote:
>On 2009-08-05 Matthias Korn wrote:
>> I have now settled with "\{[^\}]+\}" which is far from perfect,
>> because it also matches (partially) on templates. But that's ok.
>>
>s/\{\|.+?\|\}//gs would do a lot better, since wikitables start in "{|"
>and end in "|}" and would not touch templates.
>
>/BP
But that would sometimes grab more than just one table.
-Courtney
_______________________________________________
MediaWiki-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
This email was sent to you by Thomson Reuters, the global news and information
company.
Any views expressed in this message are those of the individual sender, except
where the sender specifically states them to be the views of Thomson Reuters.
_______________________________________________
MediaWiki-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l