示例#1
0
文件: index.php 项目: nikrou/dotclear
        $post_editor = $core->auth->getOption('editor');
        if ($post_editor && !empty($post_editor[$post_format])) {
            // context is not post because of tags not available
            $admin_post_behavior = $core->callBehavior('adminPostEditor', $post_editor[$post_format], 'quickentry', array('#post_content'), $post_format);
        }
    }
}
/* DISPLAY
-------------------------------------------------------- */
dcPage::open(__('Dashboard'), dcPage::jsLoad('js/_index.js') . $admin_post_behavior . $core->callBehavior('adminDashboardHeaders'), dcPage::breadcrumb(array(__('Dashboard') . ' : ' . html::escapeHTML($core->blog->name) => ''), array('home_link' => false)));
# Dotclear updates notifications
if ($core->auth->isSuperAdmin() && is_readable(DC_DIGESTS)) {
    $updater = new dcUpdate(DC_UPDATE_URL, 'dotclear', DC_UPDATE_VERSION, DC_TPL_CACHE . '/versions');
    $new_v = $updater->check(DC_VERSION);
    $version_info = $new_v ? $updater->getInfoURL() : '';
    if ($updater->getNotify() && $new_v) {
        echo '<div class="dc-update"><h3>' . sprintf(__('Dotclear %s is available!'), $new_v) . '</h3> ' . '<p><a class="button submit" href="' . $core->adminurl->get("admin.update") . '">' . sprintf(__('Upgrade now'), $new_v) . '</a> ' . '<a class="button" href="' . $core->adminurl->get("admin.update", array('hide_msg' => 1)) . '">' . __('Remind me later') . '</a>' . ($version_info ? ' </p>' . '<p class="updt-info"><a href="' . $version_info . '">' . __('Information about this version') . '</a>' : '') . '</p>' . '</div>';
    }
}
if ($core->auth->getInfo('user_default_blog') != $core->blog->id && $core->auth->getBlogCount() > 1) {
    echo '<p><a href="' . $core->adminurl->get("admin.home", array('default_blog' => 1)) . '" class="button">' . __('Make this blog my default blog') . '</a></p>';
}
if ($core->blog->status == 0) {
    echo '<p class="static-msg">' . __('This blog is offline') . '.</p>';
} elseif ($core->blog->status == -1) {
    echo '<p class="static-msg">' . __('This blog is removed') . '.</p>';
}
if (!defined('DC_ADMIN_URL') || !DC_ADMIN_URL) {
    echo '<p class="static-msg">' . sprintf(__('%s is not defined, you should edit your configuration file.'), 'DC_ADMIN_URL') . ' ' . __('See <a href="http://dotclear.org/documentation/2.0/admin/config">documentation</a> for more information.') . '</p>';
}
if (!defined('DC_ADMIN_MAILFROM') || !DC_ADMIN_MAILFROM) {