Commit graph

959 commits

Author SHA1 Message Date
ADmad
d466e00644 Merge branch 'master' into 2.5
Conflicts:
	lib/Cake/Model/Datasource/DboSource.php
	lib/Cake/Test/Case/Model/Datasource/Database/MysqlTest.php
	lib/Cake/Utility/Folder.php
	lib/Cake/VERSION.txt
2014-05-04 14:35:36 +05:30
euromark
57cb7ea260 Correct documentation. 2014-05-02 13:48:39 +02:00
euromark
fecf321cce This is a hotfix for TextHelper which seems to have gone wrong in a merge. tail() is missing completly and the docs for truncate() are the ones for tail(). This fixes it. 2014-05-02 13:33:57 +02:00
Mathew Foscarini
ceab9f185f Removed incorrect usage of @deprecated phpDoc
@deprecated is flagging the function element as deprecated in all IDE's that support phpDOC tags. There is no phpDoc tag to deprecate a function parameter.
2014-04-30 09:55:27 -04:00
mark_story
e1057e3e6b Fix FormHelper::postLink() not working when SecurityComponent is enabled.
The action attribute value was not being included in the generated hash,
so postLink() forms never worked properly.

Fixes #3418
2014-04-29 11:23:52 -04:00
euromark
7a287a6942 More coding standard corrections. 2014-04-29 14:19:33 +02:00
mark_story
cf96e9f54f Merge branch 'master' into 2.5 2014-04-26 22:04:19 -04:00
Mark Story
5b46eb71ec Merge pull request #3397 from steinkel/fix-formhelper-with-model-mock
fixed FormHelper to allow create() on Mock Models without errors
2014-04-26 08:53:43 -04:00
Jorge González
5cf2ce723c fixed FormHelper to allow create() on Mock Models without errors 2014-04-26 10:33:58 +01:00
mark_story
de0062de77 Merge branch 'master' into 2.5 2014-04-25 22:10:02 -04:00
mark_story
f23d811ff5 Use the form action URL in generated form hashes.
By including the URL in generated hash for secured forms we prevent
a class of abuse where a user uses one secured form to post into a
controller action the form was not originally intended for. These cross
action requests could potentially violate developer's mental model of
how SecurityComponent works and produce unexpected/undesirable outcomes.

Thanks to Kurita Takashi for pointing this issue out, and suggesting
a fix.
2014-04-25 22:05:58 -04:00
ADmad
27699d1f12 Fix auto linking urls with subdomain with underscore.
Closes #3392
2014-04-25 22:28:34 +05:30
ADmad
6bdfdfd436 Optimize view paths caching for plugins.
Closes #2047
2014-04-20 02:02:07 +05:30
mark_story
debdc6bccc Merge branch '2.5' of github.com:cakephp/cakephp into 2.5 2014-04-07 21:46:11 -04:00
mark_story
ac66c2c03a Merge branch 'master' into 2.5 2014-04-07 21:45:57 -04:00
euromark
0ece694a75 microptimize options and default merge and other string key array merges 2014-04-08 01:25:14 +02:00
euromark
ad5e62515f Use Hash instead of Set class 2014-04-07 03:23:51 +02:00
euromark
6f53529520 Correct doc blocks 2014-04-06 22:27:51 +02:00
Jose Lorenzo Rodriguez
925db9e25e Revert "Revert "Merge pull request #3002 from moberemk/patch-2""
This reverts commit 0d80c92ffb.
2014-04-06 21:51:03 +02:00
Jose Lorenzo Rodriguez
0d80c92ffb Revert "Merge pull request #3002 from moberemk/patch-2"
This reverts commit 8e3d6cffb7, reversing
changes made to 92800889a6.
2014-04-06 21:48:59 +02:00
José Lorenzo Rodríguez
8e3d6cffb7 Merge pull request #3002 from moberemk/patch-2
Allow chaining in the addCrumb method
2014-04-06 21:09:10 +02:00
mark_story
57b8008dbe Merge branch 'master' into 2.5 2014-03-23 11:01:13 -04:00
Mark Story
90ca41d436 Merge pull request #2941 from lucasff/master
Allow the passing parameter escape of the getCrumbList method
2014-03-23 09:23:06 -04:00
mark_story
afc8587949 Merge branch 'master' into 2.5 2014-03-18 22:12:14 -04:00
mark_story
ee895a8bb1 Add form attribute to hidden inputs when present.
If inputs are placed outside of the form elements the form attribute
needs to be set on the hidden inputs. Without this attribute the empty
state does not submit correctly.

Fixes #3053
2014-03-18 22:11:57 -04:00
Lucas Freitas
4cd6ac2f15 Fix break of the CS on Travis 2014-03-13 00:24:16 -03:00
Mark Oberemk
3f7eff1843 Update HtmlHelper.php
Updated documentation to include the chained $this return
2014-03-12 08:59:12 -04:00
mark_story
c5b6dda82f Merge branch 'master' into 2.5 2014-03-11 21:02:27 -04:00
Mark Oberemk
8a8d2697d1 Allow chaining in the addCrumb method
For convenience I think it might be valuable to allow addCrumb (and possibly other similar functions) to return $this to permit chained calls such as this:

    $this->Html->addCrumb('Admin', '/admin')->addCrumb('Blogs', '/admin/users')->addCrumb('Add');

as opposed to the considerably more verbose version that needs to be used now:

    $this->Html->addCrumb('Admin', '/admin');
    $this->Html->addCrumb('Blogs', '/admin/users');
    $this->Html->addCrumb('Add');

I'm not sure if this violates some API conventions for helpers but it does seem rather more convenient to work with to me.
2014-03-11 10:37:47 -04:00
Kunal Panchal
a77a0f76a1 Documentation correction
TimeHelper::$niceFormat to CakeTime::$niceFormat
2014-03-10 14:05:03 +05:30
Lucas Freitas
b522b1e724 Entire UL element was being outputted directly (escaped), added to the unset list and fixed 2014-03-03 05:28:59 -03:00
Lucas Freitas
d4b91166bc Fixing stupidity and adding the PHPDoc param 2014-03-03 05:10:21 -03:00
Lucas Freitas
7096495943 Allow the passing parameter escape of the getCrumbList method and reflecting that into the outputted link too 2014-03-03 05:01:49 -03:00
ADmad
a0c399e374 Remove whitespace. 2014-02-26 10:40:53 +05:30
mark_story
0f584c0e8b Merge branch 'master' into 2.5 2014-02-24 21:19:17 -05:00
mark_story
0776b87214 Fix postLink() & postButton() with nested data.
Flatten deeply nested array data before generating hidden inputs.
This solves 'Array to string conversion' errors.

Closes #2894
2014-02-24 21:17:31 -05:00
mark_story
a80cbc205a Simplify conditionals.
Set default values to remove else cases.
2014-02-19 21:46:53 -05:00
jalbertocr
8b2e1ab9e5 Don't do assignments inside conditionals. 2014-02-19 22:41:33 -03:00
jalbertocr
cdeb51167b Fix types in docblocks. 2014-02-19 20:54:00 -03:00
jalbertocr
35f152b333 Make sure a datetime instance is valid to avoid fatal errors. 2014-02-19 20:50:30 -03:00
mark_story
3433f4a1f0 Clean up changes code standards and tests.
Refs #2582
2014-02-17 11:03:49 -05:00
Jonas
b32deed4aa changed FormHelper::secure() and FormHelper::end() to support attributes in the hidden CSRF-protection tags that are being generated for SecurityComponent to allow specification of additional html attributes like HTML5s "form" attribute. This allows separation of Form instantiation/controls and form data - for instance within html tables
improved tests for testing against additional attributes for Form::secure()

improved tests for testing against additional attributes for Form::end()

removed array cast, fixed test

fixed docblock format

format

Fixed a bug, this won't work as some forms are just empty
2014-02-17 10:54:02 -05:00
ADmad
9de3418079 Merge branch 'master' into 2.5
Conflicts:
	lib/Cake/Model/Permission.php
2014-02-11 18:17:59 +05:30
Eric Martins
2793dca671 Fix ApiGen errors 2014-02-07 18:29:54 -02:00
ADmad
d9489257d3 Don't return true from view classes' render() method.
It cause's Controller:render() to set the response body as `true`.

Refs #2780
2014-02-06 03:06:00 +05:30
mark_story
be8ebfc005 Merge branch 'master' into 2.5 2014-02-05 09:22:46 -05:00
AD7six
adc0bf3ded BC fix for checkbox ids
Revert to previous behavior for id generation of checkboxes, This commit
can be reverted for 2.5+ is desired

Fixes #2733
2014-02-03 17:57:26 +00:00
mark_story
ecf5aec1ae Add '@' to the list of characters removed from radio/checkbox ID.
This character can easily show up in email addresses and can cause
invalid HTML.

Refs #2733
2014-02-02 21:20:31 -05:00
mark_story
605351d0c9 Allow empty values in checkboxes.
Allow the checkbox value attribute to be empty. This is required to make
checkboxes with a value of 0.

Fixes #2717
2014-01-30 21:12:06 -05:00
Walter Nasich
a7f50e0ce7 Using sprintf to convert number into non-scientific notation 2014-01-30 19:07:23 -03:00