Source for file form.scorm.php
Documentation is available at form.scorm.php
* Display part of the SCORM sub-process for upload. This script MUST BE included by upload/index.php
* as it prepares most of the variables needed here.
* @author Yannick Warnier <ywarnier@beeznest.org>
* Small function to list files in garbage/
if(substr($entry,0,1) == '.'){/*ignore files starting with . */}
* Just display the form needed to upload a SCORM and give its settings
$interbreadcrumb[]= array ("url"=> "../newscorm/lp_controller.php?action=list", "name"=> get_lang("Learnpath"));
require_once (api_get_path(LIBRARY_PATH). 'formvalidator/FormValidator.class.php');
include('../newscorm/content_makers.inc.php');
$form = new FormValidator('','POST','upload.php','','id="upload_form" enctype="multipart/form-data" style="background-image: url(\'../img/scorm.jpg\'); background-repeat: no-repeat; background-position: 600px;"');
$form->addElement('hidden', 'curdirpath', $path);
$form->addElement('hidden', 'tool', $my_tool);
$form->addElement('file','user_file',get_lang('FileToUpload'));
$select_content_marker = &$form->addElement('select','content_maker',get_lang('ContentMaker'));
foreach($content_origins as $index => $origin){
$select_content_marker->addOption($origin,$origin);
$select_content_proximity = &$form->addElement('select','content_proximity',get_lang('ContentProximity'));
$select_content_proximity -> setSelected("local");
$form->addElement('submit', 'submit', get_lang('Send'));
$form->addElement('html', '<br><br><br>');
/*$list = get_zip_files_in_garbage();
$select_file_name = &$form->addElement('select','file_name',get_lang('Or').' '.strtolower(get_lang('UploadLocalFileFromGarbageDir')));
$select_file_name->addOption($file,$file);
$form->addElement('submit', 'submit', get_lang('Download'));
$text_empty = &$form->addElement('text', 'empty', get_lang('Or').' '.strtolower(get_lang('UploadLocalFileFromGarbageDir')));
$defaults["empty"] = get_lang('Empty');
$form->add_real_progress_bar('uploadScorm','user_file');
$form->setDefaults($defaults);
==============================================================================
==============================================================================
|