The DateTime object is “the next big thing”?

We’ve (the folks from Phorum) been talking in the last days about using the new DateTime object in PHP for Phorum as it has a nice way to use timezones including their DST setting.
Up to now we have just a setting where the user select if DST is current active or not as there isn’t really an easy way for use to enable/disable DST automatically.
Using that object would allow us to let the user select its timezone (with the timezone-select generated from that DateTime Object) and have DST automatically adjusted or better, we would not have to care about DST once a timezone is selected as its done automatically.

But unfortunately there is no localization of the date/time formats names in that new object.
Derick tells that “It’s intentional for PHP 5.2, not for PHP 6.0.” which is not really satisfying in my opinion.
In Phorum we are using strftime which formats time and date by the locale settings which are done through our language-files too.
So we can’t really get this behaviour through the new DateTime stuff and therefore I can’t really agree with Brian that its the feature we want in Phorum and that would require PHP-5.2.
It would only work half-way, too bad. A good idea which wasn’t completely finished.


No comments yet

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: