This attempts to process HTML files loaded as media by finding and adjusting easily-detectable references to local script, css, and image assets. The intent is to handle "html activities" -- framed HTML content made interactive by scripts -- as used in statistics. An example has been added to the migration test course.
If needed, a modified copy of the file is written into a directory named <ProjectRoot>-converted alongside the input directory. This modified copy will be uploaded and used instead of the original. The content-relative tree structure is maintained within this output directory to permit matching up with files in the source and avoid need to rename files. However, only the modified HTML files are written here.
Limits: although intended for content embedded in iframes, the processing is NOT limited to HTML files referenced in iframes. In this version it will affect ALL HTML files used as asset references. So it could hit local html files referenced in other contexts, such as superactivity descriptor files. This may be undesirable.
It does not look for image references within CSS files, though this could be added using code that exists for dnd layout processing.
This attempts to process HTML files loaded as media by finding and adjusting easily-detectable references to local script, css, and image assets. The intent is to handle "html activities" -- framed HTML content made interactive by scripts -- as used in statistics. An example has been added to the migration test course.
If needed, a modified copy of the file is written into a directory named
<ProjectRoot>-converted
alongside the input directory. This modified copy will be uploaded and used instead of the original. The content-relative tree structure is maintained within this output directory to permit matching up with files in the source and avoid need to rename files. However, only the modified HTML files are written here.Limits: although intended for content embedded in iframes, the processing is NOT limited to HTML files referenced in iframes. In this version it will affect ALL HTML files used as asset references. So it could hit local html files referenced in other contexts, such as superactivity descriptor files. This may be undesirable.
It does not look for image references within CSS files, though this could be added using code that exists for dnd layout processing.