X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/190d328e402102f04ee0a287f9b173c52bffa341..84e6c4fa665703133b5778e92c045897df496e97:/doc/plugins/attachment.mdwn diff --git a/doc/plugins/attachment.mdwn b/doc/plugins/attachment.mdwn index 184f5b5df..01816cd5c 100644 --- a/doc/plugins/attachment.mdwn +++ b/doc/plugins/attachment.mdwn @@ -29,7 +29,7 @@ For example, to limit arbitrary files to 50 kilobytes, but allow larger mp3 files to be uploaded by joey, a test like this could be used: - (user(joey) and *.mp3 and maxsize(15mb)) or (!ispage() and maxsize(50kb)) + (user(joey) and *.mp3 and mimetype(audio/mpeg) and maxsize(15mb)) or (!ispage() and maxsize(50kb)) The following additional tests are available: @@ -62,3 +62,9 @@ The following additional tests are available: Tests whether the attacment is being uploaded from the specified IP address. + +* mimetype(foo/bar) + + If the [[cpan File::MimeInfo::Magic]] perl module is installed, this + allows checking the mime type of the attachment. You can include a glob + in the type, for example `mimetype(image/*)`.