Importing a file into a Moodle page

Importing a file into a Moodle page

by Kimber Warden -
Number of replies: 2

I've got a file whose contents give students instructions on how to do something. I want to display the contents of this file in several assignments in the same course. I don't want to merely link to the file, I want to actually display the instructions without making it obvious that they're from an external file.

I tried an iframe, but can't figure out how to adjust the iframe's height to perfectly match the external file's height. I don't want there to be scrollbars.

I tried using php's require('myfile.htm'); but the HTML editor stripped out the php code so I can't even see if it would work.

Does anyone have any suggestions for how I can accomplish my goal in Moodle 2.2?

Average of ratings: -
In reply to Kimber Warden

Re: Importing a file into a Moodle page

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

How long is the file? I mean, if it is a word processed document for example, is it just one page or several? Because if it is only one page you could save it as an image and embed like that.

In reply to Mary Cooch

Re: Importing a file into a Moodle page

by Kimber Warden -

It's at least a full page, with some javascript that I need to keep active, so saving it as an image won't work. Otherwise, that may have been a good solution.

I know there's a way to call and display a file from within another one, I just need to figure out how. smile

Kimber