form-actions.php
4 days ago
form-uploads.php
4 days ago
hooks.php
1 month ago
listeners.cache.php
1 month ago
media.php
1 month ago
messages.php
4 days ago
migrations.php
1 month ago
policies.cache.php
1 month ago
form-uploads.php
18 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * MIME types accepted per file-upload field `accept` preset. |
| 5 | * |
| 6 | * Keyed by the exact preset string stored on the field (e.g. `default`, |
| 7 | * `.jpg, .jpeg, .png, .gif`) — matches the presets in the builder's |
| 8 | * FileTypes settings panel. |
| 9 | */ |
| 10 | return [ |
| 11 | 'accepted_mime_types' => [ |
| 12 | 'default' => ['image/jpeg', 'image/jpg', 'image/png', 'image/gif', 'image/webp', 'video/mp4', 'video/ogg', 'video/quicktime', 'application/pdf', 'application/msword', 'text/plain'], |
| 13 | '.doc, .pdf, .txt' => ['application/pdf', 'application/msword', 'text/plain'], |
| 14 | '.mp4, .mov' => ['video/mp4', 'video/ogg', 'video/quicktime'], |
| 15 | '.jpg, .jpeg, .png, .gif' => ['image/jpeg', 'image/jpg', 'image/png', 'image/gif', 'image/webp'], |
| 16 | ], |
| 17 | ]; |
| 18 |