PageRenderTime 40ms CodeModel.GetById 16ms RepoModel.GetById 0ms app.codeStats 0ms

/hphp/test/zend/bad/ext-pdo_mysql/pdo_mysql_phpinfo.php

https://bitbucket.org/gnanakeethan/hiphop-php
PHP | 19 lines | 14 code | 4 blank | 1 comment | 1 complexity | e02446011416326dc19f87d8e306194c MD5 | raw file
Possible License(s): MPL-2.0-no-copyleft-exception
  1. <?php
  2. require_once(dirname(__FILE__) . DIRECTORY_SEPARATOR . 'mysql_pdo_test.inc');
  3. $db = MySQLPDOTest::factory();
  4. ob_start();
  5. phpinfo();
  6. $tmp = ob_get_contents();
  7. ob_end_clean();
  8. /* PDO Driver for MySQL, client library version => 6.0.3-alpha */
  9. $expected = sprintf('Client API version => %s',
  10. $db->getAttribute(PDO::ATTR_CLIENT_VERSION));
  11. if (false === stristr($tmp, $expected)) {
  12. printf("[001] Cannot find MySQL PDO driver line in phpinfo() output\n");
  13. }
  14. print "done!";
  15. ?>