User tests: Successful: Unsuccessful:
Tracker:
http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33687&start=0
http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33413&start=0
one more:
http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_id=8103&tracker_item_id=33692
Fix based on (german):
http://www.joomlaportal.de/joomla-3-x-installation/309865-sammelthread-joomla-3-3-0-released-2.html#post1534645
http://www.joomla-bugs.de/forum/index.php?topic=582.0
See #32032 in the Feature tracker, not broken anymore!
You may blame the J!Tracker Application for transmitting this comment.
Just try uploading anything to a folder.
You may blame the J!Tracker Application for transmitting this comment.
@wilsonge
There are different reports that uploading to a sub folder (e.g. images/sampledata/parks) upload the image to the /images folder.
So you can do the following:
1) login to the backend
2) access the media manager
3) navigate to a sub folder
4) try uploading a image
5) apply patch
6) test again
Thanks.
#test Confirm issue and resolution.
Folder is now created at the expected location, image is uploaded to current folder.
You may blame the J!Tracker Application for transmitting this comment.
For consistency would suggest '$this->input->post->get(' instead of '$this->input->get->get('
You may blame the J!Tracker Application for transmitting this comment.
For consistency would suggest '$this->input->post->get(' instead of '$this->input->get->get('
This depends if the folder is given in the URL (GET request) or is coming from the form data (POST) imho. The proposed code looks specifially in the URL while your suggestion would look in the form data.
Not my line of expertise. Find it strange, both fields (return-url and folder) are hidden fields, one is taken from post, the other from get. Makes me wonder, especially when something doesn't work as expected.
Test. The PR fixes the problem!
@sovainfo has a valid point. There is a hidden folder
field in the form, but it's not populated with a value. That's the main reason why the current code fails.
The script gets two inputs, one from GET (with the correct value) and one from POST (with an empty value), and the POST one overrides the one from GET.
While this fix works, I would actually prefer it if the form field would properly updated with the correct value.
It takes the value from $this->state->folder
, see https://github.com/joomla/joomla-cms/blob/staging/administrator/components/com_media/views/media/tmpl/default.php#L64 and it looks like this state isn't properly updated when traversing directories.
There are also other places where this state is used, so I gess we may well have other bugs with that.
The patch for File uploads. However the issue is also applicable for creating subfolders. If you create a subdirectory it is placed in the root (I tested that) and not in the directory where you created the sub. I guess Thomas this is one of those places where it indeed bugs as well with that
Weird, as reported, creating subfolders worked in my environment.
creating sub folders works only fore me when I upload a file. Like i described in the tracker item: http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33413
Exactly the behavior I also experienced that's why I posted. I think
that is because of the double "get" as described by Thomas
On 5/6/2014 4:22 PM, n9iels wrote:
creating sub folders works only fore me when I upload a file. Like i
described in the tracker item:
http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33413—
Reply to this email directly or view it on GitHub
#3551 (comment).
Here's another a fix or Re:Later for "If you create a subdirectory it is placed in the root (I tested that) and not in the directory where you created the sub".
We've tested all three fixes with J!3.2.4 and 3.3.0
Why ...get->get...? Because "folder=..." is added to the action URL by JavaScript, that's transmitted by GET..
Why ...get->get...? Because "folder=..." is added to the action URL by JavaScript, that's transmitted by GET..
The thing is that the current JInput->get('folder')
would actually work fine if the empty hidden folder
field wasn't present in the form. We don't really need JInput->get->get('folder')
.
There are two ways to properly fix this:
folder
field.folder
field and remove the folder parameter from the URL (as it's not needed anymore). Was able to create subfolders multiple levels deep. Also in other folders. Changed the statement into post and back to original. Made no difference, it kept working!
So, I recreated a j33demo environment. Verified existance of the bug, it exists. Added ->get, could upload image. Could also create subfolder, but only after uploading image.
Didn't test suggestion of ilovo brcause I don't like the folder in the url. Would like to have it in the post!
Thomas,
If what you write is the best option than please implement so we can test this and get over it? I also do not like illovo's suggestion because of the url and I have same experience in testing at present as Sovainfo has so let's follow Thomas suggestion ?
Title |
|
||||||
Description | <p>Tracker:<br><a href="http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33687&start=0">http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33687&start=0</a><br><a href="http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33413&start=0">http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33413&start=0</a></p> <p>Fix based on (german):<br><a href="http://www.joomlaportal.de/joomla-3-x-installation/309865-sammelthread-joomla-3-3-0-released-2.html#post1534645">http://www.joomlaportal.de/joomla-3-x-installation/309865-sammelthread-joomla-3-3-0-released-2.html#post1534645</a><br><a href="http://www.joomla-bugs.de/forum/index.php?topic=582.0">http://www.joomla-bugs.de/forum/index.php?topic=582.0</a></p> | ⇒ | <p>Tracker:<br><a href="http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33687&start=0">http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33687&start=0</a><br><a href="http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33413&start=0">http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_item_id=33413&start=0</a><br> one more:<br><a href="http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_id=8103&tracker_item_id=33692">http://joomlacode.org/gf/project/joomla/tracker/?action=TrackerItemEdit&tracker_id=8103&tracker_item_id=33692</a></p> <p>Fix based on (german):<br><a href="http://www.joomlaportal.de/joomla-3-x-installation/309865-sammelthread-joomla-3-3-0-released-2.html#post1534645">http://www.joomlaportal.de/joomla-3-x-installation/309865-sammelthread-joomla-3-3-0-released-2.html#post1534645</a><br><a href="http://www.joomla-bugs.de/forum/index.php?topic=582.0">http://www.joomla-bugs.de/forum/index.php?topic=582.0</a></p> | ||||
Status | New | ⇒ | Closed | ||||
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2014-05-08 15:54:07 | ||||
Labels |
Added:
?
?
|
Could anyone explain to me what a patch is. I'm struggling with the same issue as you all do. The Media Manager. The final step is: apply patch. But I don't know how to do that...
Thanks for messaging!
And this sounds already difficult for me...
This issue is resolved. Updating to the lastest version of Joomla should fix this.
If not, please open a new issue so it can get fixed.
I have this version: Joomla! 3.4.1
Two weeks ago I was able to make a sub-folder, but now I can't anymore...
Then you should update to 3.4.3 - which got released yesterday!
OK, I see. Solved. Thaks a lot!
As I can't access the trackers (usual broken stuff) nor read german (should have paid more attention at school) how do I replicate this?