Changeset 1280238
- Timestamp:
- 11/05/2015 10:48:43 AM (9 years ago)
- Location:
- crazy-bone
- Files:
-
- 2 edited
- 13 copied
Legend:
- Unmodified
- Added
- Removed
-
crazy-bone/tags/0.6.0/plugin.php
r1280198 r1280238 5 5 Description: Tracks user name, time of login, IP address and browser user agent. 6 6 Author: wokamoto 7 Version: 0. 5.67 Version: 0. 8 8 Author URI: http://dogmap.jp/ 9 9 Text Domain: user-login-log … … 504 504 505 505 private function nice_time($date) { 506 $dest = intval($date); 507 $sour = intval(func_num_args() == 1 ? strtotime($this->time()) : func_get_arg(1)); 508 $nicetime = ''; 509 $tt = $dest - $sour; 510 511 $minute = intval($tt / self::SEC_MINUITE); 512 if ($minute < -60) { 513 $nicetime .= date( get_option('date_format').' '.get_option('time_format'), $date ); 514 } elseif ($minute < -1) { 515 $nicetime .= sprintf(__('%s ago.', self::TEXT_DOMAIN), (!empty($nicetime) ? ' ' : '' ) . sprintf(__('%d minutes', self::TEXT_DOMAIN), abs($minute))); 516 } else if ($minute == -1) { 517 $nicetime .= sprintf(__('%s ago.', self::TEXT_DOMAIN), (!empty($nicetime) ? ' ' : '' ) . __('one minute', self::TEXT_DOMAIN)); 518 } 519 506 $nicetime = human_time_diff($date, current_time('timestamp')); 520 507 return empty($nicetime) ? __('Just now!', self::TEXT_DOMAIN) : $nicetime; 521 508 } … … 824 811 <td class="username column-username"><?php echo $user_login; ?></td> 825 812 <?php } ?> 826 <td class="date column-date"><?php echo $row->activity_date; ?></td>827 <td class="status column-status"><?php echo $row->activity_status; ?></td>828 <td class="ip column-ip"><?php echo trim(self::get_country_flag($row->activity_IP, '', true) . '<br>' . $row->activity_IP); ?></td>829 <td class="agent column-agent"><?php echo trim(self::get_browser_icon($row->activity_agent) . '<br>' . $ua); ?></td>830 <td class="errors column-errors"><?php echo $errors; ?></td>813 <td class="date column-date"><?php echo ; ?></td> 814 <td class="status column-status"><?php echo ; ?></td> 815 <td class="ip column-ip"><?php echo trim(self::get_country_flag($row->activity_IP, '', true) . '<br>' . ); ?></td> 816 <td class="agent column-agent"><?php echo trim(self::get_browser_icon($row->activity_agent) . '<br>' . ); ?></td> 817 <td class="errors column-errors"><?php echo ; ?></td> 831 818 <?php if ($user_id == 0) { ?> 832 <td class="password column-errors"><?php echo $password; ?></td>819 <td class="password column-errors"><?php echo ; ?></td> 833 820 <?php } ?> 834 821 </tr> … … 960 947 ?> 961 948 <tr id="log-<?php echo $row_num ?>"> 962 <td class="username column-username"><?php echo $user_login; ?></td>963 <td class="status column-status"><?php echo $row->activity_status; ?></td>964 <td class="errors column-errors"><?php echo $errors; ?></td>949 <td class="username column-username"><?php echo ; ?></td> 950 <td class="status column-status"><?php echo ; ?></td> 951 <td class="errors column-errors"><?php echo ; ?></td> 965 952 <?php if ($user_id == 0) { ?> 966 <td class="password column-errors"><?php echo $password; ?></td>967 <?php } ?> 968 <td class="count column-errors" style="text-align:right;"><?php echo $row->count; ?></td>953 <td class="password column-errors"><?php echo ; ?></td> 954 <?php } ?> 955 <td class="count column-errors" style="text-align:right;"><?php echo ; ?></td> 969 956 </tr> 970 957 <?php $row_num++; }?> -
crazy-bone/tags/0.6.0/readme.txt
r1280198 r1280238 5 5 Requires at least: 3.5 6 6 Tested up to: 4.3.1 7 Stable tag: 0. 5.67 Stable tag: 0. 8 8 9 9 Tracks user name, time of login, IP address and browser user agent. … … 34 34 35 35 == Changelog == 36 37 38 39 40 41 36 42 37 43 **0.5.6 - Dec. 5, 2016 -
crazy-bone/trunk/plugin.php
r1280198 r1280238 5 5 Description: Tracks user name, time of login, IP address and browser user agent. 6 6 Author: wokamoto 7 Version: 0. 5.67 Version: 0. 8 8 Author URI: http://dogmap.jp/ 9 9 Text Domain: user-login-log … … 504 504 505 505 private function nice_time($date) { 506 $dest = intval($date); 507 $sour = intval(func_num_args() == 1 ? strtotime($this->time()) : func_get_arg(1)); 508 $nicetime = ''; 509 $tt = $dest - $sour; 510 511 $minute = intval($tt / self::SEC_MINUITE); 512 if ($minute < -60) { 513 $nicetime .= date( get_option('date_format').' '.get_option('time_format'), $date ); 514 } elseif ($minute < -1) { 515 $nicetime .= sprintf(__('%s ago.', self::TEXT_DOMAIN), (!empty($nicetime) ? ' ' : '' ) . sprintf(__('%d minutes', self::TEXT_DOMAIN), abs($minute))); 516 } else if ($minute == -1) { 517 $nicetime .= sprintf(__('%s ago.', self::TEXT_DOMAIN), (!empty($nicetime) ? ' ' : '' ) . __('one minute', self::TEXT_DOMAIN)); 518 } 519 506 $nicetime = human_time_diff($date, current_time('timestamp')); 520 507 return empty($nicetime) ? __('Just now!', self::TEXT_DOMAIN) : $nicetime; 521 508 } … … 824 811 <td class="username column-username"><?php echo $user_login; ?></td> 825 812 <?php } ?> 826 <td class="date column-date"><?php echo $row->activity_date; ?></td>827 <td class="status column-status"><?php echo $row->activity_status; ?></td>828 <td class="ip column-ip"><?php echo trim(self::get_country_flag($row->activity_IP, '', true) . '<br>' . $row->activity_IP); ?></td>829 <td class="agent column-agent"><?php echo trim(self::get_browser_icon($row->activity_agent) . '<br>' . $ua); ?></td>830 <td class="errors column-errors"><?php echo $errors; ?></td>813 <td class="date column-date"><?php echo ; ?></td> 814 <td class="status column-status"><?php echo ; ?></td> 815 <td class="ip column-ip"><?php echo trim(self::get_country_flag($row->activity_IP, '', true) . '<br>' . ); ?></td> 816 <td class="agent column-agent"><?php echo trim(self::get_browser_icon($row->activity_agent) . '<br>' . ); ?></td> 817 <td class="errors column-errors"><?php echo ; ?></td> 831 818 <?php if ($user_id == 0) { ?> 832 <td class="password column-errors"><?php echo $password; ?></td>819 <td class="password column-errors"><?php echo ; ?></td> 833 820 <?php } ?> 834 821 </tr> … … 960 947 ?> 961 948 <tr id="log-<?php echo $row_num ?>"> 962 <td class="username column-username"><?php echo $user_login; ?></td>963 <td class="status column-status"><?php echo $row->activity_status; ?></td>964 <td class="errors column-errors"><?php echo $errors; ?></td>949 <td class="username column-username"><?php echo ; ?></td> 950 <td class="status column-status"><?php echo ; ?></td> 951 <td class="errors column-errors"><?php echo ; ?></td> 965 952 <?php if ($user_id == 0) { ?> 966 <td class="password column-errors"><?php echo $password; ?></td>967 <?php } ?> 968 <td class="count column-errors" style="text-align:right;"><?php echo $row->count; ?></td>953 <td class="password column-errors"><?php echo ; ?></td> 954 <?php } ?> 955 <td class="count column-errors" style="text-align:right;"><?php echo ; ?></td> 969 956 </tr> 970 957 <?php $row_num++; }?> -
crazy-bone/trunk/readme.txt
r1280198 r1280238 5 5 Requires at least: 3.5 6 6 Tested up to: 4.3.1 7 Stable tag: 0. 5.67 Stable tag: 0. 8 8 9 9 Tracks user name, time of login, IP address and browser user agent. … … 34 34 35 35 == Changelog == 36 37 38 39 40 41 36 42 37 43 **0.5.6 - Dec. 5, 2016
Note: See TracChangeset
for help on using the changeset viewer.