From 6f08484a9062f1552563c8805be30d3b26f6864a Mon Sep 17 00:00:00 2001 From: Cam Findlay Date: Sun, 20 Jul 2014 14:25:21 +1200 Subject: [PATCH] DOCS Setting allowed_extensions in YAML 3.1 compatible docs in place of #3267 --- docs/en/reference/uploadfield.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/en/reference/uploadfield.md b/docs/en/reference/uploadfield.md index 3937d7ad6..dee8b7406 100644 --- a/docs/en/reference/uploadfield.md +++ b/docs/en/reference/uploadfield.md @@ -146,6 +146,13 @@ to known file categories. // 'doc','docx','txt','rtf','xls','xlsx','pages', 'ppt','pptx','pps','csv', 'html','htm','xhtml', 'xml','pdf' $uploadField->setAllowedFileCategories('image', 'doc'); +`AllowedExtensions` can also be set globally via the [YAML configuration](/topics/configuration#setting-configuration-via-yaml-files), for example you may add the following into your mysite/_config/config.yml: + + :::yaml + File: + allowed_extensions: + - 7zip + - xzip ### Limit the maximum file size