On 7/25/07, Ian MacGregor <[EMAIL PROTECTED]> wrote:
> I need to set an
> array of pages/actions in which the "Discuss" links will not appear, pages
> like $group.(All|Recent)Changes, ?action=refcount. How do I do that?

Maybe try something like

$pagename = ResolvePageName($pagename);
if (preg_match('!^(PmWiki|Test|Profiles)\\.!', $pagename)
  || preg_match("!^$SiteGroup".'\\.!', $pagename)
  || preg_match('!\\.(GroupHeader|GroupFooter|GroupAttributes|WikiSandbox)$!',
$pagename)
  || preg_match('/^(print|refcount)$/', $action)) {
  $NoTalkPage = 1;
}

and then switch to

(:if name *-Draft :)(:else if enabled NoTalkPage:)
(:else if name *-Talk :)
* %item              class=browse    %[[{*$BaseName} |''Discuss'']]
(:else:)
* %item              class=browse    %[[{*$FullName}-Talk | Discuss ]]
(:if:)

If this is acceptable it should be refined and added to the recipe page.

Hagan

_______________________________________________
pmwiki-users mailing list
[email protected]
http://www.pmichaud.com/mailman/listinfo/pmwiki-users

Reply via email to