10
votes
Accepted
How to assign multiple file-mime-types to extension?
Note the stricter mime type check since WP 5.0.1 where the file content and file extension must match. See e.g. this recent question on the vtt file type.
Secondary mime type for a given file ...
3
votes
How to assign multiple file-mime-types to extension?
A little improved birgire's answer. Had to add multiple mime types for svg, but because svg is forbidden by default, had to add dynamic filter to upload_mimes:
class Multiple_Mimes {
public ...
2
votes
PHP - Unexpected character in input: '' (ASCII=20) state=0
In your code, you're doing this:
$template_file_name = require_once ( get_template_directory() . '/template.docx' );
...but that's not how require_once (or require) works. require_once will load the ...
1
vote
Accepted
Can a manually uploaded plugin be made to track updates from the WordPress.org plugin directory?
As long as everything was made according to WP best practices all your manually installed versions will update the same as the ones installed from wordpress.org.
The updater looks at many things to ...
1
vote
Can a manually uploaded plugin be made to track updates from the WordPress.org plugin directory?
There is a way to have a privately-hosted plugin folder that will get updated via the normal Admin, Updates process. It's a bit complex to set up, but I have done it.
The info is here: https://github....
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
ziparchive × 20plugins × 5
plugin-development × 4
wp-filesystem × 4
uploads × 3
php × 2
attachments × 2
headers × 2
automatic-updates × 2
theme-development × 1
loop × 1
themes × 1
ajax × 1
javascript × 1
array × 1
updates × 1
json × 1
installation × 1
server × 1
archive-template × 1
wordpress.org × 1
licensing × 1
compression × 1