' . "\n";
if ($editable) {
$html .= '
' . editableText($page, "sections.$index.title", $title) . '
' . "\n";
$html .= editableHtml($page, "sections.$index.content", $content);
} else {
if ($title !== '') {
$html .= ' ' . htmlspecialchars($title) . '
' . "\n";
}
if (!empty($content)) {
$html .= sanitizeHtml($content);
} elseif (!empty($items)) {
$tag = $style === 'numbered' ? 'ol' : 'ul';
$html .= ' <' . $tag . '>' . "\n";
foreach ($items as $item) {
$html .= ' ' . htmlspecialchars($item) . '' . "\n";
}
$html .= ' ' . $tag . '>' . "\n";
}
}
$html .= '' . "\n";
return $html;