Moodle
  1. Moodle
  2. MDL-9923

Linked media in lesson module does not display web pages

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.8
    • Fix Version/s: 1.8.3
    • Component/s: Lesson
    • Labels:
      None
    • Environment:
      mysql 5.0.27
      php 4.4.4.8.2
    • Database:
      MySQL
    • Affected Branches:
      MOODLE_18_STABLE
    • Fixed Branches:
      MOODLE_18_STABLE
    • Rank:
      29460

      Description

      When adding linked media to a lesson (Pop-up to file or web page option in the lesson settings), if you place a url in the textbox and run the lesson, it will display a link for you to download the file, giving the url with the domain (.com, .org, etc.) stripped. Clicking on this give a file not found error.

      If you choose a file with .htm or .html, the linked media will pop up a box that displays the footer and nothing else.

      When I view source, I get the following bit of code that may be relevant (calc.html has been uploaded and is in my file structure):

      <div id="content">

      <frameset rows="100%"><frame src="http://elearn.metrotech.org//file.php/527/calc.html" /></frameset></div>
      <!-- end div content -->

      When I view source, I get the following bit of code that may be relevant (http://www.google.com has been entered in the textbox):

      <div id="content">

      <div class="lessonmediafilecontrol"><p><div class="notifyproblem" style="text-align:center">Click on the following link to download the file.</div><br />
      <a href="http://elearn.metrotech.org/file.php/527/http/www.google.com">www.google</a></p></div></div>
      <!-- end div content -->

        Activity

        Hide
        Mark Nielsen added a comment -

        Looks like there was a problem with the form and with the display. This is fixed now and you will most likely have to re-enter the URL because the lesson settings form was clobbering it.

        Show
        Mark Nielsen added a comment - Looks like there was a problem with the form and with the display. This is fixed now and you will most likely have to re-enter the URL because the lesson settings form was clobbering it.
        Hide
        Matt Campbell added a comment - - edited

        I can now link successfully to external web pages (i.e. www.google.com), but an uploaded .txt or .htm/.html is still a problem.

        Here are lines 86-88 from my latest view source when trying to view calc.html, a file that's been uploaded into the course files:

        <html dir="ltr">
        <head><meta http-equiv="content-type" content="text/html; charset=iso-8859-1" /><title>Sample I</title></head>
        <frameset rows="100%"><frame src="http://elearn.metrotech.org/file.php/527/calc.html" /></frameset></html>

        I've attached the error messages generated by W3C Validator, if that helps.

        Show
        Matt Campbell added a comment - - edited I can now link successfully to external web pages (i.e. www.google.com), but an uploaded .txt or .htm/.html is still a problem. Here are lines 86-88 from my latest view source when trying to view calc.html, a file that's been uploaded into the course files: <html dir="ltr"> <head><meta http-equiv="content-type" content="text/html; charset=iso-8859-1" /><title>Sample I</title></head> <frameset rows="100%"><frame src="http://elearn.metrotech.org/file.php/527/calc.html" /></frameset></html> I've attached the error messages generated by W3C Validator, if that helps.
        Hide
        Mark Nielsen added a comment -

        The header was printing for those when it should not. Header is suppressed now and changes are in 1.8.3+ and HEAD. Thanks for your help

        Show
        Mark Nielsen added a comment - The header was printing for those when it should not. Header is suppressed now and changes are in 1.8.3+ and HEAD. Thanks for your help
        Hide
        Matt Campbell added a comment - - edited

        Thanks, Mark. Verified that local txt, htm, and html files are now working.

        Show
        Matt Campbell added a comment - - edited Thanks, Mark. Verified that local txt, htm, and html files are now working.

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: