Document types in Wysiwyg upload field

2 posts by 2 authors in: Forums > CMS Builder
Last Post: November 10, 2008   (RSS)

By benedict - November 9, 2008

Hi guys,

I know I can add new document types such as .pdf and .doc to be available in the upload/link field of the WYSIWYG editor (in the advanced options of the field in the admin). Is there any way of doing this once so I don't have to keep adding it in for every new WYSiWYG field I add?

Re: [benedict] Document types in Wysiwyg upload field

By Dave - November 10, 2008

Hi benedict,

There's no official way to change the defaults. But if you don't mind modifying some PHP code you can do it like this:

- Open /lib/menus/database/editField_functions.php
- Make a backup
- Search for "upload options"
- Edit this line here:

$defaultValue['allowedExtensions'] = 'gif,jpg,png,wmv,mov,swf,pdf';

Those are the default values that are used everytime a new field is created.

Hope that helps!
Dave Edis - Senior Developer
interactivetools.com