2 /****************************************************************/
4 /****************************************************************/
5 /* Copyright (c) 2002-2010 */
6 /* Inclusive Design Institute */
9 /* This program is free software. You can redistribute it and/or*/
10 /* modify it under the terms of the GNU General Public License */
11 /* as published by the Free Software Foundation. */
12 /****************************************************************/
15 define('AT_INCLUDE_PATH', '../../../include/');
16 require(AT_INCLUDE_PATH.'vitals.inc.php');
17 authenticate(AT_PRIV_CONTENT);
19 require(AT_INCLUDE_PATH.'header.inc.php');
21 if (!isset($_main_menu)) {
22 $_main_menu = $contentManager->getContent();
25 function print_menu_sections(&$menu, $parent_content_id = 0, $depth = 0, $ordering = '') {
26 $my_children = $menu[$parent_content_id];
29 if (!is_array($my_children)) {
32 foreach ($my_children as $children) {
33 echo '<option value="'.$children['content_id'].'"';
34 if ($cid == $children['content_id']) {
35 echo ' selected="selected"';
38 echo str_pad('', $depth, '-') . ' ';
39 if ($parent_content_id == 0) {
40 $new_ordering = $children['ordering'];
41 echo $children['ordering'];
43 $new_ordering = $ordering.'.'.$children['ordering'];
44 echo $ordering . '.'. $children['ordering'];
46 echo ' '.$children['title'].'</option>';
48 print_menu_sections($menu, $children['content_id'], $depth+1, $new_ordering);
53 <form name="form1" method="post" action="mods/_core/imscp/ims_import.php?tile=1" onsubmit="openWindow('<?php echo AT_BASE_HREF; ?>tools/prog.php?tile=1');">
54 <input type="hidden" name="url" value="<?php echo AT_TILE_EXPORT_CC_URL.$_GET['tile_course_id']; ?>" />
55 <input type="hidden" name="allow_a4a_import" value="1" />
56 <div class="input-form">
59 <?php echo _AT('tile_import_content_package_about'); ?>
63 <strong><?php echo _AT('import_content_package_where'); ?>:</strong>
65 <option value="0"><?php echo _AT('import_content_package_bottom_subcontent'); ?></option>
66 <option>--------------------------</option>
67 <?php print_menu_sections($_main_menu); ?>
72 <strong><?php echo _AT('import_content_package'); ?>:</strong> <?php echo urldecode($stripslashes($_GET['title'])); ?>
75 <div class="row buttons">
76 <input type="submit" name="submit" value="<?php echo _AT('import'); ?>" /> <input type="submit" name="cancel" value="<?php echo _AT('cancel'); ?>" />
81 <script language="javascript" type="text/javascript">
82 function openWindow(page) {
83 newWindow = window.open(page, "progWin", "width=400,height=200,toolbar=no,location=no");
88 <?php require (AT_INCLUDE_PATH.'footer.inc.php'); ?>