|
Re: Question to new page format variables: msg#00061web.wiki.pmwiki.user
On Sat, Jun 14, 2003 at 08:37:30AM +0200, Bernhard Weichel in pmwiki-users wrote: > Now my questions: > > 1. does it matter (e.g. is there a performance impact) if I use > > PrintFmt($pagename, "wiki:\$Group.\$Title") versus > PrintWikiPage("\$Grouip.\$Title") > > If it doesn't matter, why do we need PrintWikiPage? Well, I had never really intended for people to call PrintFmt directly (although I certainly don't exclude the possibility). For example, instead of doing <?php PrintFmt($pagename, "function:PrintGeneralMenu"); ?> I would've written <?php PrintGeneralMenu($pagename); ?> using PHP's built-in function calling syntax. Similarly, instead of <?php PrintFmt($pagename, "file:somefile.php"); ?> I would expect <?php include("somefile.php"); ?> However, there is no PHP equivalent function for displaying a wiki page, so I wrote one and called it PrintWikiPage(), thinking that would be easier for most people than calling PrintFmt(). > 2. If I use PrintFmt($pagename, "wiki:\$Group.Menu default.Menu") > Is there a way to find out which page is actually printed. This is > important > since I want to specify e.g. a general link to "Edit Menu" within the > function > PrintGeneralMenu. At present, no. I could modify PrintWikiPage or PrintText to set a global variable containing the name of the page that is actually being printed (if so, what should it be called)? Pm |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: Approach for handling Diff: 00061, Patrick R. Michaud |
|---|---|
| Next by Date: | Re: [pmwiki] bug in printfmt: 00061, Patrick R. Michaud |
| Previous by Thread: | Question to new page format variablesi: 00061, Bernhard Weichel in pmwiki-users |
| Next by Thread: | Uploads break XHTML: 00061, Edward Andrews |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |