[pmwiki-devel] Custom markup to create a link followed by text
Randy Brown
randy at brownragfilms.com
Thu Jan 14 18:27:04 CST 2016
PRR works. Thank you so much!
I’ve added the working code to the PTVLinkText recipe. Here it is for the record:
## Markup to create links using [[target|$]] such that the page's Summary ptv is displayed in a smaller font after the title link
Markup_e('[[|$', '<[[|',
"/(?>\\[\\[([^|\\]]+))\\|\\s*\\$\\s*]]/",
"Keep(MakeLink(\$pagename, \$m[1],
PTVLinkTextSummaryAfterAndSmaller(MakePageName(\$pagename,\$m[1]))
),'L').PRR(' [-'.PageTextVar(\$m[1],'Summary').'-]')");
function PTVLinkTextSummaryAfterAndSmaller ($pn) {
$title = PageVar($pn, '$Title');
return $title;
}
Randy
> On Jan 14, 2016, at 5:07 PM, Chuck Goldstein <cgpmw13 at codingmaniac.com> wrote:
>
> Try enclosing your ' [-' ... '-]' in a PRR() call. See PmWiki/FunctionList.
>
More information about the pmwiki-devel
mailing list