<?php // Protect against hack attempts if (!defined('NGCMS')) { die('HAL'); } register_plugin_page('gsmg', '', 'plugin_gsmg_screen', 0); // Load library include_once root . "/plugins/gsmg/lib/common.php"; function plugin_gsmg_screen() { global $config, $mysql, $catz, $catmap, $SUPRESS_TEMPLATE_SHOW, $SYSTEM_FLAGS, $PFILTERS; $SUPRESS_TEMPLATE_SHOW = 1; $SUPRESS_MAINBLOCK_SHOW = 1; @header('Content-type: text/xml; charset=utf-8'); $SYSTEM_FLAGS['http.headers'] = array('content-type' => 'application/xml; charset=charset=utf-8', 'cache-control' => 'private'); if (extra_get_param('gsmg', 'cache')) { $cacheData = cacheRetrieveFile('gsmg.txt', extra_get_param('gsmg', 'cacheExpire'), 'gsmg'); if ($cacheData != false) { // We got data from cache. Return it and stop print $cacheData; return; } } $output = '<?xml version="1.0" encoding="UTF-8"?>'; $output .= '<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">'; // Настройки постранички if ($config['number'] < 1) { $config['number'] = 5; } // Надо ли выводить данные с головной страницы
if (!defined('NGCMS')) { exit('HAL'); } LoadPluginLang('eshop', 'main', '', '', '#'); add_act('index', 'eshop_header_show'); register_plugin_page('eshop', '', 'eshop'); register_plugin_page('eshop', 'show', 'show_eshop'); register_plugin_page('eshop', 'search', 'search_eshop'); register_plugin_page('eshop', 'stocks', 'stocks_eshop'); register_plugin_page('eshop', 'compare', 'compare_eshop'); register_plugin_page('eshop', 'currency', 'currency_eshop'); register_plugin_page('eshop', 'yml_export', 'yml_export_eshop'); register_plugin_page('eshop', 'ebasket_list', 'plugin_ebasket_list'); register_plugin_page('eshop', 'ebasket_update', 'plugin_ebasket_update'); register_plugin_page('eshop', 'order', 'order_eshop'); register_plugin_page('eshop', 'payment', 'payment_eshop'); include_once dirname(__FILE__) . '/cache.php'; function eshop_header_show() { global $CurrentHandler, $SYSTEM_FLAGS, $template, $lang; /* print '<pre>'; print_r ($CurrentHandler); print '</pre>'; */ /* print '<pre>'; print_r ($SYSTEM_FLAGS); print '</pre>'; */ if (empty($_REQUEST['page'])) { $page = $CurrentHandler['params']['page']; } else { $page = $_REQUEST['page']; }
<?php // Protect against hack attempts if (!defined('NGCMS')) { die('HAL'); } register_plugin_page('guestbook', '', 'guestbook_list'); register_plugin_page('guestbook', 'edit', 'guestbook_edit'); register_plugin_page('guestbook', 'social', 'guestbook_social'); LoadPluginLang('guestbook', 'main', '', '', '#'); switch ($_REQUEST['action']) { case 'add': msg_add_submit(); break; case 'edit': msg_edit_submit(); break; case 'delete': msg_delete_submit(); break; } /* * Add message submit callback */ function msg_add_submit() { global $template, $tpl, $twig, $userROW, $ip, $config, $mysql, $SYSTEM_FLAGS, $TemplateCache, $lang; $errors = array(); // anonymous user if (!is_array($userROW)) { $_POST['author'] = secure_html(convert(trim($_POST['author'])));