[pmwiki-users] conditional for attachments

Tegan Dowling tmdowling at gmail.com
Tue Nov 13 08:54:30 CST 2007


On Nov 13, 2007 8:42 AM, noskule <noskule at gmx.net> wrote:
> Patrick R. Michaud schrieb:
> > On Tue, Nov 13, 2007 at 02:44:45PM +0100, noskule wrote:
> >> hi list
> >> is there a way to find out if a attachment with a given name exists?
> >> That works the same way as exists for pages does?
> >>
> >> In the documentation I found only a way to find out it any attachemt exists.
> >
> > We don't yet have a conditional for testing for specific attachments.
> > I could probably write one as a recipe, though.
> >
> > Pm
> >
>
> that would be cool, one thing that I stepped over was, that if user
> upload a profile portrait they will upload it in different formats like
> jpg, png, so the conditional should be able ot detect the filename
> without the extension. But if wildcards ar supported this will probably
> work anyway .. .
>
> (:if attachment {*$Group}/{*$Name}-Portrait.*:)
>

FYI, there's a least one other person who would use this, if it
existed.  I'd use it on profile pages, as noskule does, and also on
some blog-like pages.



More information about the pmwiki-users mailing list