Social Icons WordPress Plugin – AccessPress Social Icons - Version 1.6.3

Version Description

  • Declared constants using method of the main plugin's class
Download this release

Release Info

Developer Access Keys
Plugin Icon 128x128 Social Icons WordPress Plugin – AccessPress Social Icons
Version 1.6.3
Comparing to
See all releases

Code changes from version 1.6.2 to 1.6.3

Files changed (2) hide show
  1. accesspress-social-icons.php +48 -37
  2. readme.txt +4 -1
accesspress-social-icons.php CHANGED
@@ -4,50 +4,14 @@ defined('ABSPATH') or die("No script kiddies please!");
4
  * Plugin Name:AccessPress Social Icons
5
  * Plugin URI: https://accesspressthemes.com/wordpress-plugins/accesspress-social-icons/
6
  * Description: A plugin to add social icons in your site wherever you want dynamically with handful of configurable settings.
7
- * Version:1.6.2
8
  * Author:AccessPress Themes
9
  * Author URI:http://accesspressthemes.com/
10
  * Text Domain: accesspress-social-icons
11
  * Domain Path: /languages/
12
  * License:GPLv2 or later
13
  * */
14
- /**
15
- * Declartion of necessary constants for plugin
16
- * */
17
- if (!defined('APS_IMAGE_DIR')) {
18
- define('APS_IMAGE_DIR', plugin_dir_url(__FILE__) . 'images');
19
- }
20
- if (!defined('APS_JS_DIR')) {
21
- define('APS_JS_DIR', plugin_dir_url(__FILE__) . 'js');
22
- }
23
- if (!defined('APS_CSS_DIR')) {
24
- define('APS_CSS_DIR', plugin_dir_url(__FILE__) . 'css');
25
- }
26
 
27
- /**
28
- * @since 1.5.3
29
- *
30
- * */
31
- defined('APSI_PLUGIN_URL') or define('APSI_PLUGIN_URL',plugin_dir_url(__FILE__));
32
-
33
- if (!defined('APS_ICONS_DIR')) {
34
- /**
35
- * apsi_icons_sets_directory filter
36
- *
37
- * since @1.5.2
38
- *
39
- * Can be hooked to change http to https
40
- *
41
- * */
42
- define('APS_ICONS_DIR', apply_filters('apsi_icon_sets_directory',plugin_dir_url(__FILE__) . 'icon-sets'));
43
- }
44
- if (!defined('APS_LANG_DIR')) {
45
- define('APS_LANG_DIR', basename( dirname( __FILE__ ) ) . '/languages');
46
- }
47
- if(!defined('APS_VERSION'))
48
- {
49
- define('APS_VERSION','1.6.2');
50
- }
51
  /**
52
  * Register of widgets
53
  * */
@@ -59,6 +23,7 @@ if (!class_exists('APS_Class')) {
59
  * Initialization of plugin from constructor
60
  * */
61
  function __construct() {
 
62
  register_activation_hook(__FILE__, array($this, 'plugin_activation')); //calls plugin activation function
63
  add_action('init', array($this, 'plugin_text_domain')); //loads text domain for translation ready
64
  add_action('wp_enqueue_scripts', array($this, 'register_frontend_assets'));//registers assets for frontend
@@ -77,6 +42,52 @@ if (!class_exists('APS_Class')) {
77
  add_filter('apsi_image_url',array($this,'check_url'));
78
 
79
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
80
 
81
  //called when plugin is activated
82
  function plugin_activation() {
4
  * Plugin Name:AccessPress Social Icons
5
  * Plugin URI: https://accesspressthemes.com/wordpress-plugins/accesspress-social-icons/
6
  * Description: A plugin to add social icons in your site wherever you want dynamically with handful of configurable settings.
7
+ * Version:1.6.3
8
  * Author:AccessPress Themes
9
  * Author URI:http://accesspressthemes.com/
10
  * Text Domain: accesspress-social-icons
11
  * Domain Path: /languages/
12
  * License:GPLv2 or later
13
  * */
 
 
 
 
 
 
 
 
 
 
 
 
14
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
15
  /**
16
  * Register of widgets
17
  * */
23
  * Initialization of plugin from constructor
24
  * */
25
  function __construct() {
26
+ $this->define_constants();
27
  register_activation_hook(__FILE__, array($this, 'plugin_activation')); //calls plugin activation function
28
  add_action('init', array($this, 'plugin_text_domain')); //loads text domain for translation ready
29
  add_action('wp_enqueue_scripts', array($this, 'register_frontend_assets'));//registers assets for frontend
42
  add_filter('apsi_image_url',array($this,'check_url'));
43
 
44
  }
45
+
46
+ /**
47
+ * Declartion of necessary constants for plugin
48
+ *
49
+ * Previously declare outside the class
50
+ *
51
+ * @since 1.6.3
52
+ *
53
+ * */
54
+ function define_constants(){
55
+
56
+ if (!defined('APS_IMAGE_DIR')) {
57
+ define('APS_IMAGE_DIR', plugin_dir_url(__FILE__) . 'images');
58
+ }
59
+ if (!defined('APS_JS_DIR')) {
60
+ define('APS_JS_DIR', plugin_dir_url(__FILE__) . 'js');
61
+ }
62
+ if (!defined('APS_CSS_DIR')) {
63
+ define('APS_CSS_DIR', plugin_dir_url(__FILE__) . 'css');
64
+ }
65
+
66
+ /**
67
+ * @since 1.5.3
68
+ *
69
+ * */
70
+ defined('APSI_PLUGIN_URL') or define('APSI_PLUGIN_URL',plugin_dir_url(__FILE__));
71
+
72
+ if (!defined('APS_ICONS_DIR')) {
73
+ /**
74
+ * apsi_icons_sets_directory filter
75
+ *
76
+ * since @1.5.2
77
+ *
78
+ * Can be hooked to change http to https
79
+ *
80
+ * */
81
+ define('APS_ICONS_DIR', apply_filters('apsi_icon_sets_directory',plugin_dir_url(__FILE__) . 'icon-sets'));
82
+ }
83
+ if (!defined('APS_LANG_DIR')) {
84
+ define('APS_LANG_DIR', basename( dirname( __FILE__ ) ) . '/languages');
85
+ }
86
+ if(!defined('APS_VERSION'))
87
+ {
88
+ define('APS_VERSION','1.6.3');
89
+ }
90
+ }
91
 
92
  //called when plugin is activated
93
  function plugin_activation() {
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: social icon, social icons, social media, social icon widget, social icons
4
  Donate link: http://accesspressthemes.com/donation/
5
  Requires at least: 4.0
6
  Tested up to: 4.6
7
- Stable tag: 1.6.2
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -133,6 +133,9 @@ Once you install the plugin , you can check some general documentation about how
133
  4. Backend Lcon Sets Listing
134
 
135
  == Changelog ==
 
 
 
136
  = 1.6.2 =
137
  * Done small modification in backend message display
138
 
4
  Donate link: http://accesspressthemes.com/donation/
5
  Requires at least: 4.0
6
  Tested up to: 4.6
7
+ Stable tag: 1.6.3
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
133
  4. Backend Lcon Sets Listing
134
 
135
  == Changelog ==
136
+ = 1.6.3 =
137
+ * Declared constants using method of the main plugin's class
138
+
139
  = 1.6.2 =
140
  * Done small modification in backend message display
141