Make WordPress Core


Ignore:
Timestamp:
10/18/2020 05:25:10 PM (4 years ago)
Author:
SergeyBiryukov
Message:

Coding Standards: Replace alias PHP functions with the canonical names.

Using the canonical function name for PHP functions is strongly recommended, as aliases may be deprecated or removed without (much) warning.

This replaces all uses of the following:

  • join() with implode()
  • sizeof() with count()
  • is_writeable() with is_writable()
  • doubleval() with a (float) cast

In part, this is a follow-up to #47746.

Props jrf.
See #50767.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/edit.php

    r49178 r49193  
    127127                array(
    128128                    'trashed' => $trashed,
    129                     'ids'     => join( ',', $post_ids ),
     129                    'ids'     => implode( ',', $post_ids ),
    130130                    'locked'  => $locked,
    131131                ),
     
    443443
    444444if ( $messages ) {
    445     echo '<div id="message" class="updated notice is-dismissible"><p>' . join( ' ', $messages ) . '</p></div>';
     445    echo '<div id="message" class="updated notice is-dismissible"><p>' . implode( ' ', $messages ) . '</p></div>';
    446446}
    447447unset( $messages );
Note: See TracChangeset for help on using the changeset viewer.