Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Improved the export file naming of bootstrap and decision tree and re…
…factored XOT to add extra labels - #466
  • Loading branch information
JohnSmith-LT committed May 16, 2016
1 parent d1d3dbc commit 5e097d5
Show file tree
Hide file tree
Showing 3 changed files with 53 additions and 2 deletions.
16 changes: 14 additions & 2 deletions modules/decision/export.php
Expand Up @@ -80,15 +80,13 @@
export_folder_loop($parent_template_path);

copy_parent_files();
$row['zipname'] .= '_archive';
}
else
{
_debug("Deployment archive");
export_folder_loop($parent_template_path . "common/");

copy_parent_files();
$row['zipname'] .= '_deployment';
}


Expand All @@ -112,6 +110,20 @@
*/
basic_html5_page_create($row['template_framework'], $row['template_name'], $lo_name);


/*
* Improve the naming of the exported zip file
*/

$export_type = "";
if ($fullArchive)
$export_type = "_archive";
else
$export_type = "_deployment";

$row['zipname'] .= $export_type;


/*
* Add the files to the zip file, create the archive, then send it to the user
*/
Expand Down
14 changes: 14 additions & 0 deletions modules/site/export.php
Expand Up @@ -100,6 +100,20 @@
*/
basic_html5_page_create($row['template_framework'], $row['template_framework'], $lo_name);


/*
* Improve the naming of the exported zip file
*/

$export_type = "";
if ($fullArchive)
$export_type = "_archive";
else
$export_type = "_deployment";

$row['zipname'] .= $export_type;


/*
* Add the files to the zip file, create the archive, then send it to the user
*/
Expand Down
25 changes: 25 additions & 0 deletions modules/xerte/export.php
Expand Up @@ -388,6 +388,31 @@ function create_offline_file($varname, $sourcefile, $destfile)
}
}


/*
* Improve the naming of the exported zip file
*/

$export_engine = "";
if ($export_flash && $export_html5)
$export_engine = "_flash_html5";
elseif ($export_flash)
$export_engine = "_flashonly";

$export_type = "";
if ($export_offline)
$export_type = "_offline";
elseif ($fullArchive)
$export_type = "_archive";
elseif ($scorm == "true")
$export_type = "_scorm_1_2";
elseif ($scorm == "2004")
$export_type = "_scorm_2004";
else
$export_type = "_deployment";

$row['zipname'] .= $export_engine . $export_type;

/*
* Add the files to the zip file, create the archive, then send it to the user
*/
Expand Down

0 comments on commit 5e097d5

Please sign in to comment.