php 如何把对象转换成数组对象,php – 如何将对象转换为数组以获取数据?

WordPress是一款免费且开源的网站构建平台,适用于创建各种类型的网站和博客。超过2500万人选择WordPress作为他们的在线家园。核心软件由志愿者社区维护,同时提供丰富的插件和主题,让您的网站几乎可以实现任何想象中的设计和功能。无论您是新手还是高级用户,WordPress都能满足您的需求。
摘要由CSDN通过智能技术生成

我的阵列是这样的

Array ( [0] => stdClass Object ( [ID] => 578 [post_author] => 1 [post_date] => 2011-01-18 07:23:17 [post_date_gmt] => 2011-01-18 07:23:17 [post_content] => Home WordPress is web software you can use to create a beautiful website or blog. We like to say that WordPress is both free and priceless at the same time. The core software is built by hundreds of community volunteers, and when you’re ready for more there are thousands of plugins and themes available to transform your site into almost anything you can imagine. Over 25 million people have chosen WordPress to power the place on the web they call “home” — we’d love you to join the family [post_title] => second post [post_excerpt] => [post_status] => publish [comment_status] => open

我这样写的时候

$myposts = get_posts( $args );

$arrDt = (array) $myposts;

print_r($arrDt);

但我的问题是如何获取该对象数组中的值.

请帮忙.

日Thnx

的print_r($arrDt);

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值