Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/277.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php Wordpress Jetpack特色内容标签ID_Php_Wordpress_Jetpack - Fatal编程技术网

Php Wordpress Jetpack特色内容标签ID

Php Wordpress Jetpack特色内容标签ID,php,wordpress,jetpack,Php,Wordpress,Jetpack,我希望能够为Jetpack特色内容模块调用用户选择的标签ID,但我找不到保存该值的函数或对象 我基本上是在用以下参数从WP_查询中筛选特色帖子: $args = array( 'ignore_sticky_posts' => 1, 'posts_per_page' => $recent_posts_count, 'tag__not_in' => array( [HERE

我希望能够为Jetpack特色内容模块调用用户选择的标签ID,但我找不到保存该值的函数或对象

我基本上是在用以下参数从WP_查询中筛选特色帖子:

$args = array(
        'ignore_sticky_posts' => 1,                 
        'posts_per_page' => $recent_posts_count,
        'tag__not_in'   => array(
            [HERE IS WHERE I WANT PHP TO TELL ME THE TAG ID]
        ),
        'post_type' => array(               
            'post'                  
        )
    );  
检查这个

<?php

        global $post;
        $tags = get_tags($post->ID);
        $tagids = array();
        foreach($tags as $tag) $tagids[] = $tag->term_id;
    $args = array(
            'ignore_sticky_posts' => 1,                 
            'posts_per_page' => $recent_posts_count,
            'tag__not_in'   => $tagids,
            'post_type' => array(               
                'post'                  
            )
        );  
    ?>


谢谢

我知道这已经很晚了,但我在寻找同样的东西时找到了这篇文章,甚至在WordPress支持论坛上也找到了,但最终还是找到了:

$featured_options = get_option( 'featured-content' );
$featured_name = $featured_options[ 'tag-name' ];

该程序在何处访问Jetpack以查找特征标签ID?