Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.3
    • Fix Version/s: 2.3
    • Component/s: Filepicker
    • Labels:
      None
    • Environment:
      Win 7
    • Testing Instructions:
      Hide

      1. Log in as teacher/admin
      2. Create a page resource
      3. In the editor, click on the "Insert/edit image" icon
      4. Click "Find or upload an image..."
      5. Use the filepicker to upload an image
      6. Make sure the file is inserted only if it has proper extension (jpg, gif, png)
      7. Try to rename non-image file in your OS and add image extension (i.e. rename file.zip -> file.jpg), upload it using filepicker
      8. Make sure it is accepted (although not displayed)
      9. Try to rename image file into something different in your OS (i.e. rename file.jpg -> file.zip), upload it using filepicker
      10. Make sure it is not accepted

      11. Add a file into filemanager
      12. Rename it changing the extension and make sure that icon and file type (in table view mode) reflects the extension

      Show
      1. Log in as teacher/admin 2. Create a page resource 3. In the editor, click on the "Insert/edit image" icon 4. Click "Find or upload an image..." 5. Use the filepicker to upload an image 6. Make sure the file is inserted only if it has proper extension (jpg, gif, png) 7. Try to rename non-image file in your OS and add image extension (i.e. rename file.zip -> file.jpg), upload it using filepicker 8. Make sure it is accepted (although not displayed) 9. Try to rename image file into something different in your OS (i.e. rename file.jpg -> file.zip), upload it using filepicker 10. Make sure it is not accepted 11. Add a file into filemanager 12. Rename it changing the extension and make sure that icon and file type (in table view mode) reflects the extension
    • Affected Branches:
      MOODLE_23_STABLE
    • Fixed Branches:
      MOODLE_23_STABLE
    • Pull Master Branch:
      wip-MDL-33391-master

      Description

      local test site: Moodle 2.3dev (Build: 20120525) - Windows 7 64bits

      When I use the filepicker to upload an image or media file from my computer, in the filepicker window I keep getting the error message

      Image (JPEG) filetype cannot be accepted or Audio file (MP3) filetype cannot be accepted etc.

      Same error message is displayed in Chrome 19.0.1084.52 m; MSIE 9 and Firefox 12.0.

      See also http://moodle.org/mod/forum/discuss.php?d=203528

      Replication steps:

      1. Log in as teacher/admin
      2. Create a page resource
      3. In the editor, click on the "Insert/edit image" icon
      4. Click "Find or upload an image..."
      5. Use the filepicker to upload a media file (MP3, JPG, GIF, PNG)

      The filepicker does not accept the file under Windows 7 under various browsers. It appears to work on Linux.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

              Hide
              mina Nicolas Martignoni added a comment -

              Sorry Joseph,

              Unable to reproduce on my own testing server (Moodle 2.3dev, builds 20120522 and 20120525), on Debian GNU/Linux 6.0.5 (squeeze). Maybe related to Moodle on Windows installations?

              Show
              mina Nicolas Martignoni added a comment - Sorry Joseph, Unable to reproduce on my own testing server (Moodle 2.3dev, builds 20120522 and 20120525), on Debian GNU/Linux 6.0.5 (squeeze). Maybe related to Moodle on Windows installations?
              Hide
              marina Marina Glancy added a comment -

              Hi Joseph,
              I can't reproduce it either. Can you please try it on http://qa.moodle.net/ and please write the exact sequence of actions that you do. I can guess that you are trying to insert an uploaded image into tinymce editor but it is not clear from your issue.
              Marina

              Show
              marina Marina Glancy added a comment - Hi Joseph, I can't reproduce it either. Can you please try it on http://qa.moodle.net/ and please write the exact sequence of actions that you do. I can guess that you are trying to insert an uploaded image into tinymce editor but it is not clear from your issue. Marina
              Hide
              salvetore Michael de Raadt added a comment -

              I was able to reproduce this error. I will add reproduction steps.

              Show
              salvetore Michael de Raadt added a comment - I was able to reproduce this error. I will add reproduction steps.
              Hide
              marina Marina Glancy added a comment -

              Michael, I'm afraid this is the same issue I was fixing yesterday. It should be already in integration, so please check on qa.moodle.net too

              Show
              marina Marina Glancy added a comment - Michael, I'm afraid this is the same issue I was fixing yesterday. It should be already in integration, so please check on qa.moodle.net too
              Hide
              salvetore Michael de Raadt added a comment -

              I'll check the latest integration from today.

              Show
              salvetore Michael de Raadt added a comment - I'll check the latest integration from today.
              Hide
              salvetore Michael de Raadt added a comment -

              The problem still appears in the latests integration.

              Show
              salvetore Michael de Raadt added a comment - The problem still appears in the latests integration.
              Hide
              rezeau Joseph Rézeau added a comment -

              @Marina,
              The problem is not with qa.moodle.net but apparently with local sites running Moodle under Windows 7.

              @Michael,
              thanks for adding the reproduction steps, I feel less alone. Now let's hope a) more Windows 7 users will confirm the issue and b) most importantly the bug will fixed ASAP, as this is a serious blocker.
              Joseph

              Show
              rezeau Joseph Rézeau added a comment - @Marina, The problem is not with qa.moodle.net but apparently with local sites running Moodle under Windows 7. @Michael, thanks for adding the reproduction steps, I feel less alone. Now let's hope a) more Windows 7 users will confirm the issue and b) most importantly the bug will fixed ASAP, as this is a serious blocker. Joseph
              Hide
              grizzou Jean-François Dragon added a comment -

              @Joseph,
              Not only on Windows 7... I get the same error on a local install (fresh from this morning) using EasyPHP 5.3.9 on Windows XP. I try with PNG and GIF files and get the same error message.

              Show
              grizzou Jean-François Dragon added a comment - @Joseph, Not only on Windows 7... I get the same error on a local install (fresh from this morning) using EasyPHP 5.3.9 on Windows XP. I try with PNG and GIF files and get the same error message.
              Hide
              lael Lael... added a comment -

              same on server2007, also zip files

              Show
              lael Lael... added a comment - same on server2007, also zip files
              Hide
              marina Marina Glancy added a comment -

              Thanks for spotting this. It appeared that I tried to fix it in MDL-33338 but missed couple of places.

              Show
              marina Marina Glancy added a comment - Thanks for spotting this. It appeared that I tried to fix it in MDL-33338 but missed couple of places.
              Hide
              nebgor Aparup Banerjee added a comment -

              Hi Marina,

              • as noted in MDL-33338 , i agree with Dan for the need for unit tests. How about we try adding some in with this issue?
              Show
              nebgor Aparup Banerjee added a comment - Hi Marina, as noted in MDL-33338 , i agree with Dan for the need for unit tests. How about we try adding some in with this issue? commit 4c2fcb was already integrated with MDL-33338 , so confirming that only this commit from the diff will be integrated: https://github.com/marinaglancy/moodle/commit/d28ca30645e89281d7e34afdbe4a117f66a2e57a
              Hide
              nebgor Aparup Banerjee added a comment - - edited

              Hi Marina,
              sorry, i was testing+integrating it but it failed at step 8. I uploaded a csv and named it as a .jpg file. it was not accepted.

              step 10 i get opposite (fail) result too.. it IS accpeted in step 10.

              Show
              nebgor Aparup Banerjee added a comment - - edited Hi Marina, sorry, i was testing+integrating it but it failed at step 8. I uploaded a csv and named it as a .jpg file. it was not accepted. step 10 i get opposite (fail) result too.. it IS accpeted in step 10.
              Hide
              marina Marina Glancy added a comment -

              (14:44:26) Marina: found why
              (14:44:46) Marina: you can't change the file extension when uploading a file
              (14:44:53) aparup apu: LOL
              (14:45:12) aparup apu: so is it possible to test?
              (14:45:21) Marina: I actually understand why
              (14:45:25) Marina: this is for windows users
              (14:45:31) Marina: who don't see extensions
              (14:45:38) aparup apu: ahhh
              (14:45:49) Marina: so when they upload file verylongname.jpg they actually only see 'verylongname'
              (14:46:04) Marina: so when they try to save it with another name they just type 'shortname'
              (14:46:10) Marina: without extension
              (14:46:21) aparup apu: in the OS dialog or the JS dialog? if its the JS dialog - we are showing full filename+ext
              (14:46:24) Marina: so we automatically add the extension from initial file

              I removed test when user changes the extension on upload

              Show
              marina Marina Glancy added a comment - (14:44:26) Marina: found why (14:44:46) Marina: you can't change the file extension when uploading a file (14:44:53) aparup apu: LOL (14:45:12) aparup apu: so is it possible to test? (14:45:21) Marina: I actually understand why (14:45:25) Marina: this is for windows users (14:45:31) Marina: who don't see extensions (14:45:38) aparup apu: ahhh (14:45:49) Marina: so when they upload file verylongname.jpg they actually only see 'verylongname' (14:46:04) Marina: so when they try to save it with another name they just type 'shortname' (14:46:10) Marina: without extension (14:46:21) aparup apu: in the OS dialog or the JS dialog? if its the JS dialog - we are showing full filename+ext (14:46:24) Marina: so we automatically add the extension from initial file I removed test when user changes the extension on upload
              Hide
              rezeau Joseph Rézeau added a comment -

              Just tested from Repository: git://github.com/marinaglancy/moodle.git Pull Master Branch: wip-MDL-33391-master.

              Works fine for me... and into the bargain it also solves the HotPots questions import bug mentioned in this forum discussion: moodle.org/mod/forum/discuss.php?d=203867

              Thanks!

              Show
              rezeau Joseph Rézeau added a comment - Just tested from Repository: git://github.com/marinaglancy/moodle.git Pull Master Branch: wip- MDL-33391 -master. Works fine for me... and into the bargain it also solves the HotPots questions import bug mentioned in this forum discussion: moodle.org/mod/forum/discuss.php?d=203867 Thanks!
              Hide
              nebgor Aparup Banerjee added a comment -

              This has been integrated into master.

              Please check with Marina if there's any problems with the testing instructions. She has verified that this works properly as expected as well as Joseph too. (Thanks Joseph!)

              Show
              nebgor Aparup Banerjee added a comment - This has been integrated into master. Please check with Marina if there's any problems with the testing instructions. She has verified that this works properly as expected as well as Joseph too. (Thanks Joseph!)
              Hide
              timb Tim Barker added a comment -

              Tested and passed.

              Show
              timb Tim Barker added a comment - Tested and passed.
              Hide
              ndenmeade Natalie Denmeade added a comment -

              I can not upload either jpgs or gifs using the filepicker in a page resource or simple label. I have admin rights.

              I downloaded latest Moodle 2.3.3 dev+ (Build: 20120601)and installed on my web host http://moojoo.com.au/md ( CentOS Enterprise Linux 5 in x86_64 (64-Bit) mode with Apache 2.2.x.). My local pc is Windows 7 pro 64 bit. Error occurs in IE9 and Chrome 19.0.1084.52

              So testing stops at step 5, please let me know if you require any more testing or info about this environment.

              Show
              ndenmeade Natalie Denmeade added a comment - I can not upload either jpgs or gifs using the filepicker in a page resource or simple label. I have admin rights. I downloaded latest Moodle 2.3.3 dev+ (Build: 20120601)and installed on my web host http://moojoo.com.au/md ( CentOS Enterprise Linux 5 in x86_64 (64-Bit) mode with Apache 2.2.x.). My local pc is Windows 7 pro 64 bit. Error occurs in IE9 and Chrome 19.0.1084.52 So testing stops at step 5, please let me know if you require any more testing or info about this environment.
              Hide
              marina Marina Glancy added a comment -

              Natalie, this issue is only in integration at the moment

              Show
              marina Marina Glancy added a comment - Natalie, this issue is only in integration at the moment
              Hide
              stronk7 Eloy Lafuente (stronk7) added a comment -

              We could celebrate it today... but better if we perform a bigger party after releasing Moodle 2.3.

              Print this message and come to Perth that day, it's valid for one beer, wine, coke or... water, as you wish.

              Many thanks for your collaboration!

              Ciao

              Show
              stronk7 Eloy Lafuente (stronk7) added a comment - We could celebrate it today... but better if we perform a bigger party after releasing Moodle 2.3. Print this message and come to Perth that day, it's valid for one beer, wine, coke or... water, as you wish. Many thanks for your collaboration! Ciao
              Hide
              rezeau Joseph Rézeau added a comment -

              Thanks to all!

              Show
              rezeau Joseph Rézeau added a comment - Thanks to all!
              Hide
              augustuslogos Richard Michael Coo added a comment -

              it's still not fixed.

              I'm using Moodle 2.3

              i can add a .png image via filepicker just fine

              Show
              augustuslogos Richard Michael Coo added a comment - it's still not fixed. I'm using Moodle 2.3 i can add a .png image via filepicker just fine
              Hide
              marina Marina Glancy added a comment -

              Hi Richard,
              Since we can not reproduce it, I need to ask you for more details.
              Please make sure that you use the latest release, and that you purged the caches. In case you have disabled "cachejs" setting, clear your browser cache.
              Please re-test the issue and if the problem is still there comment here with more details: OS version, browser, moodle version and attach a screenshot.
              Thank you!

              Show
              marina Marina Glancy added a comment - Hi Richard, Since we can not reproduce it, I need to ask you for more details. Please make sure that you use the latest release, and that you purged the caches. In case you have disabled "cachejs" setting, clear your browser cache. Please re-test the issue and if the problem is still there comment here with more details: OS version, browser, moodle version and attach a screenshot. Thank you!
              Hide
              tsala Helen Foster added a comment -

              Linking to a new report of this problem.

              Show
              tsala Helen Foster added a comment - Linking to a new report of this problem.

                People

                • Votes:
                  1 Vote for this issue
                  Watchers:
                  2 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:
                    Fix Release Date:
                    25/Jun/12