Dotclear

source: plugins/zoneclearFeedServer/index.php @ 3139

Revision 3139, 2.5 KB checked in by JcDenis, 10 years ago (diff)
  • Required Dotclear 2.5
  • Fixed admin pages titles and messages and typo
  • Added Favorites icon
  • Added new 'homeonly' option on widgets
  • Fixed https protocol
  • Added option to keep active empty feeds
  • Added option to transform imported tags
Line 
1<?php
2# -- BEGIN LICENSE BLOCK ----------------------------------
3#
4# This file is part of zoneclearFeedServer, a plugin for Dotclear 2.
5#
6# Copyright (c) 2009-2013 Jean-Christian Denis, BG and contributors
7# contact@jcdenis.fr http://jcd.lv
8#
9# Licensed under the GPL version 2.0 license.
10# A copy of this license is available in LICENSE file or at
11# http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
12#
13# -- END LICENSE BLOCK ------------------------------------
14
15if (!defined('DC_CONTEXT_ADMIN')){return;}
16
17# Check user perms
18dcPage::check('admin');
19
20# Objects
21$s = $core->blog->settings->zoneclearFeedServer;
22$zc = new zoneclearFeedServer($core);
23
24# Default values
25$show_filters = false;
26$action = isset($_REQUEST['action']) ? $_REQUEST['action'] : '';
27
28$header = 
29dcPage::jsLoad('index.php?pf=zoneclearFeedServer/js/main.js').
30'<script type="text/javascript">'."\n//<![CDATA[\n".
31"jcToolsBox.prototype.text_wait = '".html::escapeJS(__('Please wait'))."';\n".
32"\n//]]>\n</script>\n";
33
34$footer = 
35'<hr class="clear"/><p class="right">
36<a class="button" href="'.$p_url.'&amp;part=setting">'.__('Settings').'</a> -
37zoneclearFeedServer - '.$core->plugins->moduleInfo('zoneclearFeedServer','version').'&nbsp;
38<img alt="'.__('Feeds server').'" src="index.php?pf=zoneclearFeedServer/icon.png" />
39</p>';
40
41# Messages
42$msg = isset($_REQUEST['msg']) ? $_REQUEST['msg'] : '';
43$msg_list = array(
44     'savesetting' => __('Configuration successfully saved'),
45     'deletepost' => __('Entries successuflly deleted'),
46     'deletefeed' => __('Feeds successfully deleted'),
47     'enablefeed' => __('Feeds successfully enabled'),
48     'disablefeed' => __('Feeds successfully disabled'),
49     'updatefeed' => __('Feeds successfully updated'),
50     'updfeedcat' => __('Category of feeds successfully updated'),
51     'updfeedint' => __('Frequency of feeds successfully updated'),
52     'resetupdlast' => __('Last update of feeds successfully reseted'),
53     'editfeed' => __('Feed successfully updated'),
54     'createfeed' => __('Feed successfully created'),
55     'postaction' => __('Actions on posts successfully completed')
56);
57if (isset($msg_list[$msg]))
58{
59     $msg = dcPage::message($msg_list[$msg]);
60}
61
62# Pages
63$start_part = $s->zoneclearFeedServer_active ? 'feeds' : 'setting';
64$default_part = isset($_REQUEST['part']) ? $_REQUEST['part'] : $start_part;
65
66if (!file_exists(dirname(__FILE__).'/inc/index.'.$default_part.'.php'))
67{
68     $default_part = 'setting';
69}
70include dirname(__FILE__).'/inc/index.'.$default_part.'.php';
71?>
Note: See TracBrowser for help on using the repository browser.

Sites map