小编Jon*_*oss的帖子

简单PHP:从数组中提取PHP变量

我需要将此数组中的"shortUrl"元素转换为变量但不能!

object(stdClass)#1 (4) {
  ["errorCode"]=> int(0) 
  ["errorMessage"]=> string(0) "" 
  ["results"]=> object(stdClass)#2 (1) { 
    ["http://www.domain.com"]=> object(stdClass)#3 (5) { 
      ["userHash"]=> string(6) "oSEMki" 
      ["shortKeywordUrl"]=> string(0) "" 
      ["hash"]=> string(6) "oms2ZB"
      ["shortCNAMEUrl"]=> string(20) "http://bit.ly/LALALA"
      ["shortUrl"]=> string(20) "http://bit.ly/LALALA" 
    } 
  } 
  ["statusCode"]=> string(2) "OK" 
} 
Run Code Online (Sandbox Code Playgroud)

帮助赞赏.

php arrays variables

-1
推荐指数
1
解决办法
101
查看次数

标签 统计

arrays ×1

php ×1

variables ×1