custom_list_table edit/delete bulk actions

so… this is a brand new chapter for me, i’ve googled for a solution and found loads but nothing working for me unfortunately. function column_title($item){ $actions = array( ‘edit’ => sprintf(‘<a href=”https://wordpress.stackexchange.com/questions/188237/?page=%s&action=%s&ID=%s”>Edit</a>’,$_REQUEST[‘page’],’edit’,$item[‘ID’]), ‘delete’ => sprintf(‘<a href=”https://wordpress.stackexchange.com/questions/188237/?page=%s&action=%s&ID=%s”>Delete</a>’,$_REQUEST[‘page’],’delete’,$item[‘ID’]), ); return sprintf(‘%1$s %2$s’, $item[‘ID’], $this->row_actions($actions) ); } above i’ve added a delete and edit action, and i think … Read more

Undefined index: hook_suffix

I am getting “Undefined index: hook_suffix” error in WordPress while trying to execute the below. Here $class_name extends MyRegularClass and MyRegularClass extends WP_List_Table. Please help. $tab_name = substr($tab_name,strlen($wpdb->prefix)); if (class_exists($tab_name.’_class’)){ $class_name = $tab_name.’_class’; $obj = new $class_name(); } else { $obj = new MyRegularClass($tab_name); } Update: Here I am trying to display a table content … Read more

How do I limit the status options for bulk/quick edit to only Published and Draft?

For my custom post type, I only want to have “Published” and “Draft” as the available options in the bulk edit and quick edit screens, i.e. I tried hooking on to the filter quick_edit_dropdown_pages_args but it doesn’t seem to get fired. I inserted a wp_die() in my callback but the admin screen lists all posts … Read more

How to specify multiple search columns for wp list table search

I have working search for a created wp_list_table. But i like to know how I can search in more than one column. My current my working search setup in a Visitor class //search something $searchcol= array( ‘visitorCompany’, ‘visitorName’, ‘visitorEmail’ ); $search = !empty($_REQUEST[“s”]) ? mysql_real_escape_string($_REQUEST[“s”]) : ”; //$search = preg_replace( “^$\**(.*)\**$?#”, “*$1*”, $_REQUEST[“s”] ); if(!empty($_REQUEST[“s”])) … Read more

How to use custom post type APIs, but use a different db table

We currently have a plugin that creates a new WP table, but it recreates the wheel when it comes to managing/updating data. It would be a good candidate for custom post types, but we don’t want to pollute the wp_posts table. Use case: We’re creating a specific job board for a company that lists 100s … Read more