[pmwiki-users] Re edit templates: auto update dates?
Henrik
henrik.bechmann at sympatico.ca
Thu Apr 10 14:28:10 CDT 2008
Patrick,
I use a whole bunch of immediate substitutions from guibuttons (actually
links) on edit forms like this:
$GUIButtons['attach'] = array(1101, 'Uploads:{$Group}/','','','
[Uploads:]');
or these:
$GUIButtons['datestamp'] = array(1405, '', '', '($CustomDate)',' [date
stamp] ');
$GUIButtons['authordatestamp'] = array(1406, '', '', '($Author -
$CustomDate)',' [author date stamp] ');
..and they're very popular.
Intuitively, I would think that some kind of call from
GroupName.Template.php would be the place for immediate substitution of
template variables, though I'm not sure how it would get wired up.
immediateSubstitution("varname","value");
or in OO
templatepage->immediatesubstitution("varname","value");
??
BTW my new webhost looks really good. I'm getting a 40% performance
improvement, and service seems as solid as a rock. Now I'm totally
chomping at the bit to employ your new features (having finally upgraded
from 2.1.27).
All the best,
- Henrik
Patrick R. Michaud wrote:
> On Thu, Apr 10, 2008 at 12:22:53PM -0400, Henrik wrote:
>
>> Regarding http://www.pmwiki.org/wiki/Cookbook/EditTemplates
>>
>> Is it possible to automatically update dates, to that the imported text
>> contains the current date (as text, not as a variable).
>>
>> So for example if creating a page today, I would like the title, as
>> imported from the template, to have in the edit textbox
>>
>> !!!!Farmers' Market news for April 10, 2008
>>
>> Where the date is written in as clear text from the template.
>>
>
> At present I don't think there's a way to do this. I've been
> thinking about ways to have "immediate substitutions" like
> this done, but haven't come up with anything I particularly
> like yet (which is why we don't have it).
>
> Pm
>
>
--
Henrik Bechmann
www.bechmann.ca
Webmaster, www.dufferinpark.ca
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.pmichaud.com/pipermail/pmwiki-users/attachments/20080410/f2824882/attachment-0001.html
More information about the pmwiki-users
mailing list