我看到在 http://test.com/wp-admin/edit.php 中添加了 ui-sortable-handle 类
<tr id="post-2442" class="iedit author-other level-0 post-2421 type-post status-publish format-standard hentry category-media-releases ui-sortable-handle">
</tr>
如何删除 ui-sortable-handle 类?
最佳答案
使用 jQuery 很容易:
$('#post-2442').removeClass('ui-sortable-handle');
编辑
全局
$('.ui-sortable-handle').each(function(){
$(this).removeClass('ui-sortable-handle');
});
编辑 2
在 wordpress 中,您的 body
中有特定的类,例如 page-id-1
。
if($('body').hasClass('page-id-1')) {
$('.ui-sortable-handle').each(function(){
$(this).removeClass('ui-sortable-handle');
});
}
关于jquery - ui-sortable-handle 类添加到 edit.php WordPress,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44715416/