Preview in File Picker

Preview in File Picker

by QLD BNE -
Number of replies: 7

I created a repository instance. Is it possible to see preview thumbnails of the jpg files in the file picker? Folder permissions set to 755

Average of ratings: -
In reply to QLD BNE

Re: Preview in File Picker

by Marina Glancy -
Picture of Core developers Picture of Moodle HQ Picture of Moodle Workplace team Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Testers

sure, don't forget to send 'thumbnail' and maybe 'realthumbnail' in your get_listing() function. See documentation http://docs.moodle.org/dev/Repository_plugins#get_listing.28.24path.3D.22.22.2C_.24page.3D.22.22.29 or examples in existing external repositories (dropbox, wikimedia, flickr, etc.)

In reply to QLD BNE

Re: Preview in File Picker

by QLD BNE -

@Marina,

The link you have given is vast. Could you simplify the way to achieve this please? Consider me a newbie smile

Regards

 

Moodle 2.5.1+

In reply to QLD BNE

Re: Preview in File Picker

by Marina Glancy -
Picture of Core developers Picture of Moodle HQ Picture of Moodle Workplace team Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Testers

Ok, then I probably misunderstood you. All repositories included in moodle standard package already display thumbnails. I thought you were talking about the repository you developed yourself. If not, you need to talk to the developer. You said "I created a repository instance" but you did not specify instance of WHICH repository type.

If you are not the developer there is no way to add thumbnails without modifying the code, sorry.

In reply to Marina Glancy

Re: Preview in File Picker

by QLD BNE -

@ Marina,

This is standard File System repository (please see ClipArt in the File Picker) and standard Moodle installation. So why it's not showing the thumbnails then?

In reply to QLD BNE

Re: Preview in File Picker

by Marina Glancy -
Picture of Core developers Picture of Moodle HQ Picture of Moodle Workplace team Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers Picture of Testers

I apologise again, I came to this discussion by the link from my mailbox and for some reason thought first it was in developers forum.

It is simply not implemented in filesystem repository. There is a tracker issue MDL-23044 for it

Average of ratings: Useful (1)
In reply to Marina Glancy

Re: Preview in File Picker

by QLD BNE -

Thanks Marina, I added to watch list and voted for the tracker issue you have noted.

Regards