Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ Following standard features of the WordPress Core are manipulated or extended.
* Search
* Site Health
* Update
* Uploads

### Archives

Expand Down Expand Up @@ -101,6 +102,10 @@ Following standard features of the WordPress Core are manipulated or extended.
* Run Plugin Updates automaticly
* Run Theme Updates automaticly

###

* Add Subdirectory YEAR for Uploads

## Plugin Modifications

Standard features of the following plugins will be manipulated or extended.
Expand Down Expand Up @@ -220,6 +225,7 @@ This project is licensed under the GPL3 License.

Release pending.

* Added: Custom Upload Subdirectories
* Added: TootPress Afterloop Filter
* Added: Caching of ActivityPub Endpoints in WP REST API
* Added: Fade out WB REST CACHE Icon @ Admin Bar
Expand Down
1 change: 1 addition & 0 deletions unmus.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
require_once('unmus_visibility.php');
require_once('unmus_cache.php');
require_once('unmus_tootpress.php');
require_once('unmus_ftp.php');

// Ensure that all required functions are available during setup
require_once( ABSPATH . 'wp-admin/includes/upgrade.php');
Expand Down
23 changes: 23 additions & 0 deletions unmus_ftp.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?php

/**
* FTP
*
* @package unmus
* @since 0.9
*/

function unmus_media_path ( $param ){

$year=date("Y");
$custom_path = '/'.$year;

$param['path'] = $param['path'] . $custom_path;
$param['url'] = $param['url'] . $custom_path;

return $param;

}
add_filter('upload_dir', 'unmus_media_path');

?>