Edit report at https://bugs.php.net/bug.php?id=65336&edit=1
ID: 65336 Updated by: yohg...@php.net Reported by: maja dot privat at gmx dot at Summary: pg_escape_literal/identifier() silently returns boolean w/o connection -Status: Assigned +Status: Closed Type: Bug Package: PostgreSQL related Operating System: Windows 7 PHP Version: 5.4.17 Assigned To: yohgaki Block user comment: N Private report: N New Comment: Automatic comment on behalf of yohgaki Revision: http://git.php.net/?p=php-src.git;a=commit;h=1d7b6970f20a059c501e68927c9fb874bdb226bc Log: Fixed bug #65336 Previous Comments: ------------------------------------------------------------------------ [2013-07-26 00:52:08] yohg...@php.net Should be a bug. ------------------------------------------------------------------------ [2013-07-25 16:20:05] maja dot privat at gmx dot at Description: ------------ This is the code-snipped: $limit = "5"; print_r( array(pg_escape_literal($limit) , gettype(pg_escape_literal($limit))) ); And it prints: [false,"boolean"] However, the documentation says, that "pg_escape_literal()" returns only strings. I'm not sure if it's a php-bug, or a documentation-error. Documentation-Page: http://www.php.net/manual/en/function.pg-escape-literal.php Test script: --------------- $limit = "5"; print_r( array(pg_escape_literal($limit) , gettype(pg_escape_literal($limit))) ); Expected result: ---------------- ["'5'","string"] Actual result: -------------- [false,"boolean"] ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=65336&edit=1