Changeset 917767
- Timestamp:
- 05/20/2014 10:00:14 AM (12 years ago)
- Location:
- reaction-buttons
- Files:
-
- 4 edited
- 1 copied
-
tags/1.8.1 (copied) (copied from reaction-buttons/trunk)
-
tags/1.8.1/reaction_buttons.php (modified) (5 diffs)
-
tags/1.8.1/readme.txt (modified) (2 diffs)
-
trunk/reaction_buttons.php (modified) (5 diffs)
-
trunk/readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
reaction-buttons/tags/1.8.1/reaction_buttons.php
r913734 r917767 4 4 Plugin URI: http://blog.jl42.de/reaction-buttons/ 5 5 Description: Adds Buttons for very simple and fast feedback to your post. Inspired by Blogger. 6 Version: 1.8. 06 Version: 1.8.1 7 7 Author: Jakob Lenfers 8 8 Author URI: http://blog.jl42.de … … 1187 1187 */ 1188 1188 function reaction_buttons_widget_control(){ 1189 // save the settings if submitted 1190 if (isset($_REQUEST['savewidgets']) && $_REQUEST['savewidgets']) { 1191 // validate the input and update the settings 1192 if (isset($_POST['reaction_buttons_widget_title'])){ 1193 update_option('reaction_buttons_widget_title', esc_attr($_POST['reaction_buttons_widget_title'])); 1194 } 1195 1196 if (isset($_POST['reaction_buttons_widget_count'])){ 1197 $count = $_POST['reaction_buttons_widget_count']; 1198 if (is_numeric($count) && 0 < intval($count)) { 1199 update_option('reaction_buttons_widget_count', esc_attr($count)); 1200 } 1201 else { 1202 reaction_buttons_message(__("Please input a positiv number!", 'reaction_buttons')); 1203 } 1204 } 1205 1206 if (isset($_POST['reaction_buttons_widget_excerpt'])){ 1207 $excerpt = $_POST['reaction_buttons_widget_excerpt']; 1208 if (is_numeric($excerpt)) { 1209 update_option('reaction_buttons_widget_excerpt', esc_attr($excerpt)); 1210 } 1211 else { 1212 update_option('reaction_buttons_widget_excerpt', 0); 1213 } 1214 } 1215 if (isset($_POST['reaction_buttons_widget_buttons'])){ 1216 update_option('reaction_buttons_widget_buttons', esc_attr($_POST['reaction_buttons_widget_buttons'])); 1217 } 1218 if (isset($_POST['reaction_buttons_widget_thumb']) && $_POST['reaction_buttons_widget_thumb']){ 1219 update_option('reaction_buttons_widget_thumb', true); 1220 } 1221 else{ 1222 update_option('reaction_buttons_widget_thumb', false); 1223 } 1224 } 1225 1226 // show the current settings and the dialog 1189 1227 echo "<p>" . __("This widget shows the posts with the most clicks for each button.", 'reaction_buttons') . "</p>"; 1190 1191 // show the current settings and the dialog1192 1228 ?> 1193 1229 <p><label><?php _e("Title:", 'reaction_buttons') ?><br /> … … 1201 1237 <p><label><?php _e("Show a possible post thumbnail? (Might need some manual adaptations in your CSS to look nice.)", 'reaction_buttons') ?><br /> 1202 1238 <input name="reaction_buttons_widget_thumb" type="checkbox" <?php checked(get_option('reaction_buttons_widget_thumb', false), true); ?> /></label></p> 1203 1204 <?php 1205 // validate the input and update the settings 1206 if (isset($_POST['reaction_buttons_widget_title'])){ 1207 update_option('reaction_buttons_widget_title', esc_attr($_POST['reaction_buttons_widget_title'])); 1208 } 1209 1210 if (isset($_POST['reaction_buttons_widget_count'])){ 1211 $count = $_POST['reaction_buttons_widget_count']; 1212 if (is_numeric($count) && 0 < intval($count)) { 1213 update_option('reaction_buttons_widget_count', esc_attr($count)); 1214 } 1215 else { 1216 reaction_buttons_message(__("Please input a positiv number!", 'reaction_buttons')); 1217 } 1218 } 1219 1220 if (isset($_POST['reaction_buttons_widget_excerpt'])){ 1221 $excerpt = $_POST['reaction_buttons_widget_excerpt']; 1222 if (is_numeric($excerpt)) { 1223 update_option('reaction_buttons_widget_excerpt', esc_attr($excerpt)); 1224 } 1225 else { 1226 update_option('reaction_buttons_widget_excerpt', 0); 1227 } 1228 } 1229 if (isset($_POST['reaction_buttons_widget_buttons'])){ 1230 update_option('reaction_buttons_widget_buttons', esc_attr($_POST['reaction_buttons_widget_buttons'])); 1231 } 1232 if (isset($_POST['reaction_buttons_widget_thumb']) && $_POST['reaction_buttons_widget_thumb']){ 1233 update_option('reaction_buttons_widget_thumb',true); 1234 } 1235 else{ 1236 update_option('reaction_buttons_widget_thumb',false); 1237 } 1239 <?php 1238 1240 } 1239 1241 … … 1270 1272 */ 1271 1273 function reaction_buttons_clicked_widget_control(){ 1274 // save the settings if submitted 1275 if (isset($_REQUEST['savewidgets']) && $_REQUEST['savewidgets']) { 1276 // validate the input and update the settings 1277 if (isset($_POST['reaction_buttons_clicked_widget_title'])){ 1278 update_option('reaction_buttons_clicked_widget_title', esc_attr($_POST['reaction_buttons_clicked_widget_title'])); 1279 } 1280 1281 if (isset($_POST['reaction_buttons_clicked_widget_count'])){ 1282 $count = $_POST['reaction_buttons_clicked_widget_count']; 1283 if (is_numeric($count) && 0 < intval($count)) { 1284 update_option('reaction_buttons_clicked_widget_count', esc_attr($count)); 1285 } 1286 else { 1287 reaction_buttons_message(__("Please input a positiv number!", 'reaction_buttons')); 1288 } 1289 } 1290 1291 if (isset($_POST['reaction_buttons_clicked_widget_excerpt'])){ 1292 $excerpt = $_POST['reaction_buttons_clicked_widget_excerpt']; 1293 if (is_numeric($excerpt)) { 1294 update_option('reaction_buttons_clicked_widget_excerpt', esc_attr($excerpt)); 1295 } 1296 else { 1297 update_option('reaction_buttons_clicked_widget_excerpt', 0); 1298 } 1299 } 1300 if (isset($_POST['reaction_buttons_clicked_widget_thumb']) && $_POST['reaction_buttons_clicked_widget_thumb']){ 1301 update_option('reaction_buttons_clicked_widget_thumb',true); 1302 } 1303 else{ 1304 update_option('reaction_buttons_clicked_widget_thumb',false); 1305 } 1306 } 1307 1308 // show the current settings and the dialog 1272 1309 echo "<p>" . __("This widget shows the posts with the most clicks over all buttons.", 'reaction_buttons') . "</p>"; 1273 1274 // show the current settings and the dialog1275 1310 ?> 1276 1311 <p><label><?php _e("Title:", 'reaction_buttons') ?><br /> … … 1284 1319 1285 1320 <?php 1286 // validate the input and update the settings1287 if (isset($_POST['reaction_buttons_clicked_widget_title'])){1288 update_option('reaction_buttons_clicked_widget_title', esc_attr($_POST['reaction_buttons_clicked_widget_title']));1289 }1290 1291 if (isset($_POST['reaction_buttons_clicked_widget_count'])){1292 $count = $_POST['reaction_buttons_clicked_widget_count'];1293 if (is_numeric($count) && 0 < intval($count)) {1294 update_option('reaction_buttons_clicked_widget_count', esc_attr($count));1295 }1296 else {1297 reaction_buttons_message(__("Please input a positiv number!", 'reaction_buttons'));1298 }1299 }1300 1301 if (isset($_POST['reaction_buttons_clicked_widget_excerpt'])){1302 $excerpt = $_POST['reaction_buttons_clicked_widget_excerpt'];1303 if (is_numeric($excerpt)) {1304 update_option('reaction_buttons_clicked_widget_excerpt', esc_attr($excerpt));1305 }1306 else {1307 update_option('reaction_buttons_clicked_widget_excerpt', 0);1308 }1309 }1310 if (isset($_POST['reaction_buttons_clicked_widget_thumb']) && $_POST['reaction_buttons_clicked_widget_thumb']){1311 update_option('reaction_buttons_clicked_widget_thumb',true);1312 }1313 else{1314 update_option('reaction_buttons_clicked_widget_thumb',false);1315 }1316 1317 1321 } 1318 1322 -
reaction-buttons/tags/1.8.1/readme.txt
r913716 r917767 3 3 Requires at least: 3.3 4 4 Tested up to: 3.9.1 5 Stable tag: 1.8. 05 Stable tag: 1.8.1 6 6 License: GPLv2 or later 7 7 Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=MLX3Z7ZD5AJ4Q … … 58 58 59 59 == Changelog == 60 = 1.8.1 = 61 * fixed an error in the new widget controls 62 60 63 = 1.8 = 61 64 * added option for post thumbs to the widgets -
reaction-buttons/trunk/reaction_buttons.php
r913734 r917767 4 4 Plugin URI: http://blog.jl42.de/reaction-buttons/ 5 5 Description: Adds Buttons for very simple and fast feedback to your post. Inspired by Blogger. 6 Version: 1.8. 06 Version: 1.8.1 7 7 Author: Jakob Lenfers 8 8 Author URI: http://blog.jl42.de … … 1187 1187 */ 1188 1188 function reaction_buttons_widget_control(){ 1189 // save the settings if submitted 1190 if (isset($_REQUEST['savewidgets']) && $_REQUEST['savewidgets']) { 1191 // validate the input and update the settings 1192 if (isset($_POST['reaction_buttons_widget_title'])){ 1193 update_option('reaction_buttons_widget_title', esc_attr($_POST['reaction_buttons_widget_title'])); 1194 } 1195 1196 if (isset($_POST['reaction_buttons_widget_count'])){ 1197 $count = $_POST['reaction_buttons_widget_count']; 1198 if (is_numeric($count) && 0 < intval($count)) { 1199 update_option('reaction_buttons_widget_count', esc_attr($count)); 1200 } 1201 else { 1202 reaction_buttons_message(__("Please input a positiv number!", 'reaction_buttons')); 1203 } 1204 } 1205 1206 if (isset($_POST['reaction_buttons_widget_excerpt'])){ 1207 $excerpt = $_POST['reaction_buttons_widget_excerpt']; 1208 if (is_numeric($excerpt)) { 1209 update_option('reaction_buttons_widget_excerpt', esc_attr($excerpt)); 1210 } 1211 else { 1212 update_option('reaction_buttons_widget_excerpt', 0); 1213 } 1214 } 1215 if (isset($_POST['reaction_buttons_widget_buttons'])){ 1216 update_option('reaction_buttons_widget_buttons', esc_attr($_POST['reaction_buttons_widget_buttons'])); 1217 } 1218 if (isset($_POST['reaction_buttons_widget_thumb']) && $_POST['reaction_buttons_widget_thumb']){ 1219 update_option('reaction_buttons_widget_thumb', true); 1220 } 1221 else{ 1222 update_option('reaction_buttons_widget_thumb', false); 1223 } 1224 } 1225 1226 // show the current settings and the dialog 1189 1227 echo "<p>" . __("This widget shows the posts with the most clicks for each button.", 'reaction_buttons') . "</p>"; 1190 1191 // show the current settings and the dialog1192 1228 ?> 1193 1229 <p><label><?php _e("Title:", 'reaction_buttons') ?><br /> … … 1201 1237 <p><label><?php _e("Show a possible post thumbnail? (Might need some manual adaptations in your CSS to look nice.)", 'reaction_buttons') ?><br /> 1202 1238 <input name="reaction_buttons_widget_thumb" type="checkbox" <?php checked(get_option('reaction_buttons_widget_thumb', false), true); ?> /></label></p> 1203 1204 <?php 1205 // validate the input and update the settings 1206 if (isset($_POST['reaction_buttons_widget_title'])){ 1207 update_option('reaction_buttons_widget_title', esc_attr($_POST['reaction_buttons_widget_title'])); 1208 } 1209 1210 if (isset($_POST['reaction_buttons_widget_count'])){ 1211 $count = $_POST['reaction_buttons_widget_count']; 1212 if (is_numeric($count) && 0 < intval($count)) { 1213 update_option('reaction_buttons_widget_count', esc_attr($count)); 1214 } 1215 else { 1216 reaction_buttons_message(__("Please input a positiv number!", 'reaction_buttons')); 1217 } 1218 } 1219 1220 if (isset($_POST['reaction_buttons_widget_excerpt'])){ 1221 $excerpt = $_POST['reaction_buttons_widget_excerpt']; 1222 if (is_numeric($excerpt)) { 1223 update_option('reaction_buttons_widget_excerpt', esc_attr($excerpt)); 1224 } 1225 else { 1226 update_option('reaction_buttons_widget_excerpt', 0); 1227 } 1228 } 1229 if (isset($_POST['reaction_buttons_widget_buttons'])){ 1230 update_option('reaction_buttons_widget_buttons', esc_attr($_POST['reaction_buttons_widget_buttons'])); 1231 } 1232 if (isset($_POST['reaction_buttons_widget_thumb']) && $_POST['reaction_buttons_widget_thumb']){ 1233 update_option('reaction_buttons_widget_thumb',true); 1234 } 1235 else{ 1236 update_option('reaction_buttons_widget_thumb',false); 1237 } 1239 <?php 1238 1240 } 1239 1241 … … 1270 1272 */ 1271 1273 function reaction_buttons_clicked_widget_control(){ 1274 // save the settings if submitted 1275 if (isset($_REQUEST['savewidgets']) && $_REQUEST['savewidgets']) { 1276 // validate the input and update the settings 1277 if (isset($_POST['reaction_buttons_clicked_widget_title'])){ 1278 update_option('reaction_buttons_clicked_widget_title', esc_attr($_POST['reaction_buttons_clicked_widget_title'])); 1279 } 1280 1281 if (isset($_POST['reaction_buttons_clicked_widget_count'])){ 1282 $count = $_POST['reaction_buttons_clicked_widget_count']; 1283 if (is_numeric($count) && 0 < intval($count)) { 1284 update_option('reaction_buttons_clicked_widget_count', esc_attr($count)); 1285 } 1286 else { 1287 reaction_buttons_message(__("Please input a positiv number!", 'reaction_buttons')); 1288 } 1289 } 1290 1291 if (isset($_POST['reaction_buttons_clicked_widget_excerpt'])){ 1292 $excerpt = $_POST['reaction_buttons_clicked_widget_excerpt']; 1293 if (is_numeric($excerpt)) { 1294 update_option('reaction_buttons_clicked_widget_excerpt', esc_attr($excerpt)); 1295 } 1296 else { 1297 update_option('reaction_buttons_clicked_widget_excerpt', 0); 1298 } 1299 } 1300 if (isset($_POST['reaction_buttons_clicked_widget_thumb']) && $_POST['reaction_buttons_clicked_widget_thumb']){ 1301 update_option('reaction_buttons_clicked_widget_thumb',true); 1302 } 1303 else{ 1304 update_option('reaction_buttons_clicked_widget_thumb',false); 1305 } 1306 } 1307 1308 // show the current settings and the dialog 1272 1309 echo "<p>" . __("This widget shows the posts with the most clicks over all buttons.", 'reaction_buttons') . "</p>"; 1273 1274 // show the current settings and the dialog1275 1310 ?> 1276 1311 <p><label><?php _e("Title:", 'reaction_buttons') ?><br /> … … 1284 1319 1285 1320 <?php 1286 // validate the input and update the settings1287 if (isset($_POST['reaction_buttons_clicked_widget_title'])){1288 update_option('reaction_buttons_clicked_widget_title', esc_attr($_POST['reaction_buttons_clicked_widget_title']));1289 }1290 1291 if (isset($_POST['reaction_buttons_clicked_widget_count'])){1292 $count = $_POST['reaction_buttons_clicked_widget_count'];1293 if (is_numeric($count) && 0 < intval($count)) {1294 update_option('reaction_buttons_clicked_widget_count', esc_attr($count));1295 }1296 else {1297 reaction_buttons_message(__("Please input a positiv number!", 'reaction_buttons'));1298 }1299 }1300 1301 if (isset($_POST['reaction_buttons_clicked_widget_excerpt'])){1302 $excerpt = $_POST['reaction_buttons_clicked_widget_excerpt'];1303 if (is_numeric($excerpt)) {1304 update_option('reaction_buttons_clicked_widget_excerpt', esc_attr($excerpt));1305 }1306 else {1307 update_option('reaction_buttons_clicked_widget_excerpt', 0);1308 }1309 }1310 if (isset($_POST['reaction_buttons_clicked_widget_thumb']) && $_POST['reaction_buttons_clicked_widget_thumb']){1311 update_option('reaction_buttons_clicked_widget_thumb',true);1312 }1313 else{1314 update_option('reaction_buttons_clicked_widget_thumb',false);1315 }1316 1317 1321 } 1318 1322 -
reaction-buttons/trunk/readme.txt
r913716 r917767 3 3 Requires at least: 3.3 4 4 Tested up to: 3.9.1 5 Stable tag: 1.8. 05 Stable tag: 1.8.1 6 6 License: GPLv2 or later 7 7 Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=MLX3Z7ZD5AJ4Q … … 58 58 59 59 == Changelog == 60 = 1.8.1 = 61 * fixed an error in the new widget controls 62 60 63 = 1.8 = 61 64 * added option for post thumbs to the widgets
Note: See TracChangeset
for help on using the changeset viewer.