All In One Favicon - Version 3.1

Version Description

(2011-01-16) = * CHANGE: made plugin compatible to PHP4

Download this release

Release Info

Developer techotronic
Plugin Icon 128x128 All In One Favicon
Version 3.1
Comparing to
See all releases

Code changes from version 3.0 to 3.1

Files changed (2) hide show
  1. all-in-one-favicon.php +32 -17
  2. readme.txt +4 -1
all-in-one-favicon.php CHANGED
@@ -6,7 +6,7 @@
6
  * Plugin Name: All in one Favicon
7
  * Plugin URI: http://www.techotronic.de/plugins/all-in-one-favicon/
8
  * Description: All in one Favicon management. Easily add a Favicon to your site and the WordPress admin pages. Complete with upload functionality. Supports all three Favicon types (ico,png,gif)
9
- * Version: 3.0
10
  * Author: Arne Franken
11
  * Author URI: http://www.techotronic.de/
12
  * License: GPL
@@ -18,7 +18,7 @@
18
  */
19
 
20
  // define constants
21
- define('AIOFAVICON_VERSION', '3.0');
22
 
23
  if (!defined('AIOFAVICON_PLUGIN_BASENAME')) {
24
  define('AIOFAVICON_PLUGIN_BASENAME', plugin_basename(__FILE__));
@@ -63,7 +63,8 @@ class AllInOneFavicon {
63
  * @access public
64
  * @author Arne Franken
65
  */
66
- public function allInOneFavicon(){
 
67
 
68
  load_plugin_textdomain(AIOFAVICON_TEXTDOMAIN, false, '/all-in-one-favicon/localization/');
69
 
@@ -107,7 +108,8 @@ class AllInOneFavicon {
107
  * @access public
108
  * @author Arne Franken
109
  */
110
- public function renderMetaLink() { ?>
 
111
  <li><?php _e('Using',AIOFAVICON_TEXTDOMAIN);?> <a href="http://www.techotronic.de/plugins/all-in-one-favicon/" title="<?php echo AIOFAVICON_NAME ?>"><?php echo AIOFAVICON_NAME ?></a></li>
112
  <?php }
113
 
@@ -120,7 +122,8 @@ class AllInOneFavicon {
120
  * @access public
121
  * @author Arne Franken
122
  */
123
- public function registerAdminScripts() {
 
124
  wp_enqueue_script('media-upload');
125
  wp_enqueue_script('thickbox');
126
  wp_register_script('aioFaviconUpload', AIOFAVICON_PLUGIN_URL .'/js/backend.js', array('jquery','media-upload','thickbox'));
@@ -136,7 +139,8 @@ class AllInOneFavicon {
136
  * @access public
137
  * @author Arne Franken
138
  */
139
- public function registerAdminStyles() {
 
140
  wp_enqueue_style('thickbox');
141
  }
142
 
@@ -149,7 +153,8 @@ class AllInOneFavicon {
149
  * @access public
150
  * @author Arne Franken
151
  */
152
- public function renderSettingsPage() {
 
153
  include_once 'includes/settings-page.php';
154
  }
155
 
@@ -162,7 +167,8 @@ class AllInOneFavicon {
162
  * @access private
163
  * @author Arne Franken
164
  */
165
- private function registerSettingsPage() {
 
166
  if (current_user_can('manage_options')) {
167
  add_options_page(AIOFAVICON_NAME, AIOFAVICON_NAME, 'manage_options', AIOFAVICON_PLUGIN_BASENAME, array(& $this, 'renderSettingsPage'));
168
  }
@@ -177,7 +183,8 @@ class AllInOneFavicon {
177
  * @access public
178
  * @author Arne Franken
179
  */
180
- public function registerAdminMenu() {
 
181
  if (function_exists('add_management_page') && current_user_can('manage_options')) {
182
 
183
  // update, uninstall message
@@ -203,7 +210,8 @@ class AllInOneFavicon {
203
  * @access private
204
  * @author Arne Franken
205
  */
206
- private function registerAdminNotice($notice) {
 
207
  if ($notice != '') {
208
  $message = '<div class="updated fade"><p>' . $notice . '</p></div>';
209
  add_action('admin_notices', create_function('', "echo '$message';"));
@@ -219,7 +227,8 @@ class AllInOneFavicon {
219
  * @access private
220
  * @author Arne Franken
221
  */
222
- private function aioFaviconDefaultSettings() {
 
223
 
224
  // Create and return array of default settings
225
  return array(
@@ -240,7 +249,8 @@ class AllInOneFavicon {
240
  * @access public
241
  * @author Arne Franken
242
  */
243
- public function aioFaviconUpdateSettings() {
 
244
 
245
  if (!current_user_can('manage_options'))
246
  wp_die(__('Did not update settings, you do not have the necessary rights.', AIOFAVICON_TEXTDOMAIN));
@@ -267,7 +277,8 @@ class AllInOneFavicon {
267
  * @access private
268
  * @author Arne Franken
269
  */
270
- private function updateSettingsInDatabase() {
 
271
  update_option(AIOFAVICON_SETTINGSNAME, $this->aioFaviconSettings);
272
  }
273
 
@@ -283,7 +294,8 @@ class AllInOneFavicon {
283
  * @access public
284
  * @author Arne Franken
285
  */
286
- public function aioFaviconDeleteSettings() {
 
287
 
288
  if (current_user_can('manage_options') && isset($_POST['delete_settings-true'])) {
289
  //cross check the given referer for nonce set in delete settings form
@@ -308,7 +320,8 @@ class AllInOneFavicon {
308
  * @access private
309
  * @author Arne Franken
310
  */
311
- private function deleteSettingsFromDatabase() {
 
312
  delete_option(AIOFAVICON_SETTINGSNAME);
313
  }
314
 
@@ -324,7 +337,8 @@ class AllInOneFavicon {
324
  * @param string $url
325
  * @return the response
326
  */
327
- private function getRemoteContent($url) {
 
328
  if ( function_exists('wp_remote_request') ) {
329
 
330
  $options = array();
@@ -355,7 +369,8 @@ class AllInOneFavicon {
355
  * @access private
356
  * @author Arne Franken
357
  */
358
- private function getReturnLocation(){
 
359
  $currentLocation = "http";
360
  $currentLocation .= ((isset($_SERVER['HTTPS']) && $_SERVER['HTTPS']=='on') ? "s" : "")."://";
361
  $currentLocation .= $_SERVER['SERVER_NAME'];
6
  * Plugin Name: All in one Favicon
7
  * Plugin URI: http://www.techotronic.de/plugins/all-in-one-favicon/
8
  * Description: All in one Favicon management. Easily add a Favicon to your site and the WordPress admin pages. Complete with upload functionality. Supports all three Favicon types (ico,png,gif)
9
+ * Version: 3.1
10
  * Author: Arne Franken
11
  * Author URI: http://www.techotronic.de/
12
  * License: GPL
18
  */
19
 
20
  // define constants
21
+ define('AIOFAVICON_VERSION', '3.1');
22
 
23
  if (!defined('AIOFAVICON_PLUGIN_BASENAME')) {
24
  define('AIOFAVICON_PLUGIN_BASENAME', plugin_basename(__FILE__));
63
  * @access public
64
  * @author Arne Franken
65
  */
66
+ //public function allInOneFavicon(){
67
+ function allInOneFavicon(){
68
 
69
  load_plugin_textdomain(AIOFAVICON_TEXTDOMAIN, false, '/all-in-one-favicon/localization/');
70
 
108
  * @access public
109
  * @author Arne Franken
110
  */
111
+ //public function renderMetaLink() {
112
+ function renderMetaLink() { ?>
113
  <li><?php _e('Using',AIOFAVICON_TEXTDOMAIN);?> <a href="http://www.techotronic.de/plugins/all-in-one-favicon/" title="<?php echo AIOFAVICON_NAME ?>"><?php echo AIOFAVICON_NAME ?></a></li>
114
  <?php }
115
 
122
  * @access public
123
  * @author Arne Franken
124
  */
125
+ //public function registerAdminScripts() {
126
+ function registerAdminScripts() {
127
  wp_enqueue_script('media-upload');
128
  wp_enqueue_script('thickbox');
129
  wp_register_script('aioFaviconUpload', AIOFAVICON_PLUGIN_URL .'/js/backend.js', array('jquery','media-upload','thickbox'));
139
  * @access public
140
  * @author Arne Franken
141
  */
142
+ //public function registerAdminStyles() {
143
+ function registerAdminStyles() {
144
  wp_enqueue_style('thickbox');
145
  }
146
 
153
  * @access public
154
  * @author Arne Franken
155
  */
156
+ //public function renderSettingsPage() {
157
+ function renderSettingsPage() {
158
  include_once 'includes/settings-page.php';
159
  }
160
 
167
  * @access private
168
  * @author Arne Franken
169
  */
170
+ //private function registerSettingsPage() {
171
+ function registerSettingsPage() {
172
  if (current_user_can('manage_options')) {
173
  add_options_page(AIOFAVICON_NAME, AIOFAVICON_NAME, 'manage_options', AIOFAVICON_PLUGIN_BASENAME, array(& $this, 'renderSettingsPage'));
174
  }
183
  * @access public
184
  * @author Arne Franken
185
  */
186
+ //public function registerAdminMenu() {
187
+ function registerAdminMenu() {
188
  if (function_exists('add_management_page') && current_user_can('manage_options')) {
189
 
190
  // update, uninstall message
210
  * @access private
211
  * @author Arne Franken
212
  */
213
+ //private function registerAdminNotice($notice) {
214
+ function registerAdminNotice($notice) {
215
  if ($notice != '') {
216
  $message = '<div class="updated fade"><p>' . $notice . '</p></div>';
217
  add_action('admin_notices', create_function('', "echo '$message';"));
227
  * @access private
228
  * @author Arne Franken
229
  */
230
+ //private function aioFaviconDefaultSettings() {
231
+ function aioFaviconDefaultSettings() {
232
 
233
  // Create and return array of default settings
234
  return array(
249
  * @access public
250
  * @author Arne Franken
251
  */
252
+ //public function aioFaviconUpdateSettings() {
253
+ function aioFaviconUpdateSettings() {
254
 
255
  if (!current_user_can('manage_options'))
256
  wp_die(__('Did not update settings, you do not have the necessary rights.', AIOFAVICON_TEXTDOMAIN));
277
  * @access private
278
  * @author Arne Franken
279
  */
280
+ //private function updateSettingsInDatabase() {
281
+ function updateSettingsInDatabase() {
282
  update_option(AIOFAVICON_SETTINGSNAME, $this->aioFaviconSettings);
283
  }
284
 
294
  * @access public
295
  * @author Arne Franken
296
  */
297
+ //public function aioFaviconDeleteSettings() {
298
+ function aioFaviconDeleteSettings() {
299
 
300
  if (current_user_can('manage_options') && isset($_POST['delete_settings-true'])) {
301
  //cross check the given referer for nonce set in delete settings form
320
  * @access private
321
  * @author Arne Franken
322
  */
323
+ //private function deleteSettingsFromDatabase() {
324
+ function deleteSettingsFromDatabase() {
325
  delete_option(AIOFAVICON_SETTINGSNAME);
326
  }
327
 
337
  * @param string $url
338
  * @return the response
339
  */
340
+ //private function getRemoteContent($url) {
341
+ function getRemoteContent($url) {
342
  if ( function_exists('wp_remote_request') ) {
343
 
344
  $options = array();
369
  * @access private
370
  * @author Arne Franken
371
  */
372
+ //private function getReturnLocation(){
373
+ function getReturnLocation(){
374
  $currentLocation = "http";
375
  $currentLocation .= ((isset($_SERVER['HTTPS']) && $_SERVER['HTTPS']=='on') ? "s" : "")."://";
376
  $currentLocation .= $_SERVER['SERVER_NAME'];
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: http://www.techotronic.de/donate/
4
  Tags: theme, favicon, admin, blog, wordpress, image, images, graphic, graphics, icon, iphone, multisite
5
  Requires at least: 2.8
6
  Tested up to: 3.0
7
- Stable tag: 3.0
8
 
9
  Easily add a Favicon to your site and the WordPress admin pages. Complete with upload functionality. Supports all three Favicon types (ico,png,gif).
10
 
@@ -108,6 +108,9 @@ I'll include new FAQs in every new version. Promise.
108
  <a href="http://www.techotronic.de/plugins/all-in-one-favicon/">Please visit my site for screenshots</a>.
109
 
110
  == Changelog ==
 
 
 
111
  = 3.0 (2011-01-15) =
112
  * NEW: Added option to remove link from meta box.
113
  * BUGFIX: Fixed a bug where the plugin would break WordPress 3.0 with Multisite enabled.
4
  Tags: theme, favicon, admin, blog, wordpress, image, images, graphic, graphics, icon, iphone, multisite
5
  Requires at least: 2.8
6
  Tested up to: 3.0
7
+ Stable tag: 3.1
8
 
9
  Easily add a Favicon to your site and the WordPress admin pages. Complete with upload functionality. Supports all three Favicon types (ico,png,gif).
10
 
108
  <a href="http://www.techotronic.de/plugins/all-in-one-favicon/">Please visit my site for screenshots</a>.
109
 
110
  == Changelog ==
111
+ = 3.1 (2011-01-16) =
112
+ * CHANGE: made plugin compatible to PHP4
113
+
114
  = 3.0 (2011-01-15) =
115
  * NEW: Added option to remove link from meta box.
116
  * BUGFIX: Fixed a bug where the plugin would break WordPress 3.0 with Multisite enabled.