CakePHP 2 fork that supports PHP 8
Find a file
aread22 64bb74a7e8 Potential Fix for LightHouse Ticket #3936
I believe I found a fix for this issue. I am here at #CakeFest2013 and during the #HourOfContribution I ran across this issue.

Currently in CakePHP 2.4 on Line 1522 - 1524 you can see the following code:

@@@ php
if ($label) {
	$optTitle = $this->Html->useTag('label', $tagName, '', $optTitle);
}
@@@

The $label variable here the is the $label array passed into the input method in Sethathi example above. The problem is that the $label array is completely ignored and instead a label is created using the HtmlHelper->useTag method.

I have what I believe is a fix for this issue but it hasn't been extensively tested. I tested against Sethathi example in the ticket and it produced the correct result.

The fix is simple. We detect if an array is passed in and then send it to the FormHelper label method instead of the HtmlHelper useTag method. The FormHelper label methods accepts an options array, so we pass in the $label array.

This will probably need to be fixed for checkbox also

"ask":https://cakephp.lighthouseapp.com/users/235987 helped me with this fix
2013-09-01 20:56:44 -04:00
app Merge branch 'master' into 2.4 2013-08-28 12:35:07 -04:00
lib/Cake Potential Fix for LightHouse Ticket #3936 2013-09-01 20:56:44 -04:00
plugins allowing install/cake-wide plugins 2009-08-02 15:01:15 -07:00
vendors we still want the vendors folder - creating empty file to ensure the 2011-03-12 20:11:33 +01:00
.editorconfig Add .editorconfig file. 2012-12-01 22:13:01 -08:00
.gitignore Updated .gitignore, synced app & skel 2013-02-08 15:54:36 +01:00
.htaccess Merging fixes into 1.x.x.x branched code: 2006-05-26 05:29:17 +00:00
.travis.yml Adds German locale for Travis. 2013-08-14 21:08:25 +02:00
build.properties Fix help & default properties file. 2013-02-03 13:05:55 -05:00
build.xml Update build scripts to fetch new changes. 2013-06-29 23:26:13 -04:00
CONTRIBUTING.md Changed http links to lighthouse, groups.google and github to https 2013-06-25 22:58:30 +02:00
index.php Improved the DocBlocks and other code cleanup 2013-05-31 00:11:19 +02:00
README.md Updates the Travis button to the master branch. 2013-08-31 13:55:09 +02:00

CakePHP

CakePHP

CakePHP is a rapid development framework for PHP which uses commonly known design patterns like Active Record, Association Data Mapping, Front Controller and MVC. Our primary goal is to provide a structured framework that enables PHP users at all levels to rapidly develop robust web applications, without any loss to flexibility.

CakePHP - The rapid development PHP framework

Cookbook - THE Cake user documentation; start learning here!

Plugins - A repository of extensions to the framework

The Bakery - Tips, tutorials and articles

API - A reference to Cake's classes

CakePHP TV - Screen casts from events and video tutorials

The Cake Software Foundation - promoting development related to CakePHP

Get Support!

Our Google Group - community mailing list and forum

#cakephp on irc.freenode.net - Come chat with us, we have cake.

Q & A - Ask questions here, all questions welcome

Lighthouse - Got issues? Please tell us!

Bake Status

Cake Power