#39355 [NEW]: README_UPDATE_5_2 incorrect DateTime API
| From: | akorthaus at web dot de | Date: | Fri, 03 Nov 2006 01:18:55 +0000 |
| Subject: | #39355 [NEW]: README_UPDATE_5_2 incorrect DateTime API | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969374313@lists.php.net to get a copy of this message | ||
From: akorthaus at web dot de
Operating system:
PHP version: Irrelevant
PHP Bug Type: Documentation problem
Bug description: README_UPDATE_5_2 incorrect DateTime API
Description:
------------
http://www.php.net/UPDATE_5_2.txt lists the DateTime
API, which is not
correct (looks like a procedural interface where the objects get passed as
1st parameter).
Patch against current PHP_5_2 branch:
Index: README.UPDATE_5_2
===================================================================
RCS file: /repository/php-src/Attic/README.UPDATE_5_2,v
retrieving revision 1.1.2.26
diff -u -r1.1.2.26 README.UPDATE_5_2
--- README.UPDATE_5_2 31 Oct 2006 17:24:51 -0000 1.1.2.26
+++ README.UPDATE_5_2 3 Nov 2006 01:13:39 -0000
@@ -541,34 +541,34 @@
Methods:
DateTime::__construct([string time[, DateTimeZone object]])
- Returns new DateTime object
- string DateTime::format(DateTime object, string format)
+ string DateTime::format(string format)
- Returns date formatted according to given format
- long DateTime::getOffset(DateTime object)
+ long DateTime::getOffset()
- Returns the DST offset
- DateTimeZone DateTime::getTimezone(DateTime object)
+ DateTimeZone DateTime::getTimezone()
- Return new DateTimeZone object relative to give DateTime
- void DateTime::modify(DateTime object, string modify)
+ void DateTime::modify(string modify)
- Alters the timestamp
array DateTime::parse(string date)
- Returns associative array with detailed info about given date
- void DateTime::setDate(DateTime object, long year, long month, long
day)
+ void DateTime::setDate(long year, long month, long day)
- Sets the date
- void DateTime::setISODate(DateTime object, long year, long week[,
long day])
+ void DateTime::setISODate(long year, long week[, long day])
- Sets the ISO date
- void DateTime::setTime(DateTime object, long hour, long minute[,
long second])
+ void DateTime::setTime(long hour, long minute[, long second])
- Sets the time
- void DateTime::setTimezone(DateTime object, DateTimeZone object)
+ void DateTime::setTimezone(DateTimeZone object)
- Sets the timezone for the DateTime object
DateTimeZone:
Methods:
DateTimeZone DateTimeZone::__construct(string timezone)
- Returns new DateTimeZone object
- string DateTimeZone::getName(DateTimeZone object)
+ string DateTimeZone::getName()
- Returns the name of the timezone
- long DateTimeZone::getOffset(DateTimeZone object, DateTime object)
+ long DateTimeZone::getOffset(DateTime object)
- Returns the timezone offset
- array DateTimeZone::getTransitions(DateTimeZone object)
+ array DateTimeZone::getTransitions()
- Returns numerically indexed array containing associative array
for all transitions for the timezone
RecursiveRegexIterator:
--
Edit bug report at http://bugs.php.net/?id=39355&edit=1
--
Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=39355&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=39355&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=39355&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=39355&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=39355&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=39355&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=39355&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=39355&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=39355&r=support
Expected behavior: http://bugs.php.net/fix.php?id=39355&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=39355&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=39355&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=39355&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=39355&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=39355&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=39355&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=39355&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=39355&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=39355&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=39355&r=mysqlcfg