[svn r12197] fix a bug again with audio export/import

skala
Eric Marguin 18 years ago
parent 8b2540a61e
commit f0adf191a2
  1. 10
      main/newscorm/learnpath.class.php
  2. 6
      main/newscorm/learnpathItem.class.php

@ -6804,9 +6804,13 @@ function display_thread_form($action = 'add', $id = 0, $extra_info = '')
}
else if (empty($file_path))
{
$file_path = $_SERVER['DOCUMENT_ROOT'].$doc_info[0];
$file_path = substr($file_path,strlen($root_path)+1);
//echo $file_path;echo '<br><br>';
/*$document_root = substr(api_get_path(SYS_PATH), 0, strpos(api_get_path(SYS_PATH),api_get_path(REL_PATH)));
if(strpos($document_root,-1)=='/')
{
$document_root = substr(0, -1, $document_root);
}*/
$file_path = substr($doc_info[0],strlen(api_get_path(REL_PATH)));
//echo $file_path.'<br><br>';
//error_log('Reduced path: '.$file_path,0);
$zip_files_abs[] = $file_path;
$link_updates[$my_file_path][] = array('orig'=>$doc_info[0],'dest'=>$file_path);

@ -545,7 +545,11 @@ class learnpathItem{
if(strpos($source , 'mp3file'))
{
$files_list[] = array(substr($source, 0, strpos($source , '.swf')+4),'local','abs');
$files_list[] = array(substr($source , strpos($source , 'mp3file=')+8),'local','rel');
$mp3file = substr($source , strpos($source , 'mp3file=')+8);
if(strpos($mp3file,0,1) == '/')
$files_list[] = array($mp3file,'local','abs');
else
$files_list[] = array($mp3file,'local','rel');
}
}
if(strstr($source,'://') > 0)

Loading…
Cancel
Save