WikiMatrix
  • Forum
  •  » TWiki
  •  » Wiki snippet: help with explanation

#1 2006-10-06 19:03:35

ACalderon
Member
Registered: 2006-10-06
Posts: 4

Wiki snippet: help with explanation

Can anyone break down the following snippet for me? This is what's used as an example of a formatted search, but I can't find documentation that explains much further than this.

\s*([^\n\r]+)

Offline

 

#2 2006-10-17 01:50:46

PeterThoeny
Member
From: San Jose, CA
Registered: 2005-12-14
Posts: 265
Website

Re: Wiki snippet: help with explanation

Disecting \s*([^\n\r]+):

* \s* -- scan over white space
* ( -- start remembering text
* [^\n\r] -- any one character that is not a newline or carriage return
* + -- one or more of the preceeding expression (the one in previous bullet)
* ) -- stop remembering

Get help on regular expression:
* http://twiki.org/cgi-bin/view/TWiki/RegularExpression
* http://en.wikipedia.org/wiki/Regular_expression
* http://www.perl.com/doc/manual/html/pod/perlre.html

BTW, the preferred place to ask for free TWiki support is the TWiki Support web at http://twiki.org/cgi-bin/view/Support/WebHome

See TWiki details on WikiMatrix.

-- Peter AT StructuredWikis DOT com - http://www.structuredwikis.com/ - http://twiki.org/

Offline

 
  • Forum
  •  » TWiki
  •  » Wiki snippet: help with explanation

You are not logged in.


Board footer

Powered by PunBB
© Copyright 2002–2008 PunBB