Plugin Directory

Changeset 3240310


Ignore:
Timestamp:
02/13/2025 07:46:09 PM (14 months ago)
Author:
wpdever
Message:

fixed post placeholder timezone

Location:
wp-notification-bell/trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • wp-notification-bell/trunk/admin/admin.php

    r3209428 r3240310  
    361361    echo $recipients;
    362362    ?>"/>
    363     <p class="description">Comma-separated list of usernames to target users (optional)</p>
     363    <p class="description">Comma-separated list of usernames to target users, case-sensitive (optional)</p>
    364364   </td>
    365365    </tr>
  • wp-notification-bell/trunk/includes/helpers.php

    r3167969 r3240310  
    113113    $to_replace = array(
    114114        '{{date}}'       => get_the_date( 'l j M Y', $post_id ),
    115         '{{human_date}}' => sprintf( _x( '%1$s ago', '%2$s = human-readable time difference', 'wp-notification-bell' ), human_time_diff( get_post_time( 'U', false, $post_id ), current_time( 'timestamp' ) ) ),
    116         '{{time}}'       => get_the_date( 'H:i', $post_id ),
     115        '{{human_date}}' => sprintf( _x( '%1$s ago', '%2$s = human-readable time difference', 'wp-notification-bell' ), human_time_diff( get_post_time( 'U', true, $post_id ), current_time( 'timestamp', true ) ) ),
     116        '{{time}}'       => get_date_from_gmt( get_the_date( 'H:i', $post_id ), 'H:i' ),
    117117        '{{post_title}}' => ( $new_post ? get_the_title( $new_post ) : '' ),
    118118    );
  • wp-notification-bell/trunk/includes/menu_bell.php

    r3209428 r3240310  
    2222            if ( strlen( $items ) > $menu_position && $menu_position > 0 ) {
    2323                $items_array = array();
    24                 while ( false !== ($item_pos = strpos( $items, '<li', $menu_position )) ) {
     24                while ( !empty( $items ) && is_string( $items ) && false !== ($item_pos = strpos( $items, '<li', $menu_position )) ) {
     25                    if ( $item_pos === 0 ) {
     26                        break;
     27                        // Avoid infinite loop
     28                    }
    2529                    $items_array[] = substr( $items, 0, $item_pos );
    2630                    $items = substr( $items, $item_pos );
     
    4549            if ( strlen( $items ) > $menu_position && $menu_position > 0 ) {
    4650                $items_array = array();
    47                 while ( false !== ($item_pos = strpos( $items, '<li', $menu_position )) ) {
     51                while ( !empty( $items ) && is_string( $items ) && false !== ($item_pos = strpos( $items, '<li', $menu_position )) ) {
     52                    if ( $item_pos === 0 ) {
     53                        break;
     54                        // Avoid infinite loop
     55                    }
    4856                    $items_array[] = substr( $items, 0, $item_pos );
    4957                    $items = substr( $items, $item_pos );
  • wp-notification-bell/trunk/readme.txt

    r3229824 r3240310  
    44Requires at least: 4.0
    55Tested up to: 6.7
    6 Stable tag: 1.4.3
     6Stable tag: 1.4.4
    77Requires PHP: 5.6
    88License: GPLv2 or later
  • wp-notification-bell/trunk/wp-notification-bell.php

    r3229824 r3240310  
    55 * Plugin URI: https://wpsimpleplugins.wordpress.com/documentation/
    66 * Description: On-site notification system.
    7  * Version: 1.4.3
     7 * Version: 1.4.4
    88 * Author: SPlugins
    99 * Author URI: https://wpsimpleplugins.wordpress.com/documentation/
Note: See TracChangeset for help on using the changeset viewer.