mirror of
https://github.com/moodle/moodle.git
synced 2025-08-09 19:06:41 +02:00
MDL-23901 copy/paste style migration of glossary to export via pluginfile.php
This commit is contained in:
parent
e243c8c448
commit
1ca1c8f820
3 changed files with 24 additions and 57 deletions
|
@ -16,9 +16,7 @@ if ($cat !== 0) {
|
|||
if ($mode !== '') {
|
||||
$url->param('mode', $mode);
|
||||
}
|
||||
if ($hook !== '') {
|
||||
$url->param('hook', $hook);
|
||||
}
|
||||
|
||||
$PAGE->set_url($url);
|
||||
|
||||
if (! $cm = get_coursemodule_from_id('glossary', $id)) {
|
||||
|
@ -56,15 +54,15 @@ $PAGE->set_heading($course->fullname);
|
|||
echo $OUTPUT->header();
|
||||
echo $OUTPUT->heading($strexportentries);
|
||||
echo $OUTPUT->box_start('glossarydisplay generalbox');
|
||||
$exporturl = moodle_url::make_pluginfile_url($context->id, 'mod_glossary', 'export', 0, "/$cat/", 'export.xml', true);
|
||||
|
||||
?>
|
||||
<form action="exportfile.php" method="post">
|
||||
<form action="<?php echo $exporturl->out(); ?>" method="post">
|
||||
<table border="0" cellpadding="6" cellspacing="6" width="100%">
|
||||
<tr><td align="center">
|
||||
<input type="submit" value="<?php p($strexportfile)?>" />
|
||||
</td></tr></table>
|
||||
<div>
|
||||
<input type="hidden" name="id" value="<?php p($id)?>" />
|
||||
<input type="hidden" name="cat" value="<?php p($cat)?>" />
|
||||
</div>
|
||||
</form>
|
||||
<?php
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue