腾讯云
开发者社区
文档
建议反馈
控制台
登录/注册
首页
学习
活动
专区
圈层
工具
MCP广场
文章/答案/技术大牛
搜索
搜索
关闭
发布
文章
问答
(9999+)
视频
沙龙
3
回答
在参数中连接字符串(php)
、
、
、
具体地说,我想要做的是:其中"
get_post_meta
“是用于获取附加到博客帖子的自定义数据的wordpress函数。
浏览 0
提问于2012-12-12
得票数 4
回答已采纳
3
回答
Wordpress "
get_post_meta
“-我不能回应它
我不能在我的html选择字段中回显
get_post_meta
。 get_the_id和get_the_title运行得很好。
为什么
"
get_post_meta
“
不起作用
?php echo
get_post_meta
( get_the_ID(), 'venue_ort', true ); ?><?> </select> 有什么建议可以让我回想
get_post_meta
吗? 谢
浏览 4
提问于2019-09-09
得票数 0
2
回答
如何从wordpress中的媒体库中获取图片元数据(如alt文本、标题和描述)
、
、
、
、
我正在尝试获取与特征图像相关联的元数据,但是
get_post_meta
始终返回为空。$image_alt_text =
get_post_meta
($image_id, '_wp_attachment_image_alt', true); $image_caption =<e
浏览 3
提问于2021-10-28
得票数 3
回答已采纳
1
回答
按多个条件查询Wordpress自定义贴子
、
我想查询多个条件: if(
get_post_meta
(get_the_ID(), 'nt_status', true) == "for-sale" &&
get_post_meta
($post->ID,= "udział" &&
get_post_meta
(get_the_ID(), 'nt_plot_size', true) <= "85" &&
get_post_meta
浏览 0
提问于2015-10-17
得票数 1
2
回答
在javascript "if“中错误使用php?
、
、
、
不起作用
的是检查是否存在更小的版本。如果它不存在,脚本应该返回到更大的版本,只需使用该图像。我得到了一个背景图像,但它只是一个大的(wordpress字段名"BG_value“)。php if(file_exists(bloginfo('template_url').
get_post_meta
php $bgimg =
get_post_meta
($post->ID, 'BG_value-medium
浏览 2
提问于2012-01-02
得票数 3
回答已采纳
1
回答
删除美元标志与自定义字段“价格”之间的空白
、
、
php if(
get_post_meta
($post->ID, 'price', true) ) { ?><?php } ?> <?php echo
get_post_meta
( get_the_ID(), 'price', true); ?>
浏览 1
提问于2014-10-21
得票数 0
回答已采纳
2
回答
WooCommerce:在Yoast中将品牌和gtin添加到产品模式标记
、
、
、
、
我想在WooCommerce中将品牌和gtin添加到我的产品标记中。目前,Yoast SEO插件已经添加了很多标记。但它只能选择添加具有产品属性的品牌。在我的例子中,品牌是基于自定义字段的。另外,gtin在不同的字段中,不能与Yoast一起使用。add_filter( 'wpseo_schema_webpage','example_change_webpage‘); * Changes @type of Webpage Schema data. * @param array $data
浏览 108
提问于2021-05-27
得票数 0
回答已采纳
1
回答
为什么
我在Wordpress中的功能
不起作用
?
为什么
不在wordpress中完成我的功能呢?我的代码$price_add =
get_post_meta
($id, 'price', true); } echo "None";} 我尝试使用if (isset($price_add)),但
不起作用
。
浏览 3
提问于2014-03-02
得票数 0
回答已采纳
1
回答
如何在Wordpress中隐藏空的自定义字段?
、
php echo
get_post_meta
($post->ID, 'Price', true); ?></p> <div class="m2"></div> <div class="year
浏览 3
提问于2020-04-20
得票数 0
1
回答
如果自定义字段为空,请帮助wordpress隐藏输入
、
$post->post_parent &&
get_post_meta
($post->ID, 'm_slider', true) == 'true') {?php echo
get_post_meta
($post->ID, 'main_folder', true); ?>/1.jpg'> <img src='<?php echo
get_post_meta
($post->ID, '
浏览 1
提问于2011-04-12
得票数 0
1
回答
如何在WooCommerce中检查哪一种优惠券适用于哪种产品?
、
、
、
、
既然我们可以在一个订单中对每个产品应用不同的优惠券,那么有什么方法可以知道哪种优惠券适用于哪种产品呢?我使用过$order->get_used_coupons()函数,但它只返回使用过的优惠券代码。
浏览 2
提问于2016-06-11
得票数 3
2
回答
Google映射短代码
、
为什么
这个代码
不起作用
?echo do_shortcode('[pw_map address="global $wp_query; $postid = $wp_query->post->ID; echo
get_post_meta
浏览 6
提问于2013-10-01
得票数 1
回答已采纳
1
回答
如何在wordpress中添加摘录的额外链接
、
、
'</a> | <a class="read-more-link" href="'.
get_post_meta
($post->ID, 'Audio File',true); .
浏览 0
提问于2010-09-14
得票数 1
回答已采纳
4
回答
创建变量的Php循环
、
、
我需要创建如下所需的变量列表:$meta_2_loft =
get_post_meta
( get_the_ID(), 'meta-2-loft', true );$meta_2_bounce =
get_
浏览 7
提问于2015-10-14
得票数 0
回答已采纳
1
回答
从metabox下拉列表中获取id
、
、
我使用可重复使用的Metaboxes (旧的但仍然有效),我创建了一个metabox,允许用户从定制的post类型列表中选择一个帖子。现在,这是很好的工作,我可以看到所有的帖子在一个列表中,我选择一个和保存。episode_guestid: a:1:{i:0;s:2:"18";}尝试了“最简单的方法”,但没有成功(因此,我需要帮助解决如何显示该帖子中的me
浏览 0
提问于2019-02-07
得票数 0
回答已采纳
1
回答
如何将PHP添加到自定义字段子句
、
、
因此,我使用标准:$key="mykey"; echo
get_post_meta
($post->ID, key/value, true);从自定义字段中调用一个值if (strlen($key="mykey"; echo
get_post_meta
($post->ID, key/value, true)) > 45)echo substr($key="mykey"; echo <
浏览 1
提问于2015-04-25
得票数 0
回答已采纳
3
回答
get post meta wordpress在插件中
不起作用
、
、
它适用于case updated_post,但不适用于new_post,我就是不明白
为什么
..timestamp'); $myId =
get_post_meta
$status .= $myId; $myId =
浏览 0
提问于2014-10-14
得票数 0
1
回答
当未设置元数据时,CPT上的自定义列没有显示正确的值。
、
、
function my_show_columns($name) {$hidden_page = get_the_title(
get_post_meta
($post->ID,'hidden_page', true)); $hidden_file = get_the_title(
get_post_meta
($post->ID, 'media_file', true));$item_type =
get_post_meta
($post->ID, '
浏览 0
提问于2021-05-10
得票数 0
1
回答
get_post_meta
在移动wordpress网站后
不起作用
、
、
、
WordPress网站移到另一个位置时,它不能工作(它在原始位置上工作):global $post; 但是如果我像下面的代码那样删除meta_value:global $post; $rt_gallery_images =
get_post_meta
1:{i:0;s:72:"/ssold/wp-content
浏览 1
提问于2013-04-30
得票数 0
回答已采纳
2
回答
PHP Wordpress简单的自定义字段重定向
、
、
function redirect () { if (is_page() || is_object($post)) { header('Location: ' .
get_post_meta
($post->ID, 'redirectredirect_b () { glo
浏览 2
提问于2017-11-04
得票数 1
回答已采纳
点击加载更多
热门
标签
更多标签
云服务器
ICP备案
对象存储
云点播
实时音视频
活动推荐
运营活动
广告
关闭
领券