Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
Fix FormHelper::postLink() not working when SecurityComponent is enab…
…led. The action attribute value was not being included in the generated hash, so postLink() forms never worked properly. Fixes #3418
- Loading branch information
Showing
2 changed files
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
e1057e3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated to 2.5 and get this error on more than one of my websites.. including a small app developed with the shell
CORE/lib/Cake/View/Helper/FormHelper.php Unsuported Operand
Line: 1802
e1057e3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes the signature for postLink() was modified slightly.
e1057e3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not change that line from
$options += array('inline' => true, 'block' => null);
to$options = (array)$options + array('inline' => true, 'block' => null);
and make it backwards compatible for easier upgrades?e1057e3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Hikkijp That is exactly what I did yesterday - see 8af76a3
e1057e3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@dereuromark Sorry for that! I don't know how to use git very well, I just got into the same error and wanted to help. Thank you for the answer and the patch.
e1057e3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No problem. Just note that it is always good to check the current master branch for recent fixes.
e1057e3
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not the commit that broke it @mirceaagr - This was: d647fe8
6 months ago and no one noticed until 2 days ago .. :)