Folder returns folder on create($path . DS)
Reported by Kim Biesbjerg | March 29th, 2010 @ 05:23 AM | in 1.3.0
Hi,
Say you have this folder:
/app/files
and you want to create a subfolder
$path = 'app/files/products/';
$Folder->create($path) will create the folder but return false with an error:
[line 109] 2010-03-29 12:16:41 Error: Fatal Error (256): Unable to create "/opt/lampp/htdocs/simpleshop/www/files/products/35/"! in [...]
I discovered this as it used to work in 1.2 but no longer after I upgraded to 1.3.
Comments and changes to this ticket
-

Kim Biesbjerg March 29th, 2010 @ 05:24 AM
Clarification: It's the slash / DS at the end of the folder name that creates the problem.
-

Mark Story March 29th, 2010 @ 05:13 PM
- → Assigned user set to Mark Story
- → Milestone set to 1.3.0
-

CakePHP March 30th, 2010 @ 09:36 PM
- → State changed from new to resolved
(from [176c12e5fecbf9829121ec0661b781bf64f40711]) Adding tests for creating directories with trailing slashes. Closes #520 http://github.com/cakephp/cakephp1x/commit/176c12e5fecbf9829121ec06...
-

Mark Story March 30th, 2010 @ 09:37 PM
I wasn't able to reproduce the issue either in my app, or the test suite.
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
Source available from github
Repository is at http://github.com/cakephp/cakephp
Creating a bug report
When creating a bug report, please include as much relevant information as possible. Please include code to reproduce the issue. Or even better, make a unit test. Either change an existing test or add a new test to show that the expected behavior is not occuring.
People watching this ticket
Referenced by
-
#996 folder->create() returns unexpected result when using trailing slashes in path
@Mark: I just found out, that the ticket duplicates #520 ...
-
#996 folder->create() returns unexpected result when using trailing slashes in path
So after some perusal as far as I can see, you did not
un...
-
#520 Folder returns folder on create($path . DS)
(from [176c12e5fecbf9829121ec0661b781bf64f40711])
Adding ...
-
#2610 [TextHelper] Truncate url
(from [3a391529d27ccd2361821b9aa91014973923362c])
Merge p...