@@ 9698-9700 (lines=3) @@ | ||
9695 | // ../../.. to return from inc/lib/flv_player to the document/main path. |
|
9696 | if (substr($old_new['dest'], -3) == 'flv' && substr($old_new['dest'], 0, 5) == 'main/') { |
|
9697 | $old_new['dest'] = str_replace('main/', '../../../', $old_new['dest']); |
|
9698 | } elseif (substr($old_new['dest'], -3) == 'flv' && substr($old_new['dest'], 0, 6) == 'video/') { |
|
9699 | $old_new['dest'] = str_replace('video/', '../../../../video/', $old_new['dest']); |
|
9700 | } |
|
9701 | //Fix to avoid problems with default_course_document |
|
9702 | if (strpos("main/default_course_document", $old_new['dest'] === false)) { |
|
9703 | //$newDestination = str_replace('document/', $mult.'document/', $old_new['dest']); |
|
@@ 9741-9743 (lines=3) @@ | ||
9738 | // will be added in document/main/inc/lib/flv_player/flv_player.swf and that needs |
|
9739 | // to find the flv to play in document/main/, so we replace main/ in the flv path by |
|
9740 | // ../../.. to return from inc/lib/flv_player to the document/main path. |
|
9741 | if (substr($old_new['dest'], -3) == 'flv' && substr($old_new['dest'], 0, 5) == 'main/') { |
|
9742 | $old_new['dest'] = str_replace('main/', '../../../', $old_new['dest']); |
|
9743 | } |
|
9744 | $string = str_replace($old_new['orig'], $old_new['dest'], $string); |
|
9745 | } |
|
9746 | file_put_contents($dest_file, $string); |