Changeset 170892
- Timestamp:
- 11/06/2009 10:33:56 AM (16 years ago)
- Location:
- wp-timer/trunk
- Files:
-
- 2 edited
-
WP_timer.php (modified) (2 diffs)
-
readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
wp-timer/trunk/WP_timer.php
r170490 r170892 5 5 Description: A simple timer for wordpress, inspired by http://xkcd.com/363/ 6 6 Author: Dan Warden 7 Version: 1.0 07 Version: 1.01 8 8 Author URI: http://www.nonamelan.co.uk 9 9 */ … … 111 111 if ($interval['interval']=="60") 112 112 { 113 $time="minute s";113 $time="minute"; 114 114 } 115 115 elseif ($interval['interval']=="3600") 116 116 { 117 $time="hour s";117 $time="hour"; 118 118 } 119 119 elseif ($interval['interval']=="86400") 120 120 { 121 $time="day s";121 $time="day"; 122 122 } 123 123 124 ?><p>It has been <?php echo $floor; ?> <?php echo $time; ?> since someone last reset this sign.</p> 124 ?><p>It has been <?php echo $floor; ?> <?php echo $time; ?><?php if ($floor == '1') 125 { 126 echo ''; 127 } 128 else 129 { 130 echo 's'; 131 } 132 ?> since someone last reset this sign.</p> 125 133 <p><form method='post' action='<?php echo $_SERVER['PHP_SELF']?>'> 126 134 <input name='interval' type='hidden' value='<?php echo $interval['interval']; ?>'/> -
wp-timer/trunk/readme.txt
r170490 r170892 8 8 A simple timer for wordpress, inspired by XKCD 9 9 10 == = ChangeLog ===10 ==Description== 11 11 12 v0.01 12 This is a small counter widget that simply shows how long it has bee since the counter was last reset. anyone is able to reset the counter using the button in the widget. This is my first wordpress widget an was used mainly as a way to teach myself how to write wordpress plugins. 13 13 14 first version, able to show only options saved in the control panel. 14 ==ChangeLog== 15 15 16 V1.01 16 17 17 v0.02 18 Fixed small gammatical error in the widget, will now show 1 day/hour/minute instead of 1days/hours/minutes 18 19 19 rewrite to allow for easier modification. 20 v1.00 20 21 21 22 v0.03 23 24 now showing message to user advsing how many days since last reset 25 26 27 v0.04 28 29 admin is now able to chosse the interval (minutes/hours/days) displayed on the main page. 30 31 32 v0.05 33 34 created form to allow reset to funtion. 22 first stable release 35 23 36 24
Note: See TracChangeset
for help on using the changeset viewer.