WordPress.org

Make WordPress Core

Opened 3 years ago

Last modified 3 years ago

#16842 closed defect (bug)

class-wp-list-table.php on line 140 — at Initial Version

Reported by: idbill Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.1
Component: Comments Keywords: reporter-feedback
Focuses: Cc:

Description

3.1 recent install...
log in as admin...
then go to 'comments'...
the following error appears:

/home2/writinl4/public_html/angeltrivia/wp-admin/includes/class-wp-list-table.php on line 140

the if statement referenced is:

if ( !$argstotal_pages? && $argsper_page? > 0 ) {

$argstotal_pages? = ceil( $argstotal_items? / $argsper_page? );

}

I checked the variables, and they were set as so:
$argstotal_pages? = 0
$argsper_page? = 20
$argstotal_items? = ( array of items )
Uh.. can't divide an array!

So I changed the if calculation to:

if ( !$argstotal_pages? && $argsper_page? > 0 ) {

$argstotal_pages? = ceil( count( $argstotal_items? ) / $argsper_page? );

}

and it works...

Change History (0)

Note: See TracTickets for help on using tickets.