类别:媒体报道 发布时间:2021-03-21 浏览人次:
在主题风格网站根目录下的 functions.php 文档 ?下加上下列编码:
if ( !function_exists('fb_AddThumbColumn') function_exists('add_theme_support') ) { // for post and page add_theme_support('post-thumbnails', array( 'post', 'page' ) ); function fb_AddThumbColumn($cols) { $cols['thumbnail'] = __('Thumbnail'); return $cols; function fb_AddThumbValue($column_name, $post_id) { $width = (int) 35; $height = (int) 35; if ( 'thumbnail' == $column_name ) { // thumbnail of WP 2.9 $thumbnail_id = get_post_meta( $post_id, '_thumbnail_id', true ); // image from gallery $attachments = get_children( array('post_parent' = $post_id, 'post_type' = 'attachment', 'post_mime_type' = 'image') ); if ($thumbnail_id) $thumb = wp_get_attachment_image( $thumbnail_id, array($width, $height), true ); elseif ($attachments) { foreach ( $attachments as $attachment_id = $attachment ) { $thumb = wp_get_attachment_image( $attachment_id, array($width, $height), true ); if ( isset($thumb) $thumb ) { echo $thumb; } else { echo __('None'); // for posts add_filter( 'manage_posts_columns', 'fb_AddThumbColumn' ); add_action( 'manage_posts_custom_column', 'fb_AddThumbValue', 10, 2 ); // for pages add_filter( 'manage_pages_columns', 'fb_AddThumbColumn' ); add_action( 'manage_pages_custom_column', 'fb_AddThumbValue', 10, 2 );
加上后储存就可以。
有关强烈推荐: 如何获得当今网页页面、系统日志连接?[wordpress开发设计实例教程] wordpress如何改动后台管理登陆详细地址来提升安全性性?[wordpress开发设计实例教程] WordPress Customize API 加上第一个自定选择项[wordpress开发设计实例教程] 获得blog信息内容wordpress涵数[wordpress开发设计实例教程] wordpress如何用编码打开站点维护保养[wordpress实例教程] wordpress忘掉登陆密码如何办?[wordpress实例教程] 侧面栏产品强烈推荐实用工具 wordpress区块链[wordpress清理实例教程] 网易游戏UU加快器版本号免费下载区块链_wordpress区块链[wordpress清理实例教程]在主题风格网站根目录下的 functions.php 文档 ?下加上下列编码:if ( !function_exists('fb_AddThumbColumn') function_exists('add_theme_support') ) {// for post and pageadd_theme_support('post-thumbnails', array( 'post', '...
2021-03-21迅雷资源v6.22.2清新版 + 不速度限制/忽视比较敏感/破译 迅雷资源v6.22.2清新版 + 不速度限制/忽视比较敏感/破译[安卓系统android]宅男看片神器,大量資源,超清顺畅,赶紧来免费下载归属...
2021-03-21提升营销推广 回到 您当今所属部位: 新闻资讯 协助管理中心 提升营销推广 文章正文 大家都知道进行公司要进行互联网营销推广,第一步便是创建一个公司网站,根据公司网...
2021-03-20伴随着宝塔面板控制面板被越来越越大人所应用,互联网上各种各样扫描仪手机软件都没有忽略它,除开扫描仪网站特点以外,也扫描仪控制面板特点。以便给控制面板加一层安全性锁...
2021-03-20徐州乐迪工坊生物化学高新科技比较有限企业是美容护肤肌肤护理、健康养生减肥、美容护肤肌肤护理、健康养生减肥等商品技术专业生产制造生产加工的企业,有着详细、科学研究的...
2021-03-20公司电子邮箱怎样关联Outlook时间:2014-02-13 | 访问:4207次 | 公司电子邮箱outlook设定方式,公司电子邮箱outlook关联方式,公司电子邮箱怎样设定outlook公司电子邮箱逐渐被普遍客户所应用...
2021-03-20