From: <zy...@us...> - 2016-05-29 20:10:20
|
Revision: 13210 http://sourceforge.net/p/xoops/svn/13210 Author: zyspec Date: 2016-05-29 20:10:16 +0000 (Sun, 29 May 2016) Log Message: ----------- - translated release notes to English (zyspec) - added Addresses, AdsLight, AmReviews, AMS, eGuide, FmContent, Lexikon, MxDirectory, MyDownloads, MyWords, MyTube, PDLinks, Portfolio, Qpages, Recette, SmartFaq, SongList, TDMDownloads, TDMPictures, WfDownloads, WfLinks, XoopsFaq, xQuiz, & Xyp4all plugin support on install (zyspec) - changed Publisher plugin to sort by weight instead of title (zyspec) - changed assigned by reference for methods/functions (zyspec) - changed to use XoopsRequest to filter input vars (zyspec) - changed most to use $[GLOBALS] (zyspec) - changed class names to be more XOOPS compatible (zyspec) - change XoopsDummyObject to XsitemapDummyObject (zyspec) - included admin language file in ./include/functions (zyspec) - general code cleanup (zyspec) - updated phpdocumentor comments (copyright, XOOPS Url, etc) (zyspec) - removed '/' from HTML void tags (<br>, <img>, etc) (zyspec) - removed XoopsPersistableObjectHandler class (zyspec) Modified Paths: -------------- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/about.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/admin_footer.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/admin_header.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/index.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/menu.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/plugin.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/xml.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/class/menu.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/class/plugin.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/docs/changelog.txt XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/docs/install.txt XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/include/functions.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/include/install.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/index.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/language/english/admin.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/language/english/blocks.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/language/english/help/help.html XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/language/english/main.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/language/english/modinfo.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/sql/mysql.sql XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/templates/xsitemap_index.tpl XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/templates/xsitemap_slickmap.tpl XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/templates/xsitemap_xml.tpl XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/xml_google.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/xoops_version.php Added Paths: ----------- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/assets/css/style.css XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/class/dummy.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/include/action.module.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/templates/admin/ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/templates/admin/index.html XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/templates/admin/xsitemap_index.tpl Removed Paths: ------------- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/class/object.php XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/class/xsitemap_class.php Modified: XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/about.php =================================================================== --- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/about.php 2016-03-28 10:28:36 UTC (rev 13209) +++ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/about.php 2016-05-29 20:10:16 UTC (rev 13210) @@ -1,31 +1,32 @@ -<?php -/** - * xSiteMap module - * - * You may not change or alter any portion of this comment or credits - * of supporting developers from this source code or any supporting source code - * which is considered copyrighted (c) material of the original comment or credit authors. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/ - * @license http://www.gnu.org/licenses/gpl-2.0.html GNU Public License - * @copyright The XOOPS Project (http://www.xoops.org) - * @license {@link http://www.gnu.org/licenses/gpl-2.0.html GNU Public License} - * @package xSiteMap - * @since 2.5.0 - * @author Mage, Mamba - * @version $Id $ - **/ - -include_once dirname(__FILE__) . '/admin_header.php'; - -xoops_cp_header(); - -$aboutAdmin = new ModuleAdmin(); - -echo $aboutAdmin->addNavigation('about.php'); -echo $aboutAdmin->renderabout('6KJ7RW5DR3VTJ', false); - -include 'admin_footer.php'; +<?php +/* + * xSiteMap module + * + * You may not change or alter any portion of this comment or credits + * of supporting developers from this source code or any supporting source code + * which is considered copyrighted (c) material of the original comment or credit authors. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + */ +/** + * @package xSiteMap + * @copyright {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://xoops.org 2001-2016 XOOPS Project} + * @license {@link http://www.gnu.org/licenses/gpl-2.0.html GNU Public License} + * @author {@link http://www.takeaweb.it Urbanspaceman} + * @author Mage, Mamba + * @link http://xoops.org XOOPS + * @since:: 1.00 + **/ + +include_once __DIR__ . '/admin_header.php'; + +xoops_cp_header(); + +$aboutAdmin = new ModuleAdmin(); + +echo $aboutAdmin->addNavigation('about.php'); +echo $aboutAdmin->renderabout('6KJ7RW5DR3VTJ', false); + +include __DIR__ . '/admin_footer.php'; Modified: XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/admin_footer.php =================================================================== --- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/admin_footer.php 2016-03-28 10:28:36 UTC (rev 13209) +++ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/admin_footer.php 2016-05-29 20:10:16 UTC (rev 13210) @@ -1,26 +1,27 @@ -<?php -/** - * xSitemMap module - * - * You may not change or alter any portion of this comment or credits - * of supporting developers from this source code or any supporting source code - * which is considered copyrighted (c) material of the original comment or credit authors. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * @copyright The XOOPS Project http://sourceforge.net/projects/xoops/ - * @license http://www.gnu.org/licenses/gpl-2.0.html GNU Public License - * @package xSitemMap - * @since 2.5.0 - * @author XOOPS Module Team - * @version $Id $ -**/ -echo "<div class='adminfooter'>\n" - ." <div style='text-align: center;'>\n" - ." <a href='http://www.xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n" - ." </div>\n" - ." " . _AM_MODULEADMIN_ADMIN_FOOTER . "\n" - ."</div>"; - -xoops_cp_footer(); +<?php +/* + * xSitemMap module + * + * You may not change or alter any portion of this comment or credits + * of supporting developers from this source code or any supporting source code + * which is considered copyrighted (c) material of the original comment or credit authors. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + */ +/** + * @package xSiteMap + * @copyright {@link http://xoops.org 2001-2016 XOOPS Project} + * @license {@link http://www.gnu.org/licenses/gpl-2.0.html GNU Public License} + * @author XOOPS Module Development Team + * @link http://xoops.org XOOPS +**/ + +echo "<div class='adminfooter'>\n" + . " <div class='txtcenter'>\n" + . " <a href='http://www.xoops.org' rel='external' target='_blank'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n" + . " </div>\n" + . " " . _AM_MODULEADMIN_ADMIN_FOOTER . "\n" + . "</div>\n"; + +xoops_cp_footer(); Modified: XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/admin_header.php =================================================================== --- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/admin_header.php 2016-03-28 10:28:36 UTC (rev 13209) +++ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/admin_header.php 2016-05-29 20:10:16 UTC (rev 13210) @@ -1,101 +1,54 @@ -<?php -/** - * xSiteMap module - * - * You may not change or alter any portion of this comment or credits - * of supporting developers from this source code or any supporting source code - * which is considered copyrighted (c) material of the original comment or credit authors. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * @copyright:: The XOOPS Project http://sourceforge.net/projects/xoops/ - * @license:: {@link http://www.gnu.org/licenses/gpl-2.0.html GNU Public License} - * @package:: xSiteMap - * @subpackage:: admin - * @since:: 2.5.0 - * @author:: XOOPS Team - * @version:: $Id $ -**/ - -$path = dirname(dirname(dirname(dirname(__FILE__)))); -include_once $path . '/mainfile.php'; -include_once $path . '/include/cp_functions.php'; -require_once $path . '/include/cp_header.php'; - -global $xoopsModule; - -$thisModuleDir = $GLOBALS['xoopsModule']->getVar('dirname'); - -//if functions.php file exist -require_once dirname(dirname(__FILE__)) . '/include/functions.php'; -include_once dirname(dirname(__FILE__)) . '/class/plugin.php'; - -// Load language files -xoops_loadLanguage('admin', $thisModuleDir); -xoops_loadLanguage('modinfo', $thisModuleDir); -xoops_loadLanguage('main', $thisModuleDir); - -$pathIcon16 = '../'.$xoopsModule->getInfo('icons16'); -$pathIcon32 = '../'.$xoopsModule->getInfo('icons32'); -$pathModuleAdmin = $xoopsModule->getInfo('dirmoduleadmin'); - -if ( file_exists($GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php'))) { - include_once $GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php'); - } else { - redirect_header("../../../admin.php", 5, _AM_XSITEMAP_MODULEADMIN_MISSING, false); - } - -function xsitemap_adminmenu ($currentoption = 0, $breadcrumb = "") -{ - global $xoopsModule, $xoopsConfig; - - echo " - <style type=\"text/css\"> - #buttontop { float:left; width:100%; background: #e7e7e7; font-size:93%; line-height:normal; border-top: 1px solid black; border-left: 1px solid black; border-right: 1px solid black; margin: 0; } - #buttonbar { float:left; width:100%; background: #e7e7e7 url(".XOOPS_URL."/modules/xsitemap/assets/images/menu/bg.png) repeat-x left bottom; font-size:93%; line-height:normal; border-left: 1px solid black; border-right: 1px solid black; margin-bottom: 12px; } - #buttonbar ul { margin:0; margin-top: 15px; padding:10px 10px 0; list-style:none; } - #buttonbar li { display:inline; margin:0; padding:0; } - #buttonbar a { float:left; background:url(".XOOPS_URL."/modules/xsitemap/assets/images/deco/left_both.png) no-repeat left top; margin:0; padding:0 0 0 9px; border-bottom:1px solid #000; text-decoration:none; } - #buttonbar a span { float:left; display:block; background:url(".XOOPS_URL."/modules/xsitemap/assets/images/deco/right_both.png) no-repeat right top; padding:5px 15px 4px 6px; font-weight:bold; color:#765; } - #buttonbar a span {float:none;} - #buttonbar a:hover span { color:#333; } - #buttonbar #current a { background-position:0 -150px; border-width:0; } - #buttonbar #current a span { background-position:100% -150px; padding-bottom:5px; color:#333; } - #buttonbar a:hover { background-position:0% -150px; } - #buttonbar a:hover span { background-position:100% -150px; } - </style> - "; - - $tblColors = Array(); - $tblColors[0] = $tblColors[1] = $tblColors[2] = $tblColors[3] = $tblColors[4] = $tblColors[5] = $tblColors[6] = $tblColors[7] = $tblColors[8] = ""; - $tblColors[$currentoption] = "current"; - if (file_exists("".XOOPS_ROOT_PATH."/modules/".$xoopsModule->getVar("dirname")."/language/".$xoopsConfig["language"]."/modinfo.php")) { - include_once("".XOOPS_ROOT_PATH."/modules/".$xoopsModule->getVar("dirname")."/language/".$xoopsConfig["language"]."/modinfo.php"); - } else { - include_once("".XOOPS_ROOT_PATH."/modules/".$xoopsModule->getVar("dirname")."/english/modinfo.php"); - } - - echo "<div id=\"buttontop\"> - <table style=\"width: 100%; padding: 0;\" cellspacing=\"0\"> - <tr> - <td style=\"font-size: 10px; text-align: left; color: #2F5376; padding: 0 6px; line-height: 18px;\"> - <a class=\"nobutton\" href=\"".XOOPS_URL."/modules/system/admin.php?fct=preferences&op=showmod&mod=".$myts->displayTarea($xoopsModule->getVar("mid"))."\">_AM_XSITEMAP_GENERALSET</a> - | <a href=\"".XOOPS_URL."/modules/xsitemap/index.php\">_AM_XSITEMAP_GOINDEX</a> - | <a href=\"".XOOPS_URL."/modules/xsitemap/admin/upgrade.php\">_AM_XSITEMAP_UPGRADE</a> - </td> - <td style=\"font-size: 10px; text-align: right; color: #2F5376; padding: 0 6px; line-height: 18px;\"><b>".$myts->displayTarea($xoopsModule->name())."</b></td> - </tr> - </table> - </div> - - <div id=\"buttonbar\"> - <ul><li id=\"$tblColors[0]\"><a href=\"".XOOPS_URL."/modules/xsitemap/admin/index.php\"><span>_MI_XSITEMAP_MANAGER_INDEX</span></a></li> - <li id=\"$tblColors[1]\"><a href=\"".XOOPS_URL."/modules/xsitemap/admin/plugin.php\"><span>_MI_XSITEMAP_MANAGER_PLUGIN</span></a></li> - - <li id=\"$tblColors[2]\"><a href=\"".XOOPS_URL."/modules/xsitemap/admin/permissions.php\"><span>_MI_XSITEMAP_MANAGER_PERMISSIONS</span></a></li> - <li id=\"$tblColors[3]\"><a href=\"".XOOPS_URL."/modules/xsitemap/admin/about.php\"><span>_MI_XSITEMAP_MANAGER_ABOUT</span></a></li> - </ul></div>"; -} - -$pluginHandler =& xoops_getModuleHandler("xsitemap_plugin", "xsitemap"); +<?php +/* + * xSiteMap module + * + * You may not change or alter any portion of this comment or credits + * of supporting developers from this source code or any supporting source code + * which is considered copyrighted (c) material of the original comment or credit authors. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + */ +/** + * @package xSiteMap + * @copyright {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://xoops.org 2001-2016 XOOPS Project} + * @license {@link http://www.gnu.org/licenses/gpl-2.0.html GNU Public License} + * @author:: XOOPS Module Dev Team + * @link http://xoops.org XOOPS + * @since:: 1.00 +**/ + +$path = dirname(dirname(dirname(__DIR__))); +include_once $path . '/mainfile.php'; +include_once $path . '/include/cp_functions.php'; +require_once $path . '/include/cp_header.php'; +xoops_load('XoopsRequest'); + +$moduleDirname = $GLOBALS['xoopsModule']->getVar('dirname'); + +//if functions.php file exist +require_once dirname(__DIR__) . '/include/functions.php'; +include_once dirname(__DIR__) . '/class/plugin.php'; + +// Load language files +xoops_loadLanguage('admin', $moduleDirname); +xoops_loadLanguage('modinfo', $moduleDirname); +xoops_loadLanguage('main', $moduleDirname); + +$pathIcon16 = $GLOBALS['xoops']->url('www/' . $GLOBALS['xoopsModule']->getInfo('icons16')); +$pathIcon32 = $GLOBALS['xoops']->url('www/' . $GLOBALS['xoopsModule']->getInfo('icons32')); +$pathModuleAdmin = $GLOBALS['xoops']->path('www/' . $GLOBALS['xoopsModule']->getInfo('dirmoduleadmin')); + +/* shouldn't be required since XOOPS >= 2.5.6 has this +if (file_exists($GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php'))) { + include_once $GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php'); +} else { + redirect_header($GLOBALS['xoops']->path("www/admin.php"), 5, _AM_XSITEMAP_MODULEADMIN_MISSING, false); +} +*/ +require_once "{$pathModuleAdmin}/moduleadmin/moduleadmin.php"; + +// module specific pieces +include_once $GLOBALS['xoops']->path("/modules/{$moduleDirname}/include/functions.php"); +$pluginHandler = xoops_getModuleHandler('plugin', $moduleDirname); Modified: XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/index.php =================================================================== --- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/index.php 2016-03-28 10:28:36 UTC (rev 13209) +++ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/index.php 2016-05-29 20:10:16 UTC (rev 13210) @@ -1,83 +1,78 @@ -<?php -/** - * **************************************************************************** - * Module g\xE9n\xE9r\xE9 par TDMCreate de la TDM "http://www.tdmxoops.net" - * **************************************************************************** - * xsitemap - MODULE FOR XOOPS CMS - * Copyright (c) Urbanspaceman (http://www.takeaweb.it) - * - * You may not change or alter any portion of this comment or credits - * of supporting developers from this source code or any supporting source code - * which is considered copyrighted (c) material of the original comment or credit authors. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * @copyright Urbanspaceman (http://www.takeaweb.it) - * @license GPL - * @package xsitemap - * @author Urbanspaceman (http://www.takeaweb.it) - * - * Version : 1.00: - * **************************************************************************** - */ -include '../../../include/cp_header.php'; -include_once './admin_header.php'; -//$moduleInfo =& $module_handler->get( $xoopsModule->getVar("mid") ); -xoops_cp_header(); - -$index_admin = new ModuleAdmin(); - -global $xoopsModule; - -//Apelle du menu admin -// if ( !is_readable(XOOPS_ROOT_PATH."/Frameworks/art/functions.admin.php")) { -// xsitemap_adminmenu(0, _AM_XSITEMAP_MANAGER_INDEX); -// } else { -// include_once XOOPS_ROOT_PATH."/Frameworks/art/functions.admin.php"; -// loadModuleAdminMenu (0, _AM_XSITEMAP_MANAGER_INDEX); -// } - - //compte "total" - $count_plugin = $pluginHandler->getCount(); - //compte "attente" - $criteria = new CriteriaCompo(); - $criteria->add(new Criteria("plugin_online", 1)); - $plugin_online = $pluginHandler->getCount($criteria); - - echo $index_admin->addNavigation('index.php'); - echo $index_admin->renderIndex(); - -// include_once XOOPS_ROOT_PATH."/modules/xsitemap/class/menu.php"; - - // $menu = new xsitemapMenu(); - // $menu->addItem("plugin", "plugin.php", "../images/deco/contact.png", _AM_XSITEMAP_MANAGER_PLUGIN); - // $menu->addItem("xml", "xml.php", "../images/deco/xml.png", _AM_XSITEMAP_XML); - // $menu->addItem("about", "about.php", "../images/deco/about.png", _AM_XSITEMAP_MANAGER_ABOUT); - // $menu->addItem("preference", "../../system/admin.php?fct=preferences&op=showmod&mod=".$xoopsModule->getVar("mid"). - // "&&confcat_id=1", "../images/deco/pref.png", _AM_XSITEMAP_MANAGER_PREFERENCES); - // $menu->addItem("update", "../../system/admin.php?fct=modulesadmin&op=update&module=xsitemap", "../images/deco/update.png", _AM_XSITEMAP_MANAGER_UPDATE); - -// echo $menu->getCSS(); - -// echo "<div class=\"CPbigTitle\" style=\"background-image: url(../images/deco/index.png); background-repeat: no-repeat; background-position: left; padding-left: 50px;\"><strong>"._AM_XSITEMAP_MANAGER_INDEX."</strong></div><br /> - // <table width=\"100%\" border=\"0\" cellspacing=\"10\" cellpadding=\"4\"> - // <tr> - // <td valign=\"top\">".$menu->render()."</td> - // <td valign=\"top\" width=\"60%\">"; - - // echo "<fieldset> - // <legend class=\"CPmediumTitle\">"._AM_XSITEMAP_MANAGER_PLUGIN."</legend> - // <br />"; - // printf(_AM_XSITEMAP_THEREARE_PLUGIN, $count_plugin); - // echo "<br /><br />"; - // printf(_AM_XSITEMAP_THEREARE_PLUGIN_ONLINE, $plugin_online); - // echo "<br /> - // </fieldset><br /><br />"; - - // echo "</td> - // </tr> - // </table> -// <br /><br /> -// <div align=\"center\">"._AM_XSITEMAP_ABOUT_BY."</div>"; -include 'admin_footer.php'; +<?php +/* + * **************************************************************************** + * Module g\xE9n\xE9r\xE9 par TDMCreate de la TDM "http://www.tdmxoops.net" + * **************************************************************************** + * xsitemap - MODULE FOR XOOPS CMS + * Copyright (c) Urbanspaceman (http://www.takeaweb.it) + * + * You may not change or alter any portion of this comment or credits + * of supporting developers from this source code or any supporting source code + * which is considered copyrighted (c) material of the original comment or credit authors. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * **************************************************************************** + */ +/** + * Module: xSiteMap + * + * @category Module + * @package xSiteMap + * @subpackage admin + * @author XOOPS Module Development Team + * @author {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://xoops.org 2001-2016 XOOPS Project} + * @license {@link http://www.fsf.org/copyleft/gpl.html GNU public license} + * @link http://xoops.org XOOPS + * @since 1.00 + */ + +include '../../../include/cp_header.php'; +require_once __DIR__ . '/admin_header.php'; + +xoops_cp_header(); +$adminClass = new ModuleAdmin(); + +$countPlugins = $pluginHandler->getCount(); +// get online plugin info +$criteria = new Criteria("plugin_online", 1); +$onlinePluginObjs = $pluginHandler->getAll($criteria); +$countPluginsOnline = (!empty($onlinePluginObjs)) ? count($onlinePluginObjs) : 0; +$onlinePluginArray = array(); +foreach($onlinePluginObjs as $onlineObj) { + $onlinePluginArray[] = $onlineObj->getVar('plugin_name'); +} +natsort($onlinePluginArray); +$onlinePluginNames = implode(", ", $onlinePluginArray); + +// get offline plugin info +$criteria = new Criteria("plugin_online", 0); +$onlinePluginObjs = $pluginHandler->getAll($criteria); +$countPluginsOffline = (!empty($offlinePluginObjs)) ? count($offlinePluginObjs) : 0; +$offlinePluginArray = array(); +foreach($offlinePluginObjs as $offlineObj) { + $offlinePluginArray[] = $offlineObj->getVar('plugin_name'); +} +natsort($offlinePluginArray); +$offlinePluginNames = implode(", ", $offlinePluginArray); + +$adminClass->addInfoBox(_AM_XSITEMAP_MANAGER_INDEX); +// display number of plugins online +$adminClass->addInfoBoxLine(_AM_XSITEMAP_PLUGIN_ONLINE, _AM_XSITEMAP_THEREARE_PLUGIN_ONLINE, $countPluginsOnline, 'green'); +// display number of plugins offline +$adminClass->addInfoBoxLine(_AM_XSITEMAP_PLUGIN_OFFLINE, _AM_XSITEMAP_THEREARE_PLUGIN_OFFLINE, $countPluginsOffline, 'green'); +// display total number of plugins +$adminClass->addInfoBoxLine(_AM_XSITEMAP_INDEX_ADMENU1, _AM_XSITEMAP_THEREARE_PLUGIN, $countPlugins); + +$adminClass->addConfigBoxLine(_AM_XSITEMAP_PLUGIN_ONLINE_NAMES, $onlinePluginNames, '', '', 'information'); +$adminClass->addConfigBoxLine(_AM_XSITEMAP_PLUGIN_OFFLINE_NAMES, $offlinePluginNames, '', '', 'information'); + +$GLOBALS['xoopsTpl']->assign('navigation', $adminClass->addNavigation('index.php')); +$GLOBALS['xoopsTpl']->assign('renderindex', $adminClass->renderIndex()); + +// Call template file +$GLOBALS['xoopsTpl']->display($GLOBALS['xoops']->path("www/modules/{$moduleDirname}/templates/admin/{$moduleDirname}_index.tpl")); + +include __DIR__ . '/admin_footer.php'; Modified: XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/menu.php =================================================================== --- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/menu.php 2016-03-28 10:28:36 UTC (rev 13209) +++ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/menu.php 2016-05-29 20:10:16 UTC (rev 13210) @@ -1,52 +1,58 @@ -<?php -/** - * **************************************************************************** - * Module g\xE9n\xE9r\xE9 par TDMCreate de la TDM "http://www.tdmxoops.net" - * **************************************************************************** - * xsitemap - MODULE FOR XOOPS CMS - * Copyright (c) Urbanspaceman (http://www.takeaweb.it) - * - * You may not change or alter any portion of this comment or credits - * of supporting developers from this source code or any supporting source code - * which is considered copyrighted (c) material of the original comment or credit authors. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * @copyright Urbanspaceman (http://www.takeaweb.it) - * @license GPL - * @package xsitemap - * @author Urbanspaceman (http://www.takeaweb.it) - * - * Version : 1.00: - * **************************************************************************** - */ -defined("XOOPS_ROOT_PATH") or die("XOOPS root path not defined"); - -$dirname = basename(dirname(dirname(__FILE__))); -$module_handler = xoops_gethandler('module'); -$module = $module_handler->getByDirname($dirname); -$pathIcon32 = $module->getInfo('icons32'); - -xoops_loadLanguage('admin', $dirname); - -$adminmenu = array(); -$i = 1; -$adminmenu[$i]["title"] = _MI_XSITEMAP_MANAGER_INDEX; -$adminmenu[$i]["link"] = "admin/index.php"; -$adminmenu[$i]["icon"] = $pathIcon32 . '/home.png'; -++$i; -$adminmenu[$i]["title"] = _MI_XSITEMAP_MANAGER_PLUGIN; -$adminmenu[$i]["link"] = "admin/plugin.php"; -$adminmenu[$i]["icon"] = "assets/images/admin/plugin.png"; -++$i; -$adminmenu[$i]["title"] = _MI_XSITEMAP_MANAGER_XML; -$adminmenu[$i]["link"] = "admin/xml.php"; -$adminmenu[$i]["icon"] = "assets/images/admin/xml.png"; -//++$i; -//$adminmenu[$i]["title"] = _MI_XSITEMAP_MANAGER_PERMISSIONS; -//$adminmenu[$i]["link"] = "admin/permissions.php"; -++$i; -$adminmenu[$i]["title"] = _MI_XSITEMAP_MANAGER_ABOUT; -$adminmenu[$i]["link"] = "admin/about.php"; -$adminmenu[$i]["icon"] = $pathIcon32 . '/about.png'; +<?php +/* + * **************************************************************************** + * Module g\xE9n\xE9r\xE9 par TDMCreate de la TDM "http://www.tdmxoops.net" + * **************************************************************************** + * xsitemap - MODULE FOR XOOPS CMS + * Copyright (c) Urbanspaceman (http://www.takeaweb.it) + * + * You may not change or alter any portion of this comment or credits + * of supporting developers from this source code or any supporting source code + * which is considered copyrighted (c) material of the original comment or credit authors. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + */ +/** + * Module: xSiteMap + * + * @category Module + * @package xSiteMap + * @subpackage admin + * @author XOOPS Module Development Team + * @author {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://xoops.org 2001-2016 XOOPS Project} + * @license {@link http://www.fsf.org/copyleft/gpl.html GNU public license} + * @link http://xoops.org XOOPS + * @since 1.00 + */ + +defined('XOOPS_ROOT_PATH') || exit('Restricted access'); + +$moduleDirname = basename(dirname(__DIR__)); +$module_handler = xoops_gethandler('module'); +$module = $module_handler->getByDirname($moduleDirname); +$pathIcon32 = $module->getInfo('icons32'); + +xoops_loadLanguage('admin', $moduleDirname); + +$adminmenu = array(array('title' => _MI_XSITEMAP_MANAGER_INDEX, + 'link' => "admin/index.php", + 'icon' => "{$pathIcon32}/home.png"), + + array('title' => _MI_XSITEMAP_MANAGER_PLUGIN, + 'link' => "admin/plugin.php", + 'icon' => "assets/images/admin/plugin.png"), + + array('title' => _MI_XSITEMAP_MANAGER_XML, + 'link' => "admin/xml.php", + 'icon' => "assets/images/admin/xml.png"), +/* + array('title' => _MI_XSITEMAP_MANAGER_PERMISSIONS, + 'link'=> "admin/permissions.php"), +*/ + array('title' => _MI_XSITEMAP_MANAGER_ABOUT, + 'link' => "admin/about.php", + 'icon' => "{$pathIcon32}/about.png") +); Modified: XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/plugin.php =================================================================== --- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/plugin.php 2016-03-28 10:28:36 UTC (rev 13209) +++ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/plugin.php 2016-05-29 20:10:16 UTC (rev 13210) @@ -1,184 +1,190 @@ -<?php -/** - * **************************************************************************** - * Module g\xE9n\xE9r\xE9 par TDMCreate de la TDM "http://www.tdmxoops.net" - * **************************************************************************** - * xsitemap - MODULE FOR XOOPS CMS - * Copyright (c) Urbanspaceman (http://www.takeaweb.it) - * - * You may not change or alter any portion of this comment or credits - * of supporting developers from this source code or any supporting source code - * which is considered copyrighted (c) material of the original comment or credit authors. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * @copyright Urbanspaceman (http://www.takeaweb.it) - * @license GPL - * @package xsitemap - * @author Urbanspaceman (http://www.takeaweb.it) - * - * Version : 1.00: - * **************************************************************************** - */ -include '../../../include/cp_header.php'; - -include 'admin_header.php'; - -xoops_cp_header(); -$index_admin = new ModuleAdmin(); - -if (isset($_REQUEST["op"])) { - $op = $_REQUEST["op"]; -} else { - @$op = "show_list_plugin"; -} - -echo $index_admin->addNavigation('plugin.php'); - -switch ($op) { - case "save_plugin": - if ( !$GLOBALS["xoopsSecurity"]->check() ) { - redirect_header("plugin.php", 3, implode(",", $GLOBALS["xoopsSecurity"]->getErrors())); - } - if (isset($_REQUEST["plugin_id"])) { - $obj =& $pluginHandler->get($_REQUEST["plugin_id"]); - } else { - $obj =& $pluginHandler->create(); - } - - //Form plugin_name - $obj->setVar("plugin_name", $_REQUEST["plugin_name"]); - //Form plugin_mod_version - $obj->setVar("plugin_mod_version", $_REQUEST["plugin_mod_version"]); - //Form plugin_mod_table - $obj->setVar("plugin_mod_table", $_REQUEST["plugin_mod_table"]); - //Form plugin_cat_id - $obj->setVar("plugin_cat_id", $_REQUEST["plugin_cat_id"]); - //Form plugin_cat_pid - $obj->setVar("plugin_cat_pid", $_REQUEST["plugin_cat_pid"]); - //Form plugin_cat_name - $obj->setVar("plugin_cat_name", $_REQUEST["plugin_cat_name"]); - //Form plugin_weight - $obj->setVar("plugin_weight", $_REQUEST["plugin_weight"]); - //Form plugin_call - $obj->setVar("plugin_call", $_REQUEST["plugin_call"]); - //Form plugin_submitter - $obj->setVar("plugin_submitter", $_REQUEST["plugin_submitter"]); - //Form plugin_date_created - $obj->setVar("plugin_date_created", strtotime($_REQUEST["plugin_date_created"])); - //Form plugin_online - $verif_plugin_online = ($_REQUEST["plugin_online"] == 1) ? "1" : "0"; - $obj->setVar("plugin_online", $verif_plugin_online); - - if ($pluginHandler->insert($obj)) { - redirect_header("plugin.php?op=show_list_plugin", 2, _AM_XSITEMAP_FORMOK); - } - //include_once("../include/forms.php"); - echo $obj->getHtmlErrors(); - $form =& $obj->getForm(); - break; - - case "edit_plugin": - $obj = $pluginHandler->get($_REQUEST["plugin_id"]); - $form = $obj->getForm(); - break; - - case "delete_plugin": - $obj =& $pluginHandler->get($_REQUEST["plugin_id"]); - if (isset($_REQUEST["ok"]) && $_REQUEST["ok"] == 1) { - if ( !$GLOBALS["xoopsSecurity"]->check() ) { - redirect_header("plugin.php", 3, implode(",", $GLOBALS["xoopsSecurity"]->getErrors())); - } - if ($pluginHandler->delete($obj)) { - redirect_header("plugin.php", 3, _AM_XSITEMAP_FORMDELOK); - } else { - echo $obj->getHtmlErrors(); - } - } else { - xoops_confirm(array("ok" => 1, "plugin_id" => $_REQUEST["plugin_id"], "op" => "delete_plugin"), $_SERVER["REQUEST_URI"], sprintf(_AM_XSITEMAP_FORMSUREDEL, $obj->getVar("plugin"))); - } - break; - - case "update_online_plugin": - - if (isset($_REQUEST["plugin_id"])) { - $obj =& $pluginHandler->get($_REQUEST["plugin_id"]); - } - $obj->setVar("plugin_online", $_REQUEST["plugin_online"]); - - if ($pluginHandler->insert($obj)) { - redirect_header("plugin.php", 3, _AM_XSITEMAP_FORMOK); - } - echo $obj->getHtmlErrors(); - - break; - - case "default": - default: - - $criteria = new CriteriaCompo(); - $criteria->setSort("plugin_name"); - $criteria->setOrder("ASC"); - $numrows = $pluginHandler->getCount(); - $plugin_arr = $pluginHandler->getall($criteria); - - //Affichage du tableau - if ($numrows>0) { - echo "<table width=\"100%\" cellspacing=\"1\" class=\"outer\"> - <tr> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_NAME."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_MOD_VERSION."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_MOD_TABLE_SHORT."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_CAT_ID_SHORT."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_CAT_PID_SHORT."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_CAT_NAME_SHORT."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_WEIGHT_SHORT."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_CALL_SHORT."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_SUBMITTER."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_DATE_CREATED."</th> - <th align=\"center\">"._AM_XSITEMAP_PLUGIN_ONLINE."</th> - - <th align=\"center\" width=\"10%\">"._AM_XSITEMAP_FORMACTION."</th> - </tr>"; - - $class = "odd"; - - foreach (array_keys($plugin_arr) as $i) { - if ( $plugin_arr[$i]->getVar("topic_pid") == 0) { - echo "<tr class=\"".$class."\">"; - $class = ($class == "even") ? "odd" : "even"; - echo "<td align=\"center\">".$plugin_arr[$i]->getVar("plugin_name")."</td>"; - echo "<td align=\"center\">".$plugin_arr[$i]->getVar("plugin_mod_version")."</td>"; - echo "<td align=\"center\">".$plugin_arr[$i]->getVar("plugin_mod_table")."</td>"; - echo "<td align=\"center\">".$plugin_arr[$i]->getVar("plugin_cat_id")."</td>"; - echo "<td align=\"center\">".$plugin_arr[$i]->getVar("plugin_cat_pid")."</td>"; - echo "<td align=\"center\">".$plugin_arr[$i]->getVar("plugin_cat_name")."</td>"; - echo "<td align=\"center\">".$plugin_arr[$i]->getVar("plugin_weight")."</td>"; - echo "<td align=\"center\">".$plugin_arr[$i]->getVar("plugin_call")."</td>"; - echo "<td align=\"center\">".XoopsUser::getUnameFromId($plugin_arr[$i]->getVar("plugin_submitter"),"S")."</td>"; - echo "<td align=\"center\">".formatTimeStamp($plugin_arr[$i]->getVar("plugin_date_created"),"S")."</td>"; - - $online = $plugin_arr[$i]->getVar("plugin_online"); - - if ($online == 1) { - echo "<td align=\"center\"><a href=\"./plugin.php?op=update_online_plugin&plugin_id=".$plugin_arr[$i]->getVar("plugin_id")."&plugin_online=0\"><img src=\"./../assets/images/icons/on.png\" border=\"0\" alt=\""._AM_XSITEMAP_ON."\" title=\""._AM_XSITEMAP_ON."\"></a></td>"; - } else { - echo "<td align=\"center\"><a href=\"./plugin.php?op=update_online_plugin&plugin_id=".$plugin_arr[$i]->getVar("plugin_id")."&plugin_online=1\"><img src=\"./../assets/images/icons/off.png\" border=\"0\" alt=\""._AM_XSITEMAP_OFF."\" title=\""._AM_XSITEMAP_OFF."\"></a></td>"; - } - echo "<td align=\"center\" width=\"10%\"> - <a href=\"plugin.php?op=edit_plugin&plugin_id=".$plugin_arr[$i]->getVar("plugin_id")."\"><img src=\"../assets/images/icons/edit.png\" alt=\""._AM_XSITEMAP_EDIT."\" title=\""._AM_XSITEMAP_EDIT."\"></a> - <a href=\"plugin.php?op=delete_plugin&plugin_id=".$plugin_arr[$i]->getVar("plugin_id")."\"><img src=\"../assets/images/icons/delete.png\" alt=\""._AM_XSITEMAP_DELETE."\" title=\""._AM_XSITEMAP_DELETE."\"></a> - </td>"; - echo "</tr>"; - } - } - echo "</table><br><br>"; - } - - // Affichage du formulaire - $obj =& $pluginHandler->create(); - $form = $obj->getForm(); -} - -include 'admin_footer.php'; +<?php +/* + * **************************************************************************** + * Module g\xE9n\xE9r\xE9 par TDMCreate de la TDM "http://www.tdmxoops.net" + * **************************************************************************** + * xsitemap - MODULE FOR XOOPS CMS + * Copyright (c) Urbanspaceman (http://www.takeaweb.it) + * + * You may not change or alter any portion of this comment or credits + * of supporting developers from this source code or any supporting source code + * which is considered copyrighted (c) material of the original comment or credit authors. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + */ +/** + * Module: xSiteMap + * + * @category Module + * @package xSiteMap + * @subpackage admin + * @author {@link http://www.takeaweb.it Urbanspaceman} + * @author XOOPS Module Development Team + * @copyright {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://xoops.org 2001-2016 XOOPS Project} + * @license {@link http://www.fsf.org/copyleft/gpl.html GNU public license} + * @link http://xoops.org XOOPS + * @since 1.00 + */ + +include '../../../include/cp_header.php'; + +include __DIR__ . '/admin_header.php'; + +xoops_cp_header(); +$adminClass = new ModuleAdmin(); + +$op = XoopsRequest::getCmd('op', 'show_list_plugin'); + +echo $adminClass->addNavigation('plugin.php'); + +switch ($op) { + case 'save_plugin': + if (!$GLOBALS["xoopsSecurity"]->check()) { + redirect_header("plugin.php", 3, implode(",", $GLOBALS["xoopsSecurity"]->getErrors())); + } + $pluginId = XoopsRequest::getInt('plugin_id', 0); + if (!empty($pluginId)) { + $obj = $pluginHandler->get($pluginId); + if (!$obj instanceof XsitemapPlugin) { // passed Id for non-existent plugin so create new plugin + $obj = $pluginHandler->create(); + } + } else { + $obj = $pluginHandler->create(); + } + + $verif_plugin_online = (1 == XoopsRequest::getInt('plugin_online')) ? 1 : 0; //Form plugin_online + $obj->setVars(array('plugin_name' => XoopsRequest::getString('plugin_name', ''), //Form plugin_name + 'plugin_mod_version' => XoopsRequest::getString('plugin_mod_version', ''), //Form plugin_mod_version + 'plugin_mod_table' => XoopsRequest::getString('plugin_mod_table', ''), //Form plugin_mod_table + 'plugin_cat_id' => XoopsRequest::getInt('plugin_cat_id', 0), //Form plugin_cat_id + 'plugin_cat_pid' => XoopsRequest::getInt('plugin_cat_pid', 0), //Form plugin_cat_pid + 'plugin_cat_name' => XoopsRequest::getText('plugin_cat_name', ''), //Form plugin_cat_name + 'plugin_weight' => XoopsRequest::getInt('plugin_weight', 0), //Form plugin_weight + 'plugin_call' => XoopsRequest::getString('plugin_call', ''), //Form plugin_call + 'plugin_submitter' => XoopsRequest::getInt('plugin_submitter', 0), //Form plugin_submitter + 'plugin_date_created' => XoopsRequest::getInt('plugin_date_created', 0), //Form plugin_date_created + 'plugin_online' => $verif_plugin_online) //Form plugin_online + ); + + if ($pluginHandler->insert($obj)) { + redirect_header("plugin.php?op=show_list_plugin", 2, _AM_XSITEMAP_FORMOK); + } + //include_once("../include/forms.php"); + echo $obj->getHtmlErrors(); + $form = $obj->getForm(); + break; + + case "edit_plugin": + $obj = $pluginHandler->get(XoopsRequest::getInt('plugin_id')); + if ($obj instanceof XsitemapPlugin) { + $form = $obj->getForm(); + } else { + //@todo: move hard coded language string to language file + echo "Could not load plugin"; + } + break; + + case "delete_plugin": + $obj = $pluginHandler->get(XoopsRequest::getInt('plugin_id', 0)); + $ok = XoopsRequest::getInt('ok', 0, 'POST'); + if (1 == $ok) { +// if (isset($_REQUEST["ok"]) && $_REQUEST["ok"] == 1) { + if (!$GLOBALS["xoopsSecurity"]->check()) { + redirect_header("plugin.php", 3, implode(",", $GLOBALS["xoopsSecurity"]->getErrors())); + } + if ($pluginHandler->delete($obj)) { + redirect_header("plugin.php", 3, _AM_XSITEMAP_FORMDELOK); + } else { + echo $obj->getHtmlErrors(); + } + } else { + xoops_confirm(array("ok" => 1, "plugin_id" => XoopsRequest::getInt('plugin_id', 0), "op" => "delete_plugin"), $_SERVER["REQUEST_URI"], sprintf(_AM_XSITEMAP_FORMSUREDEL, $obj->getVar("plugin"))); + } + break; + + case "update_online_plugin": + + if (isset($_REQUEST['plugin_id'])) { + $obj = $pluginHandler->get(XoopsRequest::getInt('plugin_id')); + } + $obj->setVar("plugin_online", XoopsRequest::getInt('plugin_online', 0)); + + if ($pluginHandler->insert($obj)) { + redirect_header('plugin.php', 3, _AM_XSITEMAP_FORMOK); + } + echo $obj->getHtmlErrors(); + + break; + + case "default": + default: + + $criteria = new CriteriaCompo(); + $criteria->setSort("plugin_name"); + $criteria->setOrder("ASC"); + $numrows = $pluginHandler->getCount(); + $plugin_arr = $pluginHandler->getAll($criteria); + + //Display the table + if ($numrows > 0) { + echo "<table cellspacing='1' class='outer width100'>\n" + . " <thead>\n" + . " <tr>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_NAME . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_MOD_VERSION . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_MOD_TABLE_SHORT . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_CAT_ID_SHORT . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_CAT_PID_SHORT . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_CAT_NAME_SHORT . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_WEIGHT_SHORT . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_CALL_SHORT . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_SUBMITTER . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_DATE_CREATED . "</th>\n" + . " <th class='txtcenter'>" . _AM_XSITEMAP_PLUGIN_ONLINE . "</th>\n" + . " <th class='txtcenter width10'>" . _AM_XSITEMAP_FORMACTION . "</th>\n" + . " </tr>\n" + . " </thead>\n"; + + $class = "odd"; + + foreach (array_keys($plugin_arr) as $i) { + if (0 == $plugin_arr[$i]->getVar("topic_pid")) { + echo " <tr class='{$class}'>\n"; + $class = ($class == "even") ? "odd" : "even"; + echo " <td class='txtcenter'>" . $plugin_arr[$i]->getVar("plugin_name") . "</td>\n" + . " <td class='txtcenter'>" . $plugin_arr[$i]->getVar("plugin_mod_version") . "</td>\n" + . " <td class='txtcenter'>" . $plugin_arr[$i]->getVar("plugin_mod_table") . "</td>\n" + . " <td class='txtcenter'>" . $plugin_arr[$i]->getVar("plugin_cat_id") . "</td>\n" + . " <td class='txtcenter'>" . $plugin_arr[$i]->getVar("plugin_cat_pid") . "</td>\n" + . " <td class='txtcenter'>" . $plugin_arr[$i]->getVar("plugin_cat_name") . "</td>\n" + . " <td class='txtcenter'>" . $plugin_arr[$i]->getVar("plugin_weight") . "</td>\n" + . " <td class='txtcenter'>" . $plugin_arr[$i]->getVar("plugin_call") . "</td>\n" + . " <td class='txtcenter'>" . XoopsUser::getUnameFromId($plugin_arr[$i]->getVar("plugin_submitter"),"S") . "</td>\n" + . " <td class='txtcenter'>" . formatTimeStamp($plugin_arr[$i]->getVar("plugin_date_created"),"S") . "</td>\n"; + + $online = $plugin_arr[$i]->getVar("plugin_online"); + + if (1 == $online) { + echo " <td class='txtcenter'><a href='./plugin.php?op=update_online_plugin&plugin_id=" . $plugin_arr[$i]->getVar("plugin_id") . "&plugin_online=0'><img src='./../assets/images/icons/on.png' border='0' alt='" . _AM_XSITEMAP_ON . "' title='" . _AM_XSITEMAP_ON . "'></a></td>\n"; + } else { + echo " <td class='txtcenter'><a href='./plugin.php?op=update_online_plugin&plugin_id=" . $plugin_arr[$i]->getVar("plugin_id") . "&plugin_online=1'><img src='./../assets/images/icons/off.png' border='0' alt='" . _AM_XSITEMAP_OFF . "' title='" . _AM_XSITEMAP_OFF . "'></a></td>\n"; + } + echo " <td class='txtcenter width10'>\n" + . " <a href='plugin.php?op=edit_plugin&plugin_id=" . $plugin_arr[$i]->getVar("plugin_id") . "'><img src='../assets/images/icons/edit.png' alt='" . _EDIT . "' title='" . _EDIT . "'></a>\n" + . " <a href='plugin.php?op=delete_plugin&plugin_id=" . $plugin_arr[$i]->getVar("plugin_id") . "'><img src='../assets/images/icons/delete.png' alt='" . _DELETE . "' title='" . _DELETE . "'></a>\n" + . " </td>\n" + . " </tr>\n"; + } + } + echo "</table><br><br>\n"; + } + + // Display the form + $obj = $pluginHandler->create(); + $form = $obj->getForm(); + break; +} + +include __DIR__ . '/admin_footer.php'; Modified: XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/xml.php =================================================================== --- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/xml.php 2016-03-28 10:28:36 UTC (rev 13209) +++ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/admin/xml.php 2016-05-29 20:10:16 UTC (rev 13210) @@ -1,67 +1,71 @@ -<?php -/** - * **************************************************************************** - * Module g\xE9n\xE9r\xE9 par TDMCreate de la TDM "http://www.tdmxoops.net" - * **************************************************************************** - * xsitemap - MODULE FOR XOOPS CMS - * Copyright (c) Urbanspaceman (http://www.takeaweb.it) - * - * You may not change or alter any portion of this comment or credits - * of supporting developers from this source code or any supporting source code - * which is considered copyrighted (c) material of the original comment or credit authors. - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - * @copyright Urbanspaceman (http://www.takeaweb.it) - * @license GPL - * @package xsitemap - * @author Urbanspaceman (http://www.takeaweb.it) - * - * Version : 1.00: - * **************************************************************************** - */ - -include '../../../include/cp_header.php'; - -//xoops_cp_header(); -include 'admin_header.php'; -xoops_cp_header(); - -$index_admin = new ModuleAdmin(); - -include_once(XOOPS_ROOT_PATH . "/class/tree.php"); -include_once XOOPS_ROOT_PATH."/modules/xsitemap/class/plugin.php"; -include_once XOOPS_ROOT_PATH."/modules/xsitemap/include/functions.php"; -include_once(XOOPS_ROOT_PATH . "/modules/xsitemap/class/xsitemap_class.php"); - -echo $index_admin->addNavigation('xml.php'); - -$xmlfile = XOOPS_ROOT_PATH."/xsitemap.xml"; -$stat = stat($xmlfile); -$last_mod = date("d-m-Y H:i:s",$stat['mtime']); -//if ( is_readable( $xmlfile ) ) { - -echo "<div style=\"padding: 8px;\">"; - - echo ""._AM_XSITEMAP_XML_LASTUPD." ".$last_mod; - echo "<br/>"; - echo "<br/>"; - echo ""._AM_XSITEMAP_UPDATE_XML.""; - echo "<br/>"; - echo "<br/>"; - echo "<form action=xml.php method=post> - <input type=submit name=update value="._AM_XSITEMAP_MANAGER_UPDATE."> - </form><br/>"; - if (isset($_POST['update'])) { - xsitemap_xml_admin(); - } - echo "</div> - <br clear=\"all\" />"; -/* -$site_url = UrlEncode(XOOPS_URL."/modules/xsitemap/xsitemap.xml"); -echo "<div>"; -echo "invia la sitemap a google <a href='http://www.google.com/webmasters/tools/ping?sitemap=".$site_url."'>CLICCA</a>"; -echo "</div>";*/ -//} -include 'admin_footer.php'; +<?php +/* + * **************************************************************************** + * Module g\xE9n\xE9r\xE9 par TDMCreate de la TDM "http://www.tdmxoops.net" + * **************************************************************************** + * xsitemap - MODULE FOR XOOPS CMS + * Copyright (c) Urbanspaceman (http://www.takeaweb.it) + * + * You may not change or alter any portion of this comment or credits + * of supporting developers from this source code or any supporting source code + * which is considered copyrighted (c) material of the original comment or credit authors. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + */ +/** + * Module: xSiteMap + * + * @category Module + * @package xSiteMap + * @subpackage admin + * @author XOOPS Module Development Team + * @author {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://www.takeaweb.it Urbanspaceman} + * @copyright {@link http://xoops.org 2001-2016 XOOPS Project} + * @license {@link http://www.fsf.org/copyleft/gpl.html GNU public license} + * @link http://xoops.org XOOPS + * @since 1.00 + */ + +include '../../../include/cp_header.php'; +include __DIR__ . '/admin_header.php'; +xoops_cp_header(); + +$index_admin = new ModuleAdmin(); + +include_once $GLOBALS['xoops']->path("/class/tree.php"); +include_once $GLOBALS['xoops']->path("/modules/xsitemap/class/plugin.php"); +include_once $GLOBALS['xoops']->path("/modules/xsitemap/include/functions.php"); +include_once $GLOBALS['xoops']->path("/modules/xsitemap/class/xsitemap_class.php"); + +echo $index_admin->addNavigation('xml.php'); + +$xmlfile = $GLOBALS['xoops']->path("/xsitemap.xml"); +$stat = stat($xmlfile); +$last_mod = date("d-m-Y H:i:s", $stat['mtime']); +//if (is_readable( $xmlfile)) { + +echo "<div style='padding: 8px;'>\n" + . "" . _AM_XSITEMAP_XML_LASTUPD . " {$last_mod}\n" + . "<br>\n" + . "<br>\n" + . "" . _AM_XSITEMAP_UPDATE_XML . "\n" + . "<br>\n" + . "<br>\n" + . "<form action=xml.php method=post>\n" + . " <input type='submit' name='update' value='" . _AM_XSITEMAP_MANAGER_UPDATE . "'>\n" + . "</form>\n" + . "<br>\n"; +if (isset($_POST['update'])) { + xsitemap_xml_admin(); +} +echo "</div>\n" + . "<br class='clear'>\n"; +/* +$site_url = UrlEncode(XOOPS_URL."/modules/xsitemap/xsitemap.xml"); +echo "<div>"; +echo "invia la sitemap a google <a href='http://www.google.com/webmasters/tools/ping?sitemap=".$site_url."'>CLICCA</a>"; +echo "</div>";*/ +//} +include __DIR__ . '/admin_footer.php'; Added: XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/assets/css/style.css =================================================================== --- XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/assets/css/style.css (rev 0) +++ XoopsModules/modulepacks/x257basicmodulepack/branches/zyspec/xsitemap/assets/css/style.css 2016-05-29 20:10:16 UTC (rev 13210) @@ -0,0 +1,278 @@ +/* ------------------------------------------------------------ + Reset Styles (from meyerweb.com) +------------------------------------------------------------ */ + +.sitemap ul, .sitemap li{ + margin: 0; + padding: 0; + border: 0; + outline: 0; + font-weight: inherit; + font-style: inherit; + font-size: 100%; + font-family: inherit; + vertical-align: baseline; + list-style-type:none; +} + +/* ------------------------------------------------------------ + NUMBER OF COLUMNS: Adjust #primaryNav li to set the number + of columns required in your site map. The default is + 4 columns (25%). 5 columns would be 20%, 6 columns would + be 16.6%, etc. +------------------------------------------------------------ */ + +#primaryNav li { + width:25%; +} + +#primaryNav li ul li { + width:100% !important; +} + +#primaryNav.col1 li { width:99.9%; } +#primaryNav.col2 li { width:50.0%; } +#primaryNav.col3 li { width:33.3%; } +#primaryNav.col4 li { width:25.0%; } +#primaryNav.col5 li { width:20.0%; } +#primaryNav.col6 li { width:16.6%; } +#primaryNav.col7 li { width:14.2%; } +#primaryNav.col8 li { width:12.5%; } +#primaryNav.col9 li { width:11.1%; } +#primaryNav.col10 li { width:10.0%; } +#primaryNav.col11 li { width:9.0%; } +#primaryNav.col12 li { width:8.0%; } +#primaryNav.col13 li { width:7.0%; } +#primaryNav.col14 li { width:6.0%; } + +/* ------------------------------------------------------------ + General Styles +------------------------------------------------------------ */ + +.sitemap { + margin: 0px 0 40px 0; + float: left; + width: 98%; + background-color:#fff; + padding:10px; +} + +.sitemap ul{ + list-style: none !important; +} + + +h1 { + font-weight: bold; + text-transform: uppercase; + font-size: 20px; + margin: 0 0 5px 0; +} +h2 { + font-family: "Lucida Grande", Verdana, sans-serif; + font-size: 10px; + color: #777777; + margin: 0 0 20px 0; +} +a { + text-decoration: none; +} +ol, ul, li { + list-style: none; +} + + +/* ------------------------------------------------------------ + Site Map Styles +------------------------------------------------------------ */ + +/* -------- Top Level --------- */ + +#primaryNav { + margin: 0; + float: left; + width: 100%; +} +#primaryNav #home { + display: block; + float: none; + background: #ffffff url('assets/images/L1-left.png') center bottom no-repeat; + position: relative; + z-index: 2; + padding: 0 0 30px 0; +} +#primaryNav li { + float: left; + background: url('assets/images/L1-center.png') center top no-repeat; + padding: 30px 0; + margin-top: -30px; +} +#primaryNav li a { + margin: 0 20px 0 0; + padding: 10px 0; + display: block; + font-size: 14px; + font-weight: bold; + text-align: center; + color: black; + background: #c3eafb url('assets/images/white-highlight.png') top left repeat-x; + border: 2px solid #b5d9ea; + -moz-border-radius: 10px 0px 10px 0px; + -webkit-border-radius: 10px 0px 10px 0px; + -webkit-box-shadow: rgba(0,0,0,0.5) 2px 2px 2px; + -moz-box-shadow: rgba(0,0,0,0.5) 2px 2px 2px; /* FF 3.5+ */ +} +#primaryNav li a:hover { + background-color: #e2f4fd; + border-color: #97bdcf; +} +#primaryNav li:last-child { + background: url('assets/images/L1-right.png') center ... [truncated message content] |