Displaying "plugin files" publicly

Displaying "plugin files" publicly

by Doug Henner -
Number of replies: 1

Dear All,

on our Moodle - site (Moodle 3.5, adaptable theme) I want to make some videos from Moodle visible for the public. For example we have a short uploaded video like e.g.  

moodledomain.com/pluginfile.php/1734/mod_glossary/entry/235/examplevideo.m4v 


that one I want to present for the not logged-in user on the front page.


So i created a web service "publicvideos".


... enabled "File upload" as well as "moodle/course:managefiles:" for that service.


... added Function "core_files_get_files browse moodle files" for that service

... created a token. For trial purposes I chose an admin user with administer privileges 

    as service I chose "publicvideos"

    assume the token is "123456789"

... activated REST as well as XML-RPC protocol


So I changed the url above to


moodledomain.com/pluginfile.php/1734/mod_glossary/entry/235/examplevideo.m4v?token=123456789



I expected to download examplevideo.m4v by that link but still getting:


error "Access Control Exception"

errorcode "accessexception"

stacktrace null

debuginfo null

reproductionlink null



As I said I want to display the video on that start page. Is that basically the right way ?

If yes can you tell what is wrong / missing ?


Thanks a lot !


Best,


Doug


Average of ratings: -