$modx->makeList() is deprecated function Snippet - Ditto F:/wamp/www/MYFOLDER/assets/snippets/ditto/extenders/tagging.extender.inc.php(line:330)
$output = $modx->makeList($tagList, $ulroot='ditto_tag_list', $ulprefix='ditto_tag_', $type='', $ordered=false, $tablevel=0);
This question has been answered by kp52. See the first response.
function makeList($array, $ulroot= 'root', $ulprefix= 'sub_', $type= '', $ordered= false, $tablevel= 0) {
// first find out whether the value passed is an array
if (!is_array($array)) {
return "<ul><li>Bad list</li></ul>";
}
if (!empty ($type)) {
$typestr= " style='list-style-type: $type'";
} else {
$typestr= "";
}
$tabs= "";
for ($i= 0; $i < $tablevel; $i++) {
$tabs .= "\t";
}
$listhtml= $ordered == true ? $tabs . "<ol class='$ulroot'$typestr>\n" : $tabs . "<ul class='$ulroot'$typestr>\n";
foreach ($array as $key => $value) {
if (is_array($value)) {
$listhtml .= $tabs . "\t<li>" . $key . "\n" . $this->makeList($value, $ulprefix . $ulroot, $ulprefix, $type, $ordered, $tablevel +2) . $tabs . "\t</li>\n";
} else {
$listhtml .= $tabs . "\t<li>" . $value . "</li>\n";
}
}
$listhtml .= $ordered == true ? $tabs . "</ol>\n" : $tabs . "</ul>\n";
return $listhtml;
}
$output = $modx->makeList($tagList, $ulroot='ditto_tag_list', $ulprefix='ditto_tag_', $type='', $ordered=false, $tablevel=0); To $output = $this->makeList($tagList, $ulroot='ditto_tag_list', $ulprefix='ditto_tag_', $type='', $ordered=false, $tablevel=0);
// ---------------------------------------------------
// Function: fetch
// Get a template, based on version by Doze
//
// https://forums.modx.com/thread/41066/support-comments-for-ditto?page=2#dis-post-237942
// ---------------------------------------------------
function fetch($tpl){// ---------------------------------------------------
// Function: fetch
// Get a template, based on version by Doze
//
// https://forums.modx.com/thread/41066/support-comments-for-ditto?page=2#dis-post-237942
// ---------------------------------------------------
static function fetch($tpl){