开发者

Pass a variable through a function parameter

开发者 https://www.devze.com 2023-03-04 19:01 出处:网络
I\'m trying to insert the output of \"get_custom_field_value\" into the id of the wp_table function开发者_Python百科.

I'm trying to insert the output of "get_custom_field_value" into the id of the wp_table function开发者_Python百科.

My syntax must be wrong, because this isn't working.

 $menu = get_custom_field_value('menu-id', true);
 wp_table_reloaded_print_table( "id=$menu&use_tablesorter=true&print_name=false" ); 


try

$menu = get_custom_field_value('menu-id', true);
wp_table_reloaded_print_table( "id=" . $menu . "&use_tablesorter=true&print_name=false"); 

if this doesn't work yet, try to

print_r($menu);

to see, what menu looks like.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号