Media from FTP - Version 10.06

Version Description

Removed unnecessary code. Fixed problem of path acquisition.

Download this release

Release Info

Developer Katsushi Kawamori
Plugin Icon wp plugin Media from FTP
Version 10.06
Comparing to
See all releases

Code changes from version 10.05 to 10.06

Files changed (3) hide show
  1. mediafromftp.php +1 -1
  2. readme.txt +5 -1
  3. req/MediaFromFtpAdmin.php +2 -4
mediafromftp.php CHANGED
@@ -2,7 +2,7 @@
2
  /*
3
  Plugin Name: Media from FTP
4
  Plugin URI: https://wordpress.org/plugins/media-from-ftp/
5
- Version: 10.05
6
  Description: Register to media library from files that have been uploaded by FTP.
7
  Author: Katsushi Kawamori
8
  Author URI: https://riverforest-wp.info/
2
  /*
3
  Plugin Name: Media from FTP
4
  Plugin URI: https://wordpress.org/plugins/media-from-ftp/
5
+ Version: 10.06
6
  Description: Register to media library from files that have been uploaded by FTP.
7
  Author: Katsushi Kawamori
8
  Author URI: https://riverforest-wp.info/
readme.txt CHANGED
@@ -5,7 +5,7 @@ Tags: files, ftp, import, media, sync, uploads
5
  Requires at least: 3.6.0
6
  Requires PHP: 5.3.0
7
  Tested up to: 4.9
8
- Stable tag: 10.05
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
@@ -123,6 +123,10 @@ Register to media library from files that have been uploaded by FTP.
123
 
124
  == Changelog ==
125
 
 
 
 
 
126
  = 10.05 =
127
  Fixed initial setup problem of log creation for multi-site.
128
 
5
  Requires at least: 3.6.0
6
  Requires PHP: 5.3.0
7
  Tested up to: 4.9
8
+ Stable tag: 10.06
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
11
 
123
 
124
  == Changelog ==
125
 
126
+ = 10.06 =
127
+ Removed unnecessary code.
128
+ Fixed problem of path acquisition.
129
+
130
  = 10.05 =
131
  Fixed initial setup problem of log creation for multi-site.
132
 
req/MediaFromFtpAdmin.php CHANGED
@@ -26,7 +26,6 @@ add_action( 'admin_notices', array($mediafromftpadmin, 'notices') );
26
 
27
  class MediaFromFtpAdmin {
28
 
29
- private $plugin_base_file;
30
  private $plugin_base_url;
31
  private $plugin_dir;
32
  private $upload_dir;
@@ -46,8 +45,7 @@ class MediaFromFtpAdmin {
46
  $plugin_base_dir = untrailingslashit(plugin_dir_path( __DIR__ ));
47
  $slugs = explode('/', $plugin_base_dir);
48
  $slug = end($slugs);
49
- $this->plugin_base_file = $slug.'/mediafromftp.php';
50
- $this->plugin_base_url = plugins_url($path='',$scheme=null).'/'.$slug;
51
  $this->plugin_dir = untrailingslashit(rtrim($plugin_base_dir, $slug));
52
 
53
  if(!class_exists('MediaFromFtp')){
@@ -107,7 +105,7 @@ class MediaFromFtpAdmin {
107
  public function settings_link( $links, $file ) {
108
  static $this_plugin;
109
  if ( empty($this_plugin) ) {
110
- $this_plugin = $this->plugin_base_file;
111
  }
112
  if ( $file == $this_plugin ) {
113
  $links[] = '<a href="'.admin_url('admin.php?page=mediafromftp').'">Media from FTP</a>';
26
 
27
  class MediaFromFtpAdmin {
28
 
 
29
  private $plugin_base_url;
30
  private $plugin_dir;
31
  private $upload_dir;
45
  $plugin_base_dir = untrailingslashit(plugin_dir_path( __DIR__ ));
46
  $slugs = explode('/', $plugin_base_dir);
47
  $slug = end($slugs);
48
+ $this->plugin_base_url = untrailingslashit(plugin_dir_url( __DIR__ ));
 
49
  $this->plugin_dir = untrailingslashit(rtrim($plugin_base_dir, $slug));
50
 
51
  if(!class_exists('MediaFromFtp')){
105
  public function settings_link( $links, $file ) {
106
  static $this_plugin;
107
  if ( empty($this_plugin) ) {
108
+ $this_plugin = 'media-from-ftp/mediafromftp.php';
109
  }
110
  if ( $file == $this_plugin ) {
111
  $links[] = '<a href="'.admin_url('admin.php?page=mediafromftp').'">Media from FTP</a>';