Home >Backend Development >PHP Tutorial >Convert php array to object instance code_PHP tutorial

Convert php array to object instance code_PHP tutorial

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOriginal
2016-07-13 17:41:111038browse

PHP array is converted into object instance code. This program has been tested by Programming Home and it runs normally.

  1. $array = array(1 => php,
  2. 2 => java,
  3. ?>
  4. Run result:
  5. object(ArrayObject)#1 (1) { ["storage":"ArrayObject":private]=> array(3) { [1]=> string(3) "php" [2]=> string(4) "java" [3]=> string(3) "c " } }
  6. http://www.bkjia.com/PHPjc/486154.html
www.bkjia.com

true
http: //www.bkjia.com/PHPjc/486154.html

TechArticle

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn