Minor - replacing split function with explode.

1.9.x
Julio Montoya 10 years ago
parent 699f26c5ff
commit 75e3579a64
  1. 2
      main/newscorm/aiccBlock.class.php
  2. 2
      main/newscorm/aiccObjective.class.php
  3. 2
      main/newscorm/resourcelinker.inc.php
  4. 2
      main/newscorm/scorm.class.php

@ -39,7 +39,7 @@ class aiccBlock extends learnpathItem
break; break;
case 'member': case 'member':
if (strstr($value, ',') !== false) { if (strstr($value, ',') !== false) {
$temp = split(',', $value); $temp = explode(',', $value);
foreach ($temp as $val) { foreach ($temp as $val) {
if (!empty($val)) { if (!empty($val)) {
$this->members[] = $val; $this->members[] = $val;

@ -38,7 +38,7 @@ class aiccObjective extends learnpathItem
break; break;
case 'member': case 'member':
if (strstr($value, ',') !== false) { if (strstr($value, ',') !== false) {
$temp = split(',', $value); $temp = explode(',', $value);
foreach ($temp as $val) { foreach ($temp as $val) {
if (!empty($val)) { if (!empty($val)) {
$this->members[] = $val; $this->members[] = $val;

@ -402,7 +402,7 @@ function display_addedresource_link_in_learnpath($type, $id, $completed, $id_in_
echo str_repeat(" >", $level); echo str_repeat(" >", $level);
// The title and the text are in the content field and we only want to display the title. // The title and the text are in the content field and we only want to display the title.
list($title, $text) = split('<br>', $myrow['content']); list($title, $text) = explode('<br>', $myrow['content']);
if ($title == '') { $title = $myrow['content']; } if ($title == '') { $title = $myrow['content']; }
$title = $myrow['title']; $title = $myrow['title'];
$text = $myrow['content']; $text = $myrow['content'];

@ -806,7 +806,7 @@ class scorm extends learnpath
$result = Database::query($sql); $result = Database::query($sql);
$row = Database::fetch_array($result); $row = Database::fetch_array($result);
$LPname = $row['path']; $LPname = $row['path'];
$list = split('/', $LPname); $list = explode('/', $LPname);
$LPnamesafe = $list[0]; $LPnamesafe = $list[0];
//$zipfoldername = '/tmp'; //$zipfoldername = '/tmp';
//$zipfoldername = '../../courses/'.$_course['directory'].'/temp/'.$LPnamesafe; //$zipfoldername = '../../courses/'.$_course['directory'].'/temp/'.$LPnamesafe;

Loading…
Cancel
Save