Patch review
| From: | Ross Masters | Date: | Sun, 02 Nov 2008 16:34:05 +0000 |
| Subject: | Patch review | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969379596@lists.php.net to get a copy of this message | ||
Hi all,
I've been doing some work on the datetime extension, and while I'm ready to commit I'm a little unsure about somethings (mainly PEAR CS). If someone could verify the following questions that would be great.
Firstly throughout the DateTime methods we can use procedural or object-oriented style. MySQLi is similar and has &mysqli.link.description; for the link parameter which is used in the procedural style only. Should I add something similar for these DateTime methods (AFAICT I need to add to /en/language-snippets.ent)?
Secondly, for PEAR CS I couldn't find anything regarding functions concetenated into a string. Which out of these is closest matched to PEAR?
echo "Day 10 of week 2 of 2008 is the " . $datetime->format('jS') . " of " . $datetime->format('F') . ".\n";
echo "Day 10 of week 2 of 2008 is the {$datetime->format('jS')} of {$datetime->format('F')}.\n";
Also, which of these is most acceptable?
echo $datetime->getTimezone()->getName() . "\n";
$tz = $datetime->getTimezone();
echo $tz->getName() . "\n";
Thanks,
Ross