|
This seems to be caused by move to
$mform-> for creating menus in the resource.class.php There is no rule for addding the repository button in the setup_elements function. The previous ims.html form is redundant - you can delete it with no impact on what you see. I used the following to create the button in the setup_elements function: if ($CFG->repositoryactivate == true) { $repositorybutton = $mform->addElement('button', 'repositorybutton', get_string('browserepository', 'resource').'...'); $buttonattributes = array('title'=>get_string('browserepository', 'resource'), 'onclick'=>"return window.open('".$CFG->wwwroot."/mod/resource/type/ims/finder.php?directory=', 'websearch', 'menubar=1,location=1,directories=1,toolbar=1,scrollbars,resizable,width=800,height=600');"); $repositorybutton->updateAttributes($buttonattributes); } which seems to work, except hitting choose in the finder does not return any information to the form. Now the "Browse Repository" is back (both under 18_STABLE, and HEAD).
Should be available in next nightly build (or by direct CVS access). Ciao P.S.: Also, the unused ims.html file has been removed from >= 18_STABLE. Thanks James!
Thanks Eloy, going to test it...
Thanks,
Working fine on my local test version - will push to live server soon and feedback, but can't see any reason for further issues. I did notice that the previous version used to automatically fill in the resource title (and summary?), but doesn't do this anymore. Not sure if this is a desired feature or not. Uhm... not sure if that's a desired feature. Perhaps, title or summary are empty, yes, but if they contain any info I wouldn't replace it.
Are you sure it was present in old releases? I've take a quick look and haven't been able to locate such code when choosing ims packages (both from the course area and from the repository). And finally, I guess it's really complex to do under new formslib. I'll imply to create one highly specialised form element (only used by ims cp) to provide such functionality... So, after all, I would vote -1 for that. Ciao It used to work in 1.6 version, but is far from essential. If you get some spare time for a super button go for it
Thanks |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
This is pretty important to my clients.
Sean K