/hphp/test/slow/ext_mysql/mysql_fetch_assoc.php
PHP | 13 lines | 11 code | 2 blank | 0 comment | 0 complexity | b5d89f3a55b4ba659010acbfdc0fca60 MD5 | raw file
Possible License(s): LGPL-2.1, BSD-2-Clause, BSD-3-Clause, MPL-2.0-no-copyleft-exception, MIT, LGPL-2.0, Apache-2.0
- <?hh
- require_once('connect.inc');
- <<__EntryPoint>> function main(): void {
- $conn = mysql_connect($host, $user, $passwd);
- var_dump(create_test_table('fetch_assoc'));
- var_dump(mysql_query(
- "insert into test_fetch_assoc (name) values ('test'),('test2')"));
- $res = mysql_query('select * from test_fetch_assoc');
- $row = mysql_fetch_assoc($res);
- print_r($row);
- }