Home > Backend Development > PHP Tutorial > Beautify phpinfo() output content

Beautify phpinfo() output content

WBOY
Release: 2016-07-25 08:47:18
Original
1108 people have browsed it
通常
  1. date_default_timezone_set('Asia/Shanghai');
  2. ob_start(); phpinfo();
  3. $i = ob_get_contents();
  4. ob_end_clean();
  5. $html = str_replace(
  6. "module_Zend Optimizer", "module_Zend_Optimizer",
  7. preg_replace('%^.*(.*).*$%ms', '$1', $i)
  8. );
  9. $html = str_replace(' width="600"', '', $html);
  10. $str = <<
  11. {$html}
  12. STR;
  13. echo $str;
复制代码


Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template