Exemplo n.º 1
0
function returnFormatToolbar()
{
    global $CMS_CONF;
    global $USER_SYNTAX;
    $content = '<table class="mo-menue-row-bottom mo-menue-row-top" width="100%" cellspacing="0" border="0" cellpadding="0">' . "<tr>" . '<td width="50%" class="mo-nowrap">' . returnFormatToolbarIcon("link") . returnFormatToolbarIcon("mail") . returnFormatToolbarIcon("seite") . returnFormatToolbarIcon("kategorie") . returnFormatToolbarIcon("datei") . returnFormatToolbarIcon("bild") . returnFormatToolbarIcon("bildlinks") . returnFormatToolbarIcon("bildrechts") . returnFormatToolbarIcon("absatz") . returnFormatToolbarIcon("liste") . returnFormatToolbarIcon("numliste") . returnFormatToolbarIcon("tabelle") . returnFormatToolbarIcon("linie") . returnFormatToolbarIcon("html") . returnFormatToolbarIcon("include") . "</td>" . '<td width="41%" class="mo-nowrap">' . returnFormatToolbarIcon("ueber1") . returnFormatToolbarIcon("ueber2") . returnFormatToolbarIcon("ueber3") . returnFormatToolbarIcon("links") . returnFormatToolbarIcon("zentriert") . returnFormatToolbarIcon("block") . returnFormatToolbarIcon("rechts") . returnFormatToolbarIcon("fett") . returnFormatToolbarIcon("kursiv") . returnFormatToolbarIcon("unter") . returnFormatToolbarIcon("durch") . returnFormatToolbarIcon("fontsize=0.8em") . "</td>" . '<td width="9%" id="colordiv-mozilo" class="mo-nowrap">' . returnToolbarColoredit() . "</td>" . "</tr>" . "</table>";
    // Smileys
    if ($user_icons = returnUserSyntaxIcons() or $CMS_CONF->get("replaceemoticons") == "true") {
        $content .= '<table class="mo-menue-row-bottom" width="100%" cellspacing="0" border="0" cellpadding="0"><tr>';
        if ($CMS_CONF->get("replaceemoticons") == "true") {
            $content .= '<td class="mo-nowrap" width="2%">' . returnSmileyBar() . '</td><td width="3%">&nbsp;</td>';
        }
        if ($user_icons) {
            $content .= '<td class="mo-nowrap">' . $user_icons . '</td>';
        }
        $content .= '</tr></table>';
    }
    $content .= '<table class="mo-menue-row-bottom" width="100%" cellspacing="0" border="0" cellpadding="0">' . "<tr>";
    # Template
    $template_title = NULL;
    $template_selectbox = "&nbsp;";
    if (ACTION == "template") {
        $template_title = "Template CSS und Bilder";
        $template_selectbox = returnTemplateSelectbox();
    }
    $content .= '<td style="width:22%;"><div class="mo-select-div">' . returnCatPagesSelectbox() . "</div></td>" . '<td style="width:22%;"><div class="mo-select-div">' . returnFilesSelectbox() . "</div></td>" . '<td style="width:22%;"><div class="mo-select-div">' . returnGalerySelectbox() . "</div></td>" . '<td style="width:34%;">' . $template_selectbox . "</td>" . "</tr>" . "</table>" . '<table class="mo-menue-row-bottom" width="100%" cellspacing="0" border="0" cellpadding="0">' . '<tr><td width="33%"><div class="mo-select-div">' . returnPluginSelectbox() . '</div></td>' . '<td width="33%"><div class="mo-select-div">' . returnPlatzhalterSelectbox() . '</div></td>' . '<td width="34%">' . returnUserSyntaxSelectbox() . '</td>' . '</tr></table>';
    return $content;
}
Exemplo n.º 2
0
function write_sort_list($movecat = false)
{
    if (false === getRequestValue('sort_array', 'post')) {
        return ajax_return("success", false);
    }
    global $cat_page_sort_array;
    $post = getRequestValue('sort_array', 'post');
    # da im frontend die cat erst umbenant wird wenn vom server ein succsses zurück kamm
    # müssen wir hier das sort_array aktualiesieren
    if (is_array($movecat)) {
        if ($movecat['type'] == "cat" and isset($post[$movecat['new']]) and isset($post[$movecat['org']])) {
            $post[$movecat['new']] = $post[$movecat['org']];
            unset($post[$movecat['org']]);
        }
    }
    $cat_page_sort_array = array();
    foreach ($post as $cat => $tmp) {
        if (substr($cat, -EXT_LENGTH) == EXT_LINK) {
            $cat_page_sort_array[$cat] = "null";
            continue;
        } else {
            $cat_page_sort_array[$cat] = array();
        }
        if (is_array($post[$cat])) {
            foreach ($post[$cat] as $page => $tmp) {
                $cat_page_sort_array[$cat][$page] = "null";
            }
        }
    }
    $sort_array = var_export($cat_page_sort_array, true);
    global $page_protect;
    if (true != mo_file_put_contents(SORT_CAT_PAGE, "<?php if(!defined('IS_CMS')) die();\n\$cat_page_sort_array = " . $sort_array . ";\n?>")) {
        return ajax_return("error", false, returnMessage(false, getLanguageValue("error_write_sort_list")), true, "js-dialog-reload");
    }
    global $CatPage;
    $CatPage = new CatPageClass();
    require_once BASE_DIR_ADMIN . 'editsite.php';
    if (true != ($error = write_xmlsitmap())) {
        return $error;
    }
    # wir schiken die neu selectbox zurück
    return ajax_return("success", false) . '<span id="replace-item">' . returnCatPagesSelectbox() . '</span>';
}