<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
Hi Patrick,<br>
<br>
thank you - this works a treat <span class="moz-smiley-s1"><span> :-) </span></span><br>
<br>
Regards<br>
<br>
Graham<br>
<br>
Patrick R. Michaud wrote:
<blockquote cite="mid20070913122909.GA26159@host.pmichaud.com"
 type="cite">
  <pre wrap="">On Thu, Sep 13, 2007 at 12:56:40PM +0100, Graham Archer - EMEA Sun Center Operations wrote:
  </pre>
  <blockquote type="cite">
    <pre wrap="">   Hi,

   Trying to get:

   Markup('attachicon', '&lt;links'
      "/\\bAttach:[^\\s$UrlExcludeChars]*\\.(mov|doc|xls)/",
       '<a class="moz-txt-link-freetext" href="http://localhost/wiki3nov/pub/icons/$2.png">http://localhost/wiki3nov/pub/icons/$2.png</a> $0');

   to work as shown in <a class="moz-txt-link-freetext" href="http://www.pmwiki.org/wiki/Cookbook/AttachIcons">http://www.pmwiki.org/wiki/Cookbook/AttachIcons</a>
    </pre>
  </blockquote>
  <pre wrap=""><!---->
There's a comma missing after '&lt;links' .

Also, the recipe appears to be incorrectly using a $2 in the last 
line -- it probably needs to be $1 (as the pattern only has
one set of parens).  Thus you might try:

  Markup('attachicon', '&lt;links',
     "/\\bAttach:[^\\s$UrlExcludeChars]*\\.(mov|doc|xls)/",
    '<a class="moz-txt-link-freetext" href="http://localhost/wiki3nov/pub/icons/$1.png">http://localhost/wiki3nov/pub/icons/$1.png</a> $0');

Pm

  </pre>
</blockquote>
<br>
</body>
</html>