我已经知道了here 如何在wordpress admin中从posts表中删除行操作。现在,我想在pages表中执行同样的操作。我查过核心文件,但我就是不明白。任何人
下面是函数中使用的代码。php删除帖子中的行操作:
function remove_row_actions( $actions )
{
if( get_post_type() === \'post\' )
unset( $actions[\'edit\'] );
unset( $actions[\'view\'] );
unset( $actions[\'trash\'] );
unset( $actions[\'inline hide-if-no-js\'] );
return $actions;
}
add_filter( \'post_row_actions\', \'remove_row_actions\', 10, 1 );
提前感谢!