Link to File: Uploaded Word HTML files not showing
Number of replies: 12Whenever I try to link to an HTML file created in Microsoft Office (Word), all I get is a blank screen when the resource is supposed to load. I have tried other HTML files, and they work fine. I tried "cleaning" the file HTML in Dreamweaver, but that still didn't work.
These files all used to appear, but I think they stopped working after I upgraded to the most current version of Moodle.
I have attached a sample document.
Help, please?
Re: Link to File: Uploaded Word HTML files not showing
We have just yesterday resolved a whole bunch of similar issues in our 1.6.5. In \file.php in the root folder we changed this line (near the top):
$lifetime = 86400; // Seconds for files to remain in caches
to 180. This has fixed MS Office docs and pdfs.
I also inserted this into config.php:
// Seconds for files to remain in caches. Decrease this if you are worried
// about students being served outdated versions of uploaded files.
$CFG->filelifetime = 180;
I haven't had a chance to see if it's one or both together that sorted it.
Re: Link to File: Uploaded Word HTML files not showing
Still perplexed...
Re: Link to File: Uploaded Word HTML files not showing
i saw that you had similar issues with uploaded file links not showing as a resource. Did you by any chance find any solutions?
thanks
kirsten
Re: Link to File: Uploaded Word HTML files not showing
Re: Link to File: Uploaded Word HTML files not showing
absolutely no one has replied.. getting a bit discouraged with this odd problem.
Kirsten
Re: Link to File: Uploaded Word HTML files not showing
This is a very old problem, particularly when linking to word documents using the "Link to file or Web site" resource. I had lots of problems with this a couple of years ago on a site I use for student eportfolios and got tired of fighting with it, so I ended up hacking out the "Link to file or Web site" resource option on that site. You can do everything with a Label that you can do with "Link to file or Web site" anyway, and the problem doesn't seem to happen when using labels to add the links. It's also not a problem when displaying files in a directory...at least not on my sites.
Steve
Re: Link to File: Uploaded Word HTML files not showing
I had the same issue. By renaming or duplicating the file, it works fine again.
So I think that may have to do with some caches, in addition to a conflict with MS HTML headers.
Did you test to reload the file from the Moodle server? (<Ctrl> + <F5>)?
If OK, you can suggest to your users to unset their browser cache.
Arnaud
Re: Link to File: Uploaded Word HTML files not showing
- upload your file to the "features" course
- create a new resource of type "Link to file or Web site" which links to the uploaded file
I suspect your problem has nothing to do with this file. Are you able to display other html pages (e.g., a simple one created by hand)?
Re: Link to File: Uploaded Word HTML files not showing
I am using Moodle 1.7.2 and I have exactly the same problem. I upgraded from 1.5.4 (everything worked there) and now most of the htm files are not appearing. I checked the permissions - they are fine. I recreated a htm file with Macromedia and it worked.
I uploaded a not working htm file to demo.moodle.org and it worked there.
Does anyone have an idea what to do next? I do not want to remake all the htm files and I believe that moodle should show the htm files made with ms word as well
regards,
Tarmo Sildeberg
Re: Link to File: Uploaded Word HTML files not showing
It seemed to be files created with MS word or Frontpage and that had a couple of return characters and blank lines at the bottom of each file. Removing these 'empty' lines fixed the problem.
However I don't think the lines were actually empty - I thinkt hey were some odd non-displaying characters (ie ASCII values out of the normal alpha-numeric and symbol range)
The files worked fine of the old Learnwise Windows/ASP server.
I've got a feeling they were doing something similar to inserting blank lines after a closing php tag, but never really found out for sure what was happening.
check your files have no empty lines after the closing HTML tag.