Exporting a canvas course, editing the html files and importing to the same course

Jump to solution
Andreasm
Community Explorer

Hello

Situation

We have several courses on Canvas. These courses have several pages which all contain a text string that needs removal.

Attempted solution

We exported course "something" which produces a "something.imscc" file which is a .zip file. We then unzipped it. Then we programatically removed all the strings that needed to be removed from the wiki_content folder files. After this we zipped it to the same name "somethings.imscc". Then we imported this file to the same course it was exported from. The hope was that this import would overwrite all the old html files with the new ones, however it just added duplicates of all the files, we then have the correct and the incorrect version of the same html page.

Question

Is there a way to export a course, do the editing needed to the html files in wiki_content and then import it to the same course and have it replace the old html files?

0 Likes
1 Solution

Hi @Andreasm,

Are the strings all in Canvas Pages, or are they in other areas like assignments, quizzes, etc too?  Another way to approach this programmatically would be to use the Canvas API to get the HTML content page-by-page, then do a search/replace, and update the content.  You could do this with your scripting/programming language of choice.  I find python to handle the API with fairly minimal code.

If you think this could be a solution that would work for you and want any further info, please let me know!

-Chris

View solution in original post