Пример #1
0
    if (is_numeric($rss_id)) {
        echo '<a href="', ABS_PATH, 'rss/rss-', $rss_id, '.xml" target="blank"><img src="', ABS_PATH, 'modules/rss/templates/feed.gif" border="0" title="RSS лента новостей" /></a>';
    }
}
if (isset($_REQUEST['module']) && $_REQUEST['module'] == 'rss' && isset($_REQUEST['do']) && $_REQUEST['do'] == 'show') {
    header('Location:rss/index.php?id=' . $_GET['id']);
}
if (defined('ACP') && !empty($_REQUEST['moduleaction'])) {
    require BASE_DIR . '/modules/rss/class.rss.php';
    switch ($_REQUEST['moduleaction']) {
        case '1':
            $tpl_dir = BASE_DIR . '/modules/rss/templates/';
            $lang_file = BASE_DIR . '/modules/rss/lang/' . $_SESSION['user_language'] . '.txt';
            Rss::rssList($tpl_dir, $lang_file);
            break;
        case 'add':
            Rss::rssNew();
            break;
        case 'del':
            Rss::rssDelete();
            break;
        case 'edit':
            $tpl_dir = BASE_DIR . '/modules/rss/templates/';
            $lang_file = BASE_DIR . '/modules/rss/lang/' . $_SESSION['user_language'] . '.txt';
            Rss::rssEdit($tpl_dir, $lang_file);
            break;
        case 'saveedit':
            Rss::rssSave();
            break;
    }
}