Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Minor
-
Resolution: Duplicate
-
Affects Version/s: 1.8.1, 1.9
-
Fix Version/s: None
-
Component/s: Resource
-
Labels:None
-
Affected Branches:MOODLE_18_STABLE, MOODLE_19_STABLE
Description
Create a resource type "Link to a file or web site".
Inside the resource settings page push the button "Search for web page..."
What is supposed to happen?
NOTING HAPPENS!!!!!!!!!!
Replace lines 630 - 634:
if (!empty($CFG->resource_websearch)) { $searchbutton = $mform->addElement('button', 'searchbutton', get_string('searchweb', 'resource').'...'); $buttonattributes = array('title'=>get_string('localfilechoose', 'resource'), 'onclick'=>"return window.open('$CFG->resource_websearch', 'websearch', 'menubar=1,location=1,directories=1,toolbar=1,scrollbars,resizable,width=800,height=600');"); $searchbutton->updateAttributes($buttonattributes); }
With these lines:
if (!empty($CFG->resource_websearch)) { $searchbutton = $mform->addElement('button', 'searchbutton', get_string('searchweb', 'resource'), array('title'=>get_string('searchweb', 'resource'), 'onclick'=>"return window.open('$CFG->resource_websearch', 'websearch', 'menubar=1,location=1,directories=1,toolbar=1,scrollbars,resizable,width=800,height=600');")); }
MORE DETAILS IN
MDL-9262.MDL-9262.