8000 DateTimeToStringTransformer - Commit b20c5ca - Broken on some php versions · Issue #6351 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

DateTimeToStringTransformer - Commit b20c5ca - Broken on some php versions #6351

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ahundiak opened this issue Dec 14, 2012 · 0 comments
Closed

Comments

@ahundiak
Copy link
Contributor

The subject commit added (among other things):

if (false === strpos($this->parseFormat, '|')) {
    $this->parseFormat .= '|';
}

According to notes in the php manual, the trailing | does not work correctly on all php versions:

"It seems that a pipe ('|') option in formating string works only with PHP version 5.3.8 and newer. 
 We had an issue with it on versions 5.3.2, 5.3.3, 5.3.6. Yet it was fine with 5.3.8 and 5.3.10."

This fix broke my applications running on 5.3.3 and 5.3.5 applications. Commenting out the above line fixed the problem.

Since 5.5.3 is officially supported by S2 we might consider an adjustment somewhere.

fabpot added a commit that referenced this issue Dec 14, 2012
This PR was merged into the 2.1 branch.

Commits
-------

ad29df5 [Form] Fixed DateTimeToStringTransformer parsing on PHP < 5.3.8

Discussion
----------

[Form] Fixed DateTimeToStringTransformer parsing on PHP < 5.3.8

Bug fix: yes
Feature addition: no
Backwards compatibility break: no
Symfony2 tests pass: yes
Fixes the following tickets: #6351, see comments in b20c5ca
Todo: -
License of the code: MIT
Documentation PR: -
@fabpot fabpot closed this as completed Dec 14, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants
0