Doc #53383 [NEW]: timezone_name_get() documentation says 0 parameters, actually takes 1.
| From: | tonyv at cohtitan dot com | Date: | Tue, 23 Nov 2010 03:31:51 +0000 |
| Subject: | Doc #53383 [NEW]: timezone_name_get() documentation says 0 parameters, actually takes 1. | ||
| Groups: | php.doc.bugs | ||
| Request: | Send a blank email to doc-bugs+get-5573@lists.php.net to get a copy of this message | ||
From:
Operating system:
PHP version: Irrelevant
Package: Documentation problem
Bug Type: Documentation Problem
Bug description:timezone_name_get() documentation says 0 parameters, actually takes 1.
Description:
------------
---
From manual page: http://www.php.net/datetimezone.getname#Parameters
---
The documentation for timezone_name_get() says that the function takes no
parameters. The object oriented version doesn't, but the procedural
version takes
exactly one DateTimeZone parameter.
Test script:
---------------
// Documentation of function indicates following prototype:
// string timezone_name_get ( void )
$tz_name = timezone_name_get();
// Generates warning:
// PHP Warning: timezone_name_get() expects exactly 1 parameter, 0 given
$tz_obj = new DateTimeZone("America/New_York");
$tz_name = timezone_name_get($tz_obj);
// $tz_name is correctly set to "America/New_York";
--
Edit bug report at http://bugs.php.net/bug.php?id=53383&edit=1
--
Try a snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=53383&r=trysnapshot52
Try a snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=53383&r=trysnapshot53
Try a snapshot (trunk): http://bugs.php.net/fix.php?id=53383&r=trysnapshottrunk
Fixed in SVN: http://bugs.php.net/fix.php?id=53383&r=fixed
Fixed in SVN and need be documented: http://bugs.php.net/fix.php?id=53383&r=needdocs
Fixed in release: http://bugs.php.net/fix.php?id=53383&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=53383&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=53383&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=53383&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=53383&r=support
Expected behavior: http://bugs.php.net/fix.php?id=53383&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=53383&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=53383&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=53383&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=53383&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=53383&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=53383&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=53383&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=53383&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=53383&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=53383&r=mysqlcfg