bp_media_allowed_document_type()
Function get document support extension.
Description
Parameters
- $format
-
(Required)
Return
(array|mixed|string|void)
Source
File: bp-templates/bp-nouveau/includes/document/functions.php
function bp_media_allowed_document_type() {
$extension_lists = array(
'bb_doc_1' => array(
'extension' => '.abw',
'mime_type' => 'application/x-abiword',
'description' => __( 'AbiWord Document', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_2' => array(
'extension' => '.abw',
'mime_type' => 'text/xml',
'description' => __( 'AbiWord Document', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_3' => array(
'extension' => '.ace',
'mime_type' => 'application/x-ace-compressed',
'description' => __( 'ACE Archive', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_4' => array(
'extension' => '.ai',
'mime_type' => 'application/postscript',
'description' => __( 'Illustrator File', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_5' => array(
'extension' => '.ai',
'mime_type' => 'application/pdf',
'description' => __( 'Illustrator File', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_6' => array(
'extension' => '.apk',
'mime_type' => 'application/vnd.android.package-archive',
'description' => __( 'Android Package', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_7' => array(
'extension' => '.apk',
'mime_type' => 'application/java-archive',
'description' => __( 'Android Package', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_8' => array(
'extension' => '.css',
'mime_type' => 'text/css',
'description' => __( 'CSS', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_9' => array(
'extension' => '.css',
'mime_type' => 'text/plain',
'description' => __( 'CSS', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_10' => array(
'extension' => '.csv',
'mime_type' => 'text/csv',
'description' => __( 'CSV', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_11' => array(
'extension' => '.doc',
'mime_type' => 'application/msword',
'description' => __( 'Word Document', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_12' => array(
'extension' => '.docm',
'mime_type' => 'application/vnd.ms-word.document.macroenabled.12',
'description' => __( 'Word Document (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_13' => array(
'extension' => '.docm',
'mime_type' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
'description' => __( 'Word Document (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_14' => array(
'extension' => '.docx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
'description' => __( 'Word Document', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_15' => array(
'extension' => '.dotm',
'mime_type' => 'application/vnd.ms-word.template.macroenabled.12',
'description' => __( 'Word Template (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_16' => array(
'extension' => '.dotx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
'description' => __( 'Word Template', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_17' => array(
'extension' => '.eps',
'mime_type' => 'application/postscript',
'description' => __( 'Encapsulated Postscript', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_18' => array(
'extension' => '.eps',
'mime_type' => 'image/x-eps',
'description' => __( 'Encapsulated Postscript', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_19' => array(
'extension' => '.gif',
'mime_type' => 'image/gif',
'description' => __( 'Graphics Interchange Format', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_20' => array(
'extension' => '.gz',
'mime_type' => 'application/x-gzip',
'description' => __( 'Gzip Archive', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_21' => array(
'extension' => '.gzip',
'mime_type' => 'application/gzip',
'description' => __( 'Gzip Archive', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_22' => array(
'extension' => '.htm',
'mime_type' => 'text/html',
'description' => __( 'HTML', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_23' => array(
'extension' => '.html',
'mime_type' => 'text/html',
'description' => __( 'HTML', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_24' => array(
'extension' => '.ico',
'mime_type' => 'image/x-icon',
'description' => __( 'ICO', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_25' => array(
'extension' => '.ics',
'mime_type' => 'text/calendar',
'description' => __( 'iCalendar', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_26' => array(
'extension' => '.ipa',
'mime_type' => 'application/octet-stream',
'description' => __( 'iOS Package', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_27' => array(
'extension' => '.jar',
'mime_type' => 'application/java-archive',
'description' => __( 'JAR Archive', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_28' => array(
'extension' => '.jpeg',
'mime_type' => 'image/jpeg',
'description' => __( 'Image File', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_29' => array(
'extension' => '.jpg',
'mime_type' => 'image/jpeg',
'description' => __( 'Image File', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_30' => array(
'extension' => '.js',
'mime_type' => 'application/javascript',
'description' => __( 'JavaScript', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_31' => array(
'extension' => '.js',
'mime_type' => 'text/plain',
'description' => __( 'JavaScript', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_32' => array(
'extension' => '.mp3',
'mime_type' => 'audio/mpeg',
'description' => __( 'MP3', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_33' => array(
'extension' => '.ods',
'mime_type' => 'application/vnd.oasis.opendocument.spreadsheet',
'description' => __( 'OpenDocument Spreadsheet', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_34' => array(
'extension' => '.odt',
'mime_type' => 'application/vnd.oasis.opendocument.text',
'description' => __( 'OpenDocument Text', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_35' => array(
'extension' => '.pdf',
'mime_type' => 'application/pdf',
'description' => __( 'PDF', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_36' => array(
'extension' => '.png',
'mime_type' => 'image/png',
'description' => __( 'Image File', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_37' => array(
'extension' => '.potm',
'mime_type' => 'application/vnd.ms-powerpoint.template.macroenabled.12',
'description' => __( 'PowerPoint Template (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_38' => array(
'extension' => '.potx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.presentationml.template',
'description' => __( 'PowerPoint Template', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_39' => array(
'extension' => '.potx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
'description' => __( 'PowerPoint Template', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_40' => array(
'extension' => '.pps',
'mime_type' => 'application/vnd.ms-powerpoint',
'description' => __( 'PowerPoint Template', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_41' => array(
'extension' => '.ppsx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.presentationml.slideshow',
'description' => __( 'PowerPoint Slideshow', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_42' => array(
'extension' => '.ppsx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
'description' => __( 'PowerPoint Slideshow', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_43' => array(
'extension' => '.ppt',
'mime_type' => 'application/vnd.ms-powerpoint',
'description' => __( 'PowerPoint Presentation', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_44' => array(
'extension' => '.pptm',
'mime_type' => 'application/vnd.ms-powerpoint.presentation.macroenabled.12',
'description' => __( 'PowerPoint Presentation (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_45' => array(
'extension' => '.pptm',
'mime_type' => 'application/octet-stream',
'description' => __( 'PowerPoint Presentation (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_46' => array(
'extension' => '.pptm',
'mime_type' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
'description' => __( 'PowerPoint Presentation (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_47' => array(
'extension' => '.pptx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
'description' => __( 'PowerPoint Presentation', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_48' => array(
'extension' => '.psd',
'mime_type' => 'image/vnd.adobe.photoshop',
'description' => __( 'Photoshop Document', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_49' => array(
'extension' => '.rar',
'mime_type' => 'application/x-rar-compressed',
'description' => __( 'RAR Archive', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_50' => array(
'extension' => '.rar',
'mime_type' => 'application/x-rar',
'description' => __( 'RAR Archive', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_51' => array(
'extension' => '.rss',
'mime_type' => 'application/rss+xml',
'description' => __( 'RSS', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_52' => array(
'extension' => '.rtf',
'mime_type' => 'application/rtf',
'description' => __( 'Rich Text Format', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_53' => array(
'extension' => '.sketch',
'mime_type' => 'application/x-sqlite3',
'description' => __( 'Sketch Document', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_54' => array(
'extension' => '.svg',
'mime_type' => 'image/svg+xml',
'description' => __( 'SVG', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_55' => array(
'extension' => '.tar',
'mime_type' => 'application/x-tar',
'description' => __( 'TAR Archive', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_56' => array(
'extension' => '.tiff',
'mime_type' => 'image/tiff',
'description' => __( 'Tagged Image File', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_57' => array(
'extension' => '.txt',
'mime_type' => 'text/plain',
'description' => __( 'Text File', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_58' => array(
'extension' => '.vcf',
'mime_type' => 'text/x-vcard',
'description' => __( 'vCard', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_59' => array(
'extension' => '.vcf',
'mime_type' => 'text/vcard',
'description' => __( 'vCard', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_60' => array(
'extension' => '.wav',
'mime_type' => 'audio/x-wav',
'description' => __( 'Waveform Audio', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_61' => array(
'extension' => '.xlam',
'mime_type' => 'application/vnd.ms-excel.sheet.binary.macroenabled.12',
'description' => __( 'Excel Spreadsheet (Binary, Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_62' => array(
'extension' => '.xls',
'mime_type' => 'application/vnd.ms-excel',
'description' => __( 'Excel Spreadsheet', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_63' => array(
'extension' => '.xlsb',
'mime_type' => 'application/vnd.ms-excel.sheet.binary.macroenabled.12',
'description' => __( 'Excel Spreadsheet (Binary, Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_64' => array(
'extension' => '.xlsb',
'mime_type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
'description' => __( 'Excel Spreadsheet (Binary, Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_65' => array(
'extension' => '.xlsb',
'mime_type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
'description' => __( 'Excel Spreadsheet (Binary, Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_66' => array(
'extension' => '.xlsm',
'mime_type' => 'application/vnd.ms-excel.sheet.macroenabled.12',
'description' => __( 'Excel Spreadsheet (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_67' => array(
'extension' => '.xlsm',
'mime_type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
'description' => __( 'Excel Spreadsheet (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_68' => array(
'extension' => '.xlsx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
'description' => __( 'Excel Spreadsheet', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_69' => array(
'extension' => '.xltm',
'mime_type' => 'application/vnd.ms-excel.template.macroenabled.12',
'description' => __( 'Excel Template (Macro Enabled)', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_70' => array(
'extension' => '.xltx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.template',
'description' => __( 'Excel Template', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_71' => array(
'extension' => '.xltx',
'mime_type' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
'description' => __( 'Excel Template', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_72' => array(
'extension' => '.xml',
'mime_type' => 'application/rss+xml',
'description' => __( 'XML', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_73' => array(
'extension' => '.xml',
'mime_type' => 'text/xml',
'description' => __( 'XML', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_74' => array(
'extension' => '.yaml',
'mime_type' => 'text/yaml',
'description' => __( 'YAML', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_75' => array(
'extension' => '.zip',
'mime_type' => 'application/zip',
'description' => __( 'Zip', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
'bb_doc_76' => array(
'extension' => '.7z',
'mime_type' => 'application/x-7z-compressed',
'description' => __( '7z Archive', 'buddyboss' ),
'is_default' => 1,
'is_active' => 1,
'icon' => '',
),
);
$extension_lists = apply_filters( 'bp_media_allowed_document_type', $extension_lists );
return $extension_lists;
}
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.