May 2017
Beginner to intermediate
536 pages
14h 25m
English
Now, we need to define all the columns available to create the custom list by modifying the existing get_columns function, as illustrated in the following code:
function get_columns() { $columns = array( 'cb' => '<input type="checkbox" />', 'topic_title' => __('Topic Title','wpwaf') ); return $columns; }
This is an in-built function that returns an array of columns. We don't need to change the details of the checkbox column as it's common to all the lists. Later, we have to define all the custom columns using the column name as the key and the display name as the value.
Read now
Unlock full access