bug in html5 time method
html5 time method always fails in my projects (tests and app itself) and I cannot figure out why
<time datetime="Y-M-dTH:i+00:00">1978-12-29 20:20:22</time>
or
<time datetime="Y-M-dTH:i+00:00" format="Y-m-d">Y-m-d</time>
instead of what it should be.
maybe sth changed in the core time helper? seems like its the formatting. i am running unter 1.3.10 head
hah, silly me, I put the TimeHelper::format() arguments in the wrong order.
are the rests running through now? because I still have some issues
<time datetime="1978-12-29T20:20:22+01:00">1978-12-29 20:20:22</time>
but should be:
Array
(
[time] => Array
(
[class] => birthday
[datetime] => 20:20:22
)
[0] => Fri 29th of Dec '78 08:20pm
[1] => /time
)
I'm not good with tests so I haven't updated them. You're using my fork, right?
I guess I forgot to allow custom parameters to be passed? Can you show me the line of code you're using?
yes, i did.
welll, all time tests are failing. they all do not get formatted into human readable format :)
Can you paste the line of code you were using On Jul 16, 2011 6:59 PM, "dereuromark" < [email protected]> wrote:
are the rests running through now? because I still have some issues
but should be:
Array ( [time] => Array ( [class] => birthday [datetime] => 20:20:22 )
[0] => Fri 29th of Dec '78 08:20pm [1] => /time )
Reply to this email directly or view it on GitHub: https://github.com/ProLoser/BakingPlate/issues/9#issuecomment-1588770
echo $this->HtmlPlus->time($post['Post']['created'], array('format' => 'Y-M-D'))
Appears to work for me. I need to see how you're attempting to use the method so that I can perhaps improve it's syntax (or at least the documentation).
It's currently designed to use the TimeHelper to format a string.
i didnt change your files i simply use the plugin and execute the test case
its windows on php5.3. maybe there is something different with the formatting of the date function? 6 failed tests in the htmlplus helper test case
and i did check out the current head again today and how there are 10 failing tests. really strange..
is it possible that you mixed up the methods? maybe we should use strftime() instead of format()?
I haven't been updating the tests. I'm not really profficient at tests. I need to go back and learn how to do them. Heh, sorry.
On Sun, Jul 17, 2011 at 3:45 AM, dereuromark < [email protected]>wrote:
i didnt change your files i simply use the plugin and execute the test case
its windows on php5.3. maybe there is something different with the formatting of the date function? 6 failed tests in the htmlplus helper test case
and i did check out the current head again today and how there are 10 failing tests. really strange..
is it possible that you mixed up the methods? maybe we should use strftime() instead of format()?
Reply to this email directly or view it on GitHub: https://github.com/ProLoser/BakingPlate/issues/9#issuecomment-1589730
i also tried i18nformat() with your test cases. not working either. what a bugger
by the way: you might be interested to hear that i opened a ticket regarding the order of the params: http://cakephp.lighthouseapp.com/projects/42648-cakephp/tickets/1834-inconsistent-time-helper-params