]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-19807 Upgraded call to button_to_popup_window
authornicolasconnault <nicolasconnault>
Thu, 6 Aug 2009 00:27:20 +0000 (00:27 +0000)
committernicolasconnault <nicolasconnault>
Thu, 6 Aug 2009 00:27:20 +0000 (00:27 +0000)
mod/feedback/import.php

index 15d82c3a2c4e156c5f08e56f0115fa838dd2d6e5..3d28e0ab1251177c3dd4e495730011e217deb14c 100644 (file)
 
                 <tr>
                      <td>&nbsp;</td>
-                     <td><?php  button_to_popup_window ("/files/index.php?id={$course->id}&amp;choose=form.choosefile", 
-                          "coursefiles", get_string('choosefile', 'feedback'), 500, 750, get_string('choosefile', 'feedback')); ?>
+                     <td><?php  
+                        $form = new html_form();
+                        $form->button->text = get_string('choosefile', 'feedback');
+                        $form->button->title = $form->button->text;
+                        $form->url = "/files/index.php?id={$course->id}&choose=form.choosefile";
+                        $form->button->add_action(new popup_action('click', $form->url, "coursefiles", array('width' => 750, 'height' => 500)));
+                        echo $OUTPUT->button($form);
+                        ?>
                           <input type="submit" name="save" value="<?php print_string('importfromthisfile', 'feedback'); ?>" />
                     </td>
                 </tr>