Better Font Awesome - Version 1.0.1

Version Description

  • Fix error handling for 404 API requests.
Download this release

Release Info

Developer McGuive7
Plugin Icon 128x128 Better Font Awesome
Version 1.0.1
Comparing to
See all releases

Code changes from version 1.0.0 to 1.0.1

better-font-awesome.php CHANGED
@@ -12,7 +12,7 @@
12
  * Plugin Name: Better Font Awesome
13
  * Plugin URI: http://wordpress.org/plugins/better-font-awesome
14
  * Description: The ultimate Font Awesome icon plugin for WordPress.
15
- * Version: 1.0.0
16
  * Author: MIGHTYminnow & Mickey Kay
17
  * Author URI: mickey@mickeykaycreative.com
18
  * License: GPLv2+
12
  * Plugin Name: Better Font Awesome
13
  * Plugin URI: http://wordpress.org/plugins/better-font-awesome
14
  * Description: The ultimate Font Awesome icon plugin for WordPress.
15
+ * Version: 1.0.1
16
  * Author: MIGHTYminnow & Mickey Kay
17
  * Author URI: mickey@mickeykaycreative.com
18
  * License: GPLv2+
languages/better-font-awesome.pot CHANGED
@@ -2,9 +2,9 @@
2
  # This file is distributed under the same license as the Better Font Awesome package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Better Font Awesome 0.9.3\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/better-font-awesome\n"
7
- "POT-Creation-Date: 2014-04-21 00:53:22+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
@@ -12,186 +12,143 @@ msgstr ""
12
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
 
15
- #: Titan-Framework/class-admin-panel.php:290
16
- msgid "Settings saved."
17
- msgstr ""
18
-
19
- #: Titan-Framework/class-admin-panel.php:292
20
- msgid "Settings reset to default."
21
- msgstr ""
22
-
23
- #: Titan-Framework/class-meta-box.php:35
24
- #: Titan-Framework/class-theme-customizer-section.php:30
25
- msgid "More Options"
26
- msgstr ""
27
-
28
- #: Titan-Framework/class-option-save.php:20
29
- msgid "Save Changes"
30
- msgstr ""
31
-
32
- #: Titan-Framework/class-option-save.php:23
33
- msgid "Reset to Default"
34
- msgstr ""
35
-
36
- #: Titan-Framework/class-option-select-categories.php:37
37
- #: Titan-Framework/class-option-select-categories.php:104
38
- #: Titan-Framework/class-option-select-pages.php:30
39
- #: Titan-Framework/class-option-select-posts.php:38
40
- #: Titan-Framework/class-option-select-posts.php:106
41
- msgid "Select"
42
  msgstr ""
43
 
44
- #: Titan-Framework/class-option-select-googlefont.php:29
45
  msgid ""
46
- "%s has been deprecated and will be removed in version %s! Please use %s "
47
- "instead to avoid errors in the future."
 
 
 
 
 
 
 
 
 
 
48
  msgstr ""
49
 
50
- #: Titan-Framework/class-option-select-googlefont.php:108
51
- msgid "Ultra-light"
52
  msgstr ""
53
 
54
- #: Titan-Framework/class-option-select-googlefont.php:111
55
- msgid "Light"
56
  msgstr ""
57
 
58
- #: Titan-Framework/class-option-select-googlefont.php:114
59
- msgid "Book"
60
- msgstr ""
61
-
62
- #: Titan-Framework/class-option-select-googlefont.php:117
63
- msgid "Medium"
64
- msgstr ""
65
-
66
- #: Titan-Framework/class-option-select-googlefont.php:120
67
- msgid "Semi-Bold"
68
- msgstr ""
69
-
70
- #: Titan-Framework/class-option-select-googlefont.php:123
71
- msgid "Bold"
72
- msgstr ""
73
-
74
- #: Titan-Framework/class-option-select-googlefont.php:126
75
- msgid "Extra-Bold"
76
- msgstr ""
77
-
78
- #: Titan-Framework/class-option-select-googlefont.php:129
79
- msgid "Ultra-Bold"
80
- msgstr ""
81
-
82
- #: Titan-Framework/class-option-select-googlefont.php:132
83
- msgid "Regular"
84
- msgstr ""
85
-
86
- #: Titan-Framework/class-option-upload.php:196
87
- msgid "Select Image"
88
- msgstr ""
89
-
90
- #: Titan-Framework/class-option-upload.php:199
91
- msgid "Use image"
92
- msgstr ""
93
-
94
- #: Titan-Framework/class-option.php:40
95
- msgid "Option type or extended class %s does not exist."
96
- msgstr ""
97
-
98
- #: Titan-Framework/class-titan-framework.php:85
99
- msgid "All option IDs must be unique. The id %s has been used multiple times."
100
  msgstr ""
101
 
102
- #: Titan-Framework/class-titan-framework.php:346
103
- #: Titan-Framework/class-titan-framework.php:393
104
  msgid ""
105
- "Wrong usage of %s, this should be called inside a hook or from within a "
106
- "theme file."
107
- msgstr ""
108
-
109
- #: Titan-Framework/titan-framework.php:126
110
- msgid "Documentation"
111
  msgstr ""
112
 
113
- #: Titan-Framework/titan-framework.php:130
114
- msgid "GitHub Repo"
115
  msgstr ""
116
 
117
- #: Titan-Framework/titan-framework.php:134
118
- msgid "Issue Tracker"
 
 
119
  msgstr ""
120
 
121
- #: better-font-awesome.php:189
122
- msgid "Latest"
123
  msgstr ""
124
 
125
- #. #-#-#-#-# plugin.pot (Better Font Awesome 0.9.3) #-#-#-#-#
126
- #. Plugin Name of the plugin/theme
127
- #: better-font-awesome.php:198
128
- msgid "Better Font Awesome"
129
  msgstr ""
130
 
131
- #: better-font-awesome.php:203
132
- msgid "Font Awesome version"
133
  msgstr ""
134
 
135
- #: better-font-awesome.php:206
 
136
  msgid ""
137
- "Select the version of Font Awesome you would like to use. Visit the <a href="
138
- "\"http://fontawesome.io/\" target=\"_blank\">Font Awesome website</a> for "
139
- "more information."
140
- msgstr ""
141
-
142
- #: better-font-awesome.php:212
143
- msgid "Use minified CSS"
144
  msgstr ""
145
 
146
- #: better-font-awesome.php:215
147
  msgid ""
148
- "Whether to include the minified version of the CSS (checked), or the "
149
- "unminified version (unchecked)."
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
150
  msgstr ""
151
 
152
- #: better-font-awesome.php:220
153
- msgid "Remove existing Font Awesome styles and shortcodes"
154
  msgstr ""
155
 
156
- #: better-font-awesome.php:223
157
  msgid ""
158
- "Attempt to remove Font Awesome CSS and shortcodes included by other plugins "
159
- "and themes. This may help if icons are not rendering properly."
 
160
  msgstr ""
161
 
162
- #: better-font-awesome.php:228
163
- msgid "Usage"
 
 
164
  msgstr ""
165
 
166
- #: better-font-awesome.php:230
167
- msgid ""
168
- "\n"
169
- "\t\t \t\t<b>Version 4</b>&nbsp;&nbsp;&nbsp;<small><a href=\"http://"
170
- "fontawesome.io/examples/\">See all available classes &raquo;</a></small><br /"
171
- "><br />\n"
172
- "\t\t \t\t<i class=\"icon-star fa fa-star\"></i> <code>[icon name=\"star\"]"
173
- "</code> or <code>&lt;i class=\"fa-star\"&gt;&lt;/i&gt;</code><br /><br />\n"
174
- "\t\t \t\t<i class=\"icon-star fa fa-star icon-2x fa-2x\"></i> <code>[icon "
175
- "name=\"star\" class=\"fa-2x\"]</code> or <code>&lt;i class=\"fa-star fa-2x"
176
- "\"&gt;&lt;/i&gt;</code><br /><br />\n"
177
- "\t\t \t\t<i class=\"icon-star fa fa-star icon-2x fa-2x icon-border fa-"
178
- "border\"></i> <code>[icon name=\"star\" class=\"fa-2x fa-border\"]</code> or "
179
- "<code>&lt;i class=\"fa-star fa-2x fa-border\"&gt;&lt;/i&gt;</code><br /><br /"
180
- "><br />\n"
181
- "\t\t \t\t<b>Version 3</b>&nbsp;&nbsp;&nbsp;<small><a href=\"http://"
182
- "fontawesome.io/3.2.1/examples/\">See all available classes &raquo;</a></"
183
- "small><br /><br />\n"
184
- "\t\t \t\t<i class=\"icon-star fa fa-star\"></i> <code>[icon name=\"star\"]"
185
- "</code> or <code>&lt;i class=\"icon-star\"&gt;&lt;/i&gt;</code><br /><br />\n"
186
- "\t\t \t\t<i class=\"icon-star fa fa-star icon-2x fa-2x\"></i> <code>[icon "
187
- "name=\"star\" class=\"icon-2x\"]</code> or <code>&lt;i class=\"icon-star "
188
- "icon-2x\"&gt;&lt;/i&gt;</code><br /><br />\n"
189
- "\t\t \t\t<i class=\"icon-star fa fa-star icon-2x fa-2x icon-border fa-"
190
- "border\"></i> <code>[icon name=\"star\" class=\"icon-2x icon-border\"]</"
191
- "code> or <code>&lt;i class=\"icon-star icon-2x icon-border\"&gt;&lt;/i&gt;</"
192
- "code>\n"
193
- "\n"
194
- "\t\t \t\t"
195
  msgstr ""
196
 
197
  #. Plugin URI of the plugin/theme
@@ -199,11 +156,11 @@ msgid "http://wordpress.org/plugins/better-font-awesome"
199
  msgstr ""
200
 
201
  #. Description of the plugin/theme
202
- msgid "The better Font Awesome icon plugin for Wordpress."
203
  msgstr ""
204
 
205
  #. Author of the plugin/theme
206
- msgid "Mickey Kay"
207
  msgstr ""
208
 
209
  #. Author URI of the plugin/theme
2
  # This file is distributed under the same license as the Better Font Awesome package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Better Font Awesome 1.0.2\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/better-font-awesome\n"
7
+ "POT-Creation-Date: 2014-09-03 16:31:22+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
12
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
 
15
+ #. #-#-#-#-# plugin.pot (Better Font Awesome 1.0.2) #-#-#-#-#
16
+ #. Plugin Name of the plugin/theme
17
+ #: better-font-awesome.php:179 better-font-awesome.php:216
18
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:1016
19
+ msgid "Better Font Awesome"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
20
  msgstr ""
21
 
22
+ #: better-font-awesome.php:217
23
  msgid ""
24
+ "It appears that Better Font Awesome is missing it's <a href=\"https://github."
25
+ "com/MickeyKay/better-font-awesome-library\" target=\"_blank\">core library</"
26
+ "a>, which typically occurs when cloning the Git repository and not updating "
27
+ "all submodules. Please refer to the plugin's <a href=\"https://github.com/"
28
+ "MickeyKay/better-font-awesome\" target=\"_blank\">installation instructions</"
29
+ "a> for details on how to properly install Better Font Awesome via Git. If "
30
+ "you installed from within WordPress, or via the wordpress.org repo, then "
31
+ "chances are the install failed and you can try again. If the issue persists, "
32
+ "please create a new topic on the plugin's <a href=\"http://wordpress.org/"
33
+ "support/plugin/better-font-awesome\" target=\"_blank\">support forum</a> or "
34
+ "file an issue on the <a href=\"https://github.com/MickeyKay/better-font-"
35
+ "awesome/issues\" target=\"_blank\">Github repo</a>."
36
  msgstr ""
37
 
38
+ #: better-font-awesome.php:218
39
+ msgid "Back to the plugins page &rarr;"
40
  msgstr ""
41
 
42
+ #: better-font-awesome.php:352
43
+ msgid "Version"
44
  msgstr ""
45
 
46
+ #: better-font-awesome.php:361
47
+ msgid "Use minified CSS"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48
  msgstr ""
49
 
50
+ #: better-font-awesome.php:367
 
51
  msgid ""
52
+ "Whether to include the minified version of the CSS (checked), or the "
53
+ "unminified version (unchecked)."
 
 
 
 
54
  msgstr ""
55
 
56
+ #: better-font-awesome.php:373
57
+ msgid "Remove existing Font Awesome"
58
  msgstr ""
59
 
60
+ #: better-font-awesome.php:379
61
+ msgid ""
62
+ "Attempt to remove Font Awesome CSS and shortcodes added by other plugins and "
63
+ "themes."
64
  msgstr ""
65
 
66
+ #: better-font-awesome.php:396 better-font-awesome.php:422
67
+ msgid "Always Latest"
68
  msgstr ""
69
 
70
+ #: better-font-awesome.php:456
71
+ msgid ""
72
+ "Version selection is currently unavailable. The attempt to reach the "
73
+ "jsDelivr API server failed with the following error: %s"
74
  msgstr ""
75
 
76
+ #: better-font-awesome.php:463
77
+ msgid "Font Awesome will still render using version: %s"
78
  msgstr ""
79
 
80
+ #: better-font-awesome.php:470
81
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:1052
82
  msgid ""
83
+ "This may be the result of a temporary server or connectivity issue which "
84
+ "will resolve shortly. However if the problem persists please file a support "
85
+ "ticket on the %splugin forum%s, citing the errors listed above. "
 
 
 
 
86
  msgstr ""
87
 
88
+ #: better-font-awesome.php:517
89
  msgid ""
90
+ "<h3>Usage</h3>\n"
91
+ " <b>Font Awesome version 4.x +</b>&nbsp;&nbsp;&nbsp;"
92
+ "<small><a href=\"http://fontawesome.io/examples/\">See all available options "
93
+ "&raquo;</a></small><br /><br />\n"
94
+ " <i class=\"icon-coffee fa fa-coffee\"></i> <code>[icon "
95
+ "name=\"coffee\"]</code> or <code>&lt;i class=\"fa-coffee\"&gt;&lt;/i&gt;</"
96
+ "code><br /><br />\n"
97
+ " <i class=\"icon-coffee fa fa-coffee icon-2x fa-2x\"></"
98
+ "i> <code>[icon name=\"coffee\" class=\"fa-2x\"]</code> or <code>&lt;i class="
99
+ "\"fa-coffee fa-2x\"&gt;&lt;/i&gt;</code><br /><br />\n"
100
+ " <i class=\"icon-coffee fa fa-coffee icon-2x fa-2x icon-"
101
+ "rotate-90 fa-rotate-90\"></i> <code>[icon name=\"coffee\" class=\"fa-2x fa-"
102
+ "rotate-90\"]</code> or <code>&lt;i class=\"fa-coffee fa-2x fa-rotate-90\"&gt;"
103
+ "&lt;/i&gt;</code><br /><br /><br />\n"
104
+ " <b>Font Awesome version 3.x</b>&nbsp;&nbsp;&nbsp;"
105
+ "<small><a href=\"http://fontawesome.io/3.2.1/examples/\">See all available "
106
+ "options &raquo;</a></small><br /><br />\n"
107
+ " <i class=\"icon-coffee fa fa-coffee\"></i> <code>[icon "
108
+ "name=\"coffee\"]</code> or <code>&lt;i class=\"icon-coffee\"&gt;&lt;/i&gt;</"
109
+ "code><br /><br />\n"
110
+ " <i class=\"icon-coffee fa fa-coffee icon-2x fa-2x\"></"
111
+ "i> <code>[icon name=\"coffee\" class=\"icon-2x\"]</code> or <code>&lt;i "
112
+ "class=\"icon-coffee icon-2x\"&gt;&lt;/i&gt;</code><br /><br />\n"
113
+ " <i class=\"icon-coffee fa fa-coffee icon-2x fa-2x icon-"
114
+ "rotate-90 fa-rotate-90\"></i> <code>[icon name=\"coffee\" class=\"icon-2x "
115
+ "icon-rotate-90\"]</code> or <code>&lt;i class=\"icon-coffee icon-2x icon-"
116
+ "rotate-90\"&gt;&lt;/i&gt;</code>"
117
+ msgstr ""
118
+
119
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:430
120
+ msgid "The jsDelivr API servers appear to be temporarily unavailable."
121
+ msgstr ""
122
+
123
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:1022
124
+ msgid "API Error"
125
+ msgstr ""
126
+
127
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:1024
128
+ msgid ""
129
+ "The attempt to reach the jsDelivr API server failed with the following "
130
+ "error: %s"
131
  msgstr ""
132
 
133
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:1034
134
+ msgid "Remote CSS Error"
135
  msgstr ""
136
 
137
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:1036
138
  msgid ""
139
+ "The attempt to fetch the remote Font Awesome stylesheet failed with the "
140
+ "following error: %s %s The embedded fallback Font Awesome will be used "
141
+ "instead (version: %s)."
142
  msgstr ""
143
 
144
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:1046
145
+ msgid ""
146
+ "<b>Don't worry! Better Font Awesome will still render using the included "
147
+ "fallback version:</b> "
148
  msgstr ""
149
 
150
+ #: lib/better-font-awesome-library/better-font-awesome-library.php:1050
151
+ msgid "Solution"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
152
  msgstr ""
153
 
154
  #. Plugin URI of the plugin/theme
156
  msgstr ""
157
 
158
  #. Description of the plugin/theme
159
+ msgid "The ultimate Font Awesome icon plugin for WordPress."
160
  msgstr ""
161
 
162
  #. Author of the plugin/theme
163
+ msgid "MIGHTYminnow & Mickey Kay"
164
  msgstr ""
165
 
166
  #. Author URI of the plugin/theme
lib/better-font-awesome-library/better-font-awesome-library.php CHANGED
@@ -425,9 +425,14 @@ class Better_Font_Awesome_Library {
425
  // Set the API transient.
426
  set_transient( self::SLUG . '-api-versions', $response, $transient_expiration );
427
 
 
 
 
 
 
428
  } else {
429
 
430
- $this->set_error( 'api', $response->get_error_code(), $response->get_error_message() . " (URL: $url" );
431
  $response = '';
432
 
433
  }
@@ -1037,6 +1042,9 @@ class Better_Font_Awesome_Library {
1037
  </p>
1038
  <?php endif; ?>
1039
 
 
 
 
1040
  <!-- Solution Text -->
1041
  <p>
1042
  <b><?php _e( 'Solution', 'bfa' ); ?></b><br />
@@ -1222,4 +1230,4 @@ class Better_Font_Awesome_Library {
1222
  }
1223
 
1224
  }
1225
- endif;
425
  // Set the API transient.
426
  set_transient( self::SLUG . '-api-versions', $response, $transient_expiration );
427
 
428
+ } elseif ( ! $response || 404 == wp_remote_retrieve_response_code( $response ) ) {
429
+
430
+ $this->set_error( 'api', 404, __( 'The jsDelivr API servers appear to be temporarily unavailable.', 'bfa') . " (URL: $url)" );
431
+ $response = '';
432
+
433
  } else {
434
 
435
+ $this->set_error( 'api', $response->get_error_code(), $response->get_error_message() . " (URL: $url)" );
436
  $response = '';
437
 
438
  }
1042
  </p>
1043
  <?php endif; ?>
1044
 
1045
+ <!-- Fallback Text -->
1046
+ <p><?php echo __( '<b>Don\'t worry! Better Font Awesome will still render using the included fallback version:</b> ', 'bfa' ) . '<code>' . $this->fallback_data['version'] . '</code>' ; ?></p>
1047
+
1048
  <!-- Solution Text -->
1049
  <p>
1050
  <b><?php _e( 'Solution', 'bfa' ); ?></b><br />
1230
  }
1231
 
1232
  }
1233
+ endif;
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: better, font, awesome, icon, icons, bootstrap, fontstrap, cdn, shortcode
4
  Donate link: http://mightyminnow.com
5
  Requires at least: 3.0
6
  Tested up to: 4.0
7
- Stable tag: 1.0.0
8
  License: GPLv2+
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -105,6 +105,9 @@ Better Font Awesome does it's best to load after any existing Font Awesome CSS,
105
 
106
  == Changelog ==
107
 
 
 
 
108
  = 1.0.0 =
109
  * Fully refactor the back-end.
110
  * Switch to just using the jsDelivr CDN.
@@ -141,6 +144,9 @@ Better Font Awesome does it's best to load after any existing Font Awesome CSS,
141
 
142
  == Upgrade Notice ==
143
 
 
 
 
144
  = 1.0.0 =
145
  * Fully refactor the back-end.
146
  * Switch to just using the jsDelivr CDN.
4
  Donate link: http://mightyminnow.com
5
  Requires at least: 3.0
6
  Tested up to: 4.0
7
+ Stable tag: 1.0.1
8
  License: GPLv2+
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
105
 
106
  == Changelog ==
107
 
108
+ = 1.0.1 =
109
+ * Fix error handling for 404 API requests.
110
+
111
  = 1.0.0 =
112
  * Fully refactor the back-end.
113
  * Switch to just using the jsDelivr CDN.
144
 
145
  == Upgrade Notice ==
146
 
147
+ = 1.0.1 =
148
+ * Fix error handling for 404 API requests.
149
+
150
  = 1.0.0 =
151
  * Fully refactor the back-end.
152
  * Switch to just using the jsDelivr CDN.