|
From: <be...@us...> - 2013-09-29 10:23:14
|
Revision: 12106
http://sourceforge.net/p/xoops/svn/12106
Author: beckmi
Date: 2013-09-29 10:23:10 +0000 (Sun, 29 Sep 2013)
Log Message:
-----------
Updating to 0.73 Beta 1
Modified Paths:
--------------
XoopsModules/latestnews/trunk/latestnews/admin/admin.php
XoopsModules/latestnews/trunk/latestnews/admin/header.php
XoopsModules/latestnews/trunk/latestnews/admin/menu.php
XoopsModules/latestnews/trunk/latestnews/blocks/latestnews.php
XoopsModules/latestnews/trunk/latestnews/class/class.latestnews.php
XoopsModules/latestnews/trunk/latestnews/docs/changelog.txt
XoopsModules/latestnews/trunk/latestnews/images/latestnews_logo.png
XoopsModules/latestnews/trunk/latestnews/include/blocksadmin.inc.php
XoopsModules/latestnews/trunk/latestnews/include/functions.php
XoopsModules/latestnews/trunk/latestnews/include/gtickets.php
XoopsModules/latestnews/trunk/latestnews/include/onupdate.inc.php
XoopsModules/latestnews/trunk/latestnews/include/updateblock.inc.php
XoopsModules/latestnews/trunk/latestnews/language/arabic/blocks.php
XoopsModules/latestnews/trunk/latestnews/language/arabic/main.php
XoopsModules/latestnews/trunk/latestnews/language/arabic/modinfo.php
XoopsModules/latestnews/trunk/latestnews/language/danish/blocks.php
XoopsModules/latestnews/trunk/latestnews/language/danish/main.php
XoopsModules/latestnews/trunk/latestnews/language/danish/modinfo.php
XoopsModules/latestnews/trunk/latestnews/language/english/blocks.php
XoopsModules/latestnews/trunk/latestnews/language/english/main.php
XoopsModules/latestnews/trunk/latestnews/language/english/modinfo.php
XoopsModules/latestnews/trunk/latestnews/language/french/blocks.php
XoopsModules/latestnews/trunk/latestnews/language/french/main.php
XoopsModules/latestnews/trunk/latestnews/language/french/modinfo.php
XoopsModules/latestnews/trunk/latestnews/language/persian/blocks.php
XoopsModules/latestnews/trunk/latestnews/language/persian/main.php
XoopsModules/latestnews/trunk/latestnews/language/persian/modinfo.php
XoopsModules/latestnews/trunk/latestnews/language/polish/blocks.php
XoopsModules/latestnews/trunk/latestnews/language/polish/main.php
XoopsModules/latestnews/trunk/latestnews/language/polish/modinfo.php
XoopsModules/latestnews/trunk/latestnews/language/portuguesebr/blocks.php
XoopsModules/latestnews/trunk/latestnews/language/portuguesebr/main.php
XoopsModules/latestnews/trunk/latestnews/language/portuguesebr/modinfo.php
XoopsModules/latestnews/trunk/latestnews/language/spanish/blocks.php
XoopsModules/latestnews/trunk/latestnews/language/spanish/main.php
XoopsModules/latestnews/trunk/latestnews/language/spanish/modinfo.php
XoopsModules/latestnews/trunk/latestnews/xoops_version.php
Added Paths:
-----------
XoopsModules/latestnews/trunk/latestnews/admin/about.php
XoopsModules/latestnews/trunk/latestnews/admin/admin_footer.php
XoopsModules/latestnews/trunk/latestnews/admin/admin_header.php
XoopsModules/latestnews/trunk/latestnews/admin/blockform.php
XoopsModules/latestnews/trunk/latestnews/admin/blocksadmin.php
XoopsModules/latestnews/trunk/latestnews/admin/index.php
XoopsModules/latestnews/trunk/latestnews/admin/permissions.php
XoopsModules/latestnews/trunk/latestnews/class/xoopstree.php
XoopsModules/latestnews/trunk/latestnews/docs/credits.txt
XoopsModules/latestnews/trunk/latestnews/docs/install.txt
XoopsModules/latestnews/trunk/latestnews/docs/lang_diff.txt
XoopsModules/latestnews/trunk/latestnews/docs/license.txt
XoopsModules/latestnews/trunk/latestnews/language/arabic/help/
XoopsModules/latestnews/trunk/latestnews/language/arabic/help/help.html
XoopsModules/latestnews/trunk/latestnews/language/arabic/help/index.html
XoopsModules/latestnews/trunk/latestnews/language/danish/help/
XoopsModules/latestnews/trunk/latestnews/language/danish/help/help.html
XoopsModules/latestnews/trunk/latestnews/language/danish/help/index.html
XoopsModules/latestnews/trunk/latestnews/language/english/admin.php
XoopsModules/latestnews/trunk/latestnews/language/english/help/
XoopsModules/latestnews/trunk/latestnews/language/english/help/help.html
XoopsModules/latestnews/trunk/latestnews/language/english/help/index.html
XoopsModules/latestnews/trunk/latestnews/language/french/help/
XoopsModules/latestnews/trunk/latestnews/language/french/help/help.html
XoopsModules/latestnews/trunk/latestnews/language/french/help/index.html
XoopsModules/latestnews/trunk/latestnews/language/persian/help/
XoopsModules/latestnews/trunk/latestnews/language/persian/help/help.html
XoopsModules/latestnews/trunk/latestnews/language/persian/help/index.html
XoopsModules/latestnews/trunk/latestnews/language/polish/help/
XoopsModules/latestnews/trunk/latestnews/language/polish/help/help.html
XoopsModules/latestnews/trunk/latestnews/language/polish/help/index.html
XoopsModules/latestnews/trunk/latestnews/language/portuguesebr/help/
XoopsModules/latestnews/trunk/latestnews/language/portuguesebr/help/help.html
XoopsModules/latestnews/trunk/latestnews/language/portuguesebr/help/index.html
XoopsModules/latestnews/trunk/latestnews/language/spanish/help/
XoopsModules/latestnews/trunk/latestnews/language/spanish/help/help.html
XoopsModules/latestnews/trunk/latestnews/language/spanish/help/index.html
XoopsModules/latestnews/trunk/latestnews/templates/blocks/block_latestnews.tpl
Removed Paths:
-------------
XoopsModules/latestnews/trunk/latestnews/admin/myblockform.php
XoopsModules/latestnews/trunk/latestnews/admin/myblocksadmin.php
XoopsModules/latestnews/trunk/latestnews/admin/myblocksadmin2.php
XoopsModules/latestnews/trunk/latestnews/admin/mygroupperm.php
XoopsModules/latestnews/trunk/latestnews/admin/mygrouppermform.php
XoopsModules/latestnews/trunk/latestnews/templates/blocks/block_latestnews.html
Added: XoopsModules/latestnews/trunk/latestnews/admin/about.php
===================================================================
--- XoopsModules/latestnews/trunk/latestnews/admin/about.php (rev 0)
+++ XoopsModules/latestnews/trunk/latestnews/admin/about.php 2013-09-29 10:23:10 UTC (rev 12106)
@@ -0,0 +1,30 @@
+<?php
+/*
+ * 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 GNU GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
+ * @package
+ * @since
+ * @author XOOPS Development Team
+ * @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';
Property changes on: XoopsModules/latestnews/trunk/latestnews/admin/about.php
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Author Date Id Rev URL
\ No newline at end of property
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: XoopsModules/latestnews/trunk/latestnews/admin/admin.php
===================================================================
--- XoopsModules/latestnews/trunk/latestnews/admin/admin.php 2013-09-29 09:28:39 UTC (rev 12105)
+++ XoopsModules/latestnews/trunk/latestnews/admin/admin.php 2013-09-29 10:23:10 UTC (rev 12106)
@@ -41,121 +41,119 @@
// include "../../mainfile.php"; GIJ
//include XOOPS_ROOT_PATH."/include/cp_functions.php";
require("header.php");
-include_once XOOPS_ROOT_PATH."/class/xoopsmodule.php";
+include_once XOOPS_ROOT_PATH."/kernel/module.php";
include_once "../include/gtickets.php" ;// GIJ
$admintest = 0;
if (is_object($xoopsUser)) {
- $xoopsModule =& XoopsModule::getByDirname("system");
- if ( !$xoopsUser->isAdmin($xoopsModule->mid()) ) {
- redirect_header(XOOPS_URL.'/user.php',3,_NOPERM);
- exit();
- }
- $admintest=1;
+ $xoopsModule =& XoopsModule::getByDirname("system");
+ if ( !$xoopsUser->isAdmin($xoopsModule->mid()) ) {
+ redirect_header(XOOPS_URL.'/user.php',3,_NOPERM);
+ exit();
+ }
+ $admintest=1;
} else {
- redirect_header(XOOPS_URL.'/user.php',3,_NOPERM);
- exit();
+ redirect_header(XOOPS_URL.'/user.php',3,_NOPERM);
+ exit();
}
// include system category definitions
include_once XOOPS_ROOT_PATH."/modules/system/constants.php";
$error = false;
if ($admintest != 0) {
- if (isset($fct) && $fct != '') {
- if (file_exists(XOOPS_ROOT_PATH."/modules/system/admin/".$fct."/xoops_version.php")) {
+ if (isset($fct) && $fct != '') {
+ if (file_exists(XOOPS_ROOT_PATH."/modules/system/admin/".$fct."/xoops_version.php")) {
- if ( file_exists(XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin.php") ) {
- include XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin.php";
- } else {
- include XOOPS_ROOT_PATH."/modules/system/language/english/admin.php";
- }
+ if ( file_exists(XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin.php") ) {
+ include XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin.php";
+ } else {
+ include XOOPS_ROOT_PATH."/modules/system/language/english/admin.php";
+ }
- if (file_exists(XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin/".$fct.".php")) {
- include XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin/".$fct.".php";
- } elseif (file_exists(XOOPS_ROOT_PATH."/modules/system/language/english/admin/".$fct.".php")) {
- include XOOPS_ROOT_PATH."/modules/system/language/english/admin/".$fct.".php";
- }
- include XOOPS_ROOT_PATH."/modules/system/admin/".$fct."/xoops_version.php";
- $sysperm_handler =& xoops_gethandler('groupperm');
- $category = !empty($modversion['category']) ? intval($modversion['category']) : 0;
- unset($modversion);
- if ($category > 0) {
- $groups = $xoopsUser->getGroups();
- if (in_array(XOOPS_GROUP_ADMIN, $groups) || false != $sysperm_handler->checkRight('system_admin', $category, $groups, $xoopsModule->getVar('mid'))){
+ if (file_exists(XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin/".$fct.".php")) {
+ include XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin/".$fct.".php";
+ } elseif (file_exists(XOOPS_ROOT_PATH."/modules/system/language/english/admin/".$fct.".php")) {
+ include XOOPS_ROOT_PATH."/modules/system/language/english/admin/".$fct.".php";
+ }
+ include XOOPS_ROOT_PATH."/modules/system/admin/".$fct."/xoops_version.php";
+ $sysperm_handler =& xoops_gethandler('groupperm');
+ $category = !empty($modversion['category']) ? intval($modversion['category']) : 0;
+ unset($modversion);
+ if ($category > 0) {
+ $groups = $xoopsUser->getGroups();
+ if (in_array(XOOPS_GROUP_ADMIN, $groups) || false != $sysperm_handler->checkRight('system_admin', $category, $groups, $xoopsModule->getVar('mid'))) {
// if (file_exists(XOOPS_ROOT_PATH."/modules/system/admin/".$fct."/main.php")) {
// include_once XOOPS_ROOT_PATH."/modules/system/admin/".$fct."/main.php"; GIJ
- if (file_exists("../include/{$fct}.inc.php")) {
- include_once "../include/{$fct}.inc.php" ;
- } else {
- $error = true;
- }
- } else {
- $error = true;
- }
- } elseif ($fct == 'version') {
- if (file_exists(XOOPS_ROOT_PATH."/modules/system/admin/version/main.php")) {
- include_once XOOPS_ROOT_PATH."/modules/system/admin/version/main.php";
- } else {
- $error = true;
- }
- } else {
- $error = true;
- }
- } else {
- $error = true;
- }
- } else {
- $error = true;
- }
+ if (file_exists("../include/{$fct}.inc.php")) {
+ include_once "../include/{$fct}.inc.php" ;
+ } else {
+ $error = true;
+ }
+ } else {
+ $error = true;
+ }
+ } elseif ($fct == 'version') {
+ if (file_exists(XOOPS_ROOT_PATH."/modules/system/admin/version/main.php")) {
+ include_once XOOPS_ROOT_PATH."/modules/system/admin/version/main.php";
+ } else {
+ $error = true;
+ }
+ } else {
+ $error = true;
+ }
+ } else {
+ $error = true;
+ }
+ } else {
+ $error = true;
+ }
}
if (false != $error) {
- xoops_cp_header();
+ xoops_cp_header();
mytabs_adminmenu(1);
- echo "<h4>System Configuration</h4>";
- echo '<table class="outer" cellpadding="4" cellspacing="1">';
- echo '<tr>';
- $groups = $xoopsUser->getGroups();
- $all_ok = false;
- if (!in_array(XOOPS_GROUP_ADMIN, $groups)) {
- $sysperm_handler =& xoops_gethandler('groupperm');
- $ok_syscats = $sysperm_handler->getItemIds('system_admin', $groups);
- } else {
- $all_ok = true;
- }
- $admin_dir = XOOPS_ROOT_PATH."/modules/system/admin";
- $handle = opendir($admin_dir);
- $counter = 0;
- $class = 'even';
- while ($file = readdir($handle)) {
- if (strtolower($file) != 'cvs' && !preg_match("/[.]/", $file) && is_dir($admin_dir.'/'.$file)) {
- include $admin_dir.'/'.$file.'/xoops_version.php';
- if ($modversion['hasAdmin']) {
- $category = isset($modversion['category']) ? intval($modversion['category']) : 0;
- if (false != $all_ok || in_array($modversion['category'], $ok_syscats)) {
- echo "<td class='$class' align='center' valign='bottom' width='19%'>";
- echo "<a href='".XOOPS_URL."/modules/system/admin.php?fct=".$file."'><b>" .trim($modversion['name'])."</b></a>\n";
- echo "</td>";
- $counter++;
- $class = ($class == 'even') ? 'odd' : 'even';
- }
- if ( $counter > 4 ) {
- $counter = 0;
- echo "</tr>";
- echo "<tr>";
- }
- }
- unset($modversion);
- }
- }
- while ($counter < 5) {
- echo '<td class="'.$class.'"> </td>';
- $class = ($class == 'even') ? 'odd' : 'even';
- $counter++;
- }
- echo '</tr></table>';
+ echo "<h4>System Configuration</h4>";
+ echo '<table class="outer" cellpadding="4" cellspacing="1">';
+ echo '<tr>';
+ $groups = $xoopsUser->getGroups();
+ $all_ok = false;
+ if (!in_array(XOOPS_GROUP_ADMIN, $groups)) {
+ $sysperm_handler =& xoops_gethandler('groupperm');
+ $ok_syscats = $sysperm_handler->getItemIds('system_admin', $groups);
+ } else {
+ $all_ok = true;
+ }
+ $admin_dir = XOOPS_ROOT_PATH."/modules/system/admin";
+ $handle = opendir($admin_dir);
+ $counter = 0;
+ $class = 'even';
+ while ($file = readdir($handle)) {
+ if (strtolower($file) != 'cvs' && !preg_match("/[.]/", $file) && is_dir($admin_dir.'/'.$file)) {
+ include $admin_dir.'/'.$file.'/xoops_version.php';
+ if ($modversion['hasAdmin']) {
+ $category = isset($modversion['category']) ? intval($modversion['category']) : 0;
+ if (false != $all_ok || in_array($modversion['category'], $ok_syscats)) {
+ echo "<td class='$class' align='center' valign='bottom' width='19%'>";
+ echo "<a href='".XOOPS_URL."/modules/system/admin.php?fct=".$file."'><b>" .trim($modversion['name'])."</b></a>\n";
+ echo "</td>";
+ $counter++;
+ $class = ($class == 'even') ? 'odd' : 'even';
+ }
+ if ($counter > 4) {
+ $counter = 0;
+ echo "</tr>";
+ echo "<tr>";
+ }
+ }
+ unset($modversion);
+ }
+ }
+ while ($counter < 5) {
+ echo '<td class="'.$class.'"> </td>';
+ $class = ($class == 'even') ? 'odd' : 'even';
+ $counter++;
+ }
+ echo '</tr></table>';
xoops_cp_footer();
}
-
-?>
Added: XoopsModules/latestnews/trunk/latestnews/admin/admin_footer.php
===================================================================
--- XoopsModules/latestnews/trunk/latestnews/admin/admin_footer.php (rev 0)
+++ XoopsModules/latestnews/trunk/latestnews/admin/admin_footer.php 2013-09-29 10:23:10 UTC (rev 12106)
@@ -0,0 +1,29 @@
+<?php
+/*
+ * 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 GNU GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
+ * @package
+ * @since
+ * @author XOOPS Development Team
+ * @version $Id $
+ */
+
+global $pathIcon32;
+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();
Property changes on: XoopsModules/latestnews/trunk/latestnews/admin/admin_footer.php
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Author Date Id Rev URL
\ No newline at end of property
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: XoopsModules/latestnews/trunk/latestnews/admin/admin_header.php
===================================================================
--- XoopsModules/latestnews/trunk/latestnews/admin/admin_header.php (rev 0)
+++ XoopsModules/latestnews/trunk/latestnews/admin/admin_header.php 2013-09-29 10:23:10 UTC (rev 12106)
@@ -0,0 +1,48 @@
+<?php
+/*
+ * 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 GNU GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
+ * @package
+ * @since
+ * @author XOOPS Development 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';
+include_once $path . '/class/xoopsformloader.php';
+include_once $path . '/class/xoopsform/grouppermform.php';
+
+global $xoopsModule;
+
+$thisModuleDir = $GLOBALS['xoopsModule']->getVar('dirname');
+
+//if functions.php file exist
+//require_once dirname(dirname(__FILE__)) . '/include/functions.php';
+
+// Load language files
+xoops_loadLanguage('admin', $thisModuleDir);
+xoops_loadLanguage('modinfo', $thisModuleDir);
+xoops_loadLanguage('main', $thisModuleDir);
+
+//$pathIcon16 = '../'.$xoopsModule->getInfo('icons16');
+$pathIcon16 = XOOPS_URL.'/'.$xoopsModule->getInfo('icons16root');
+$pathIcon32 = XOOPS_URL.'/'.$xoopsModule->getInfo('icons32root');
+
+//$pathIcon32 = '../'.$xoopsModule->getInfo('icons32');
+
+$pathModuleAdmin = $xoopsModule->getInfo('dirmoduleadmin');
+
+include_once $GLOBALS['xoops']->path($pathModuleAdmin.'/moduleadmin.php');
Property changes on: XoopsModules/latestnews/trunk/latestnews/admin/admin_header.php
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Author Date Id Rev URL
\ No newline at end of property
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: XoopsModules/latestnews/trunk/latestnews/admin/blockform.php
===================================================================
--- XoopsModules/latestnews/trunk/latestnews/admin/blockform.php (rev 0)
+++ XoopsModules/latestnews/trunk/latestnews/admin/blockform.php 2013-09-29 10:23:10 UTC (rev 12106)
@@ -0,0 +1,142 @@
+<?php
+/**
+ * Module: XoopsTube
+ *
+ * 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.
+ *
+ * PHP version 5
+ *
+ * @category Module
+ * @package Xoopstube
+ * @author Fernando Santos (topet05), fer...@ma...
+ * @copyright Mastop InfoDigital (c) 2003-2007
+ * @link http://www.mastop.com.br
+ * @license GNU GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
+ * @since 1.0.6
+ * @version $Id$
+ */
+
+include_once XOOPS_ROOT_PATH . "/class/xoopsformloader.php";
+$form = new XoopsThemeForm($block['form_title'], 'blockform', 'blocksadmin.php', "post", true);
+if (isset($block['name'])) {
+ $form->addElement(new XoopsFormLabel(_AM_SYSTEM_BLOCKS_NAME, $block['name']));
+}
+$side_select = new XoopsFormSelect(_AM_SYSTEM_BLOCKS_TYPE, "bside", $block['side']);
+$side_select->addOptionArray(
+ array(
+ 0 => _AM_SYSTEM_BLOCKS_SBLEFT,
+ 1 => _AM_SYSTEM_BLOCKS_SBRIGHT,
+ 3 => _AM_SYSTEM_BLOCKS_CBLEFT,
+ 4 => _AM_SYSTEM_BLOCKS_CBRIGHT,
+ 5 => _AM_SYSTEM_BLOCKS_CBCENTER,
+ 7 => _AM_SYSTEM_BLOCKS_CBBOTTOMLEFT,
+ 8 => _AM_SYSTEM_BLOCKS_CBBOTTOMRIGHT,
+ 9 => _AM_SYSTEM_BLOCKS_CBBOTTOM,
+ )
+);
+$form->addElement($side_select);
+$form->addElement(new XoopsFormText(_AM_SYSTEM_BLOCKS_WEIGHT, "bweight", 2, 5, $block['weight']));
+$form->addElement(new XoopsFormRadioYN(_AM_SYSTEM_BLOCKS_VISIBLE, 'bvisible', $block['visible']));
+$mod_select = new XoopsFormSelect(_AM_SYSTEM_BLOCKS_VISIBLEIN, "bmodule", $block['modules'], 5, true);
+$module_handler =& xoops_gethandler('module');
+$criteria = new CriteriaCompo(new Criteria('hasmain', 1));
+$criteria->add(new Criteria('isactive', 1));
+$module_list =& $module_handler->getList($criteria);
+$module_list[-1] = _AM_SYSTEM_BLOCKS_TOPPAGE;
+$module_list[0] = _AM_SYSTEM_BLOCKS_ALLPAGES;
+ksort($module_list);
+$mod_select->addOptionArray($module_list);
+$form->addElement($mod_select);
+$form->addElement(new XoopsFormText(_AM_TITLE, 'btitle', 50, 255, $block['title']), false);
+if ($block['is_custom']) {
+ $textarea = new XoopsFormDhtmlTextArea(_AM_SYSTEM_BLOCKS_CONTENT, 'bcontent', $block['content'], 15, 70);
+ $textarea->setDescription(
+ '<span style="font-size:x-small;font-weight:bold;">' . _AM_SYSTEM_BLOCKS_USEFULTAGS
+ . '</span><br /><span style="font-size:x-small;font-weight:normal;">' . sprintf(
+ _AM_BLOCKTAG1,
+ '{X_SITEURL}',
+ XOOPS_URL . '/'
+ ) . '</span>'
+ );
+ $form->addElement($textarea, true);
+ $ctype_select = new XoopsFormSelect(_AM_SYSTEM_BLOCKS_CTYPE, 'bctype', $block['ctype']);
+ $ctype_select->addOptionArray(
+ array(
+ 'H' => _AM_SYSTEM_BLOCKS_HTML,
+ 'P' => _AM_SYSTEM_BLOCKS_PHP,
+ 'S' => _AM_SYSTEM_BLOCKS_AFWSMILE,
+ 'T' => _AM_SYSTEM_BLOCKS_AFNOSMILE
+ )
+ );
+ $form->addElement($ctype_select);
+} else {
+ if ($block['template'] != '') {
+ $tplfile_handler =& xoops_gethandler('tplfile');
+ $btemplate =& $tplfile_handler->find($GLOBALS['xoopsConfig']['template_set'], 'block', $block['bid']);
+ if (count($btemplate) > 0) {
+ $form->addElement(
+ new XoopsFormLabel(_AM_SYSTEM_BLOCKS_CONTENT,
+ '<a href="' . XOOPS_URL . '/modules/system/admin.php?fct=tplsets&op=edittpl&id='
+ . $btemplate[0]->getVar('tpl_id') . '">' . _AM_SYSTEM_BLOCKS_EDITTPL . '</a>')
+ );
+ } else {
+ $btemplate2 =& $tplfile_handler->find('default', 'block', $block['bid']);
+ if (count($btemplate2) > 0) {
+ $form->addElement(
+ new XoopsFormLabel(_AM_SYSTEM_BLOCKS_CONTENT,
+ '<a href="' . XOOPS_URL . '/modules/system/admin.php?fct=tplsets&op=edittpl&id='
+ . $btemplate2[0]->getVar('tpl_id') . '" target="_blank">' . _AM_SYSTEM_BLOCKS_EDITTPL . '</a>')
+ );
+ }
+ }
+ }
+ if ($block['edit_form'] != false) {
+ $form->addElement(new XoopsFormLabel(_AM_SYSTEM_BLOCKS_OPTIONS, $block['edit_form']));
+ }
+}
+$cache_select = new XoopsFormSelect(_AM_SYSTEM_BLOCKS_BCACHETIME, 'bcachetime', $block['bcachetime']);
+$cache_select->addOptionArray(
+ array(
+ '0' => _NOCACHE,
+ '30' => sprintf(_SECONDS, 30),
+ '60' => _MINUTE,
+ '300' => sprintf(_MINUTES, 5),
+ '1800' => sprintf(_MINUTES, 30),
+ '3600' => _HOUR,
+ '18000' => sprintf(_HOURS, 5),
+ '86400' => _DAY,
+ '259200' => sprintf(_DAYS, 3),
+ '604800' => _WEEK,
+ '2592000' => _MONTH
+ )
+);
+$form->addElement($cache_select);
+
+$groupperm_handler =& xoops_gethandler('groupperm');
+$groups =& $groupperm_handler->getGroupIds('block_read', $block['bid']);
+
+
+$form->addElement(new XoopsFormSelectGroup( _AM_SYSTEM_BLOCKS_GROUP, 'groups', true, $groups, 5, true) );
+
+if (isset($block['bid'])) {
+ $form->addElement(new XoopsFormHidden('bid', $block['bid']));
+}
+$form->addElement(new XoopsFormHidden('op', $block['op']));
+$form->addElement(new XoopsFormHidden('fct', 'blocksadmin'));
+$button_tray = new XoopsFormElementTray('', ' ');
+if ($block['is_custom']) {
+ $button_tray->addElement(new XoopsFormButton('', 'previewblock', _PREVIEW, "submit"));
+}
+
+//Submit buttons
+$button_tray = new XoopsFormElementTray('', '');
+$submit_button = new XoopsFormButton("", "submitblock", _SUBMIT, "submit");
+$button_tray->addElement($submit_button);
+
+$cancel_button = new XoopsFormButton('', '', _CANCEL, 'button');
+$cancel_button->setExtra('onclick="history.go(-1)"');
+$button_tray->addElement($cancel_button);
+
+$form->addElement($button_tray);
Property changes on: XoopsModules/latestnews/trunk/latestnews/admin/blockform.php
___________________________________________________________________
Added: svn:keywords
## -0,0 +1 ##
+Author Date Id Rev URL
\ No newline at end of property
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: XoopsModules/latestnews/trunk/latestnews/admin/blocksadmin.php
===================================================================
--- XoopsModules/latestnews/trunk/latestnews/admin/blocksadmin.php (rev 0)
+++ XoopsModules/latestnews/trunk/latestnews/admin/blocksadmin.php 2013-09-29 10:23:10 UTC (rev 12106)
@@ -0,0 +1,622 @@
+<?php
+/**
+ * Module: XoopsTube
+ *
+ * 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.
+ *
+ * PHP version 5
+ *
+ * @category Module
+ * @package Xoopstube
+ * @author Fernando Santos (topet05), fer...@ma...
+ * @copyright Mastop InfoDigital (c) 2003-2007
+ * @link http://www.mastop.com.br
+ * @license GNU GPL 2 or later (http://www.gnu.org/licenses/gpl-2.0.html)
+ * @since 1.0.6
+ * @version $Id$
+ */
+
+include_once 'admin_header.php';
+if (!is_object($xoopsUser) || !is_object($xoopsModule) || !$xoopsUser->isAdmin($xoopsModule->mid())) {
+ exit(_AM_XTUBE_ERROR403);
+}
+if ($xoopsUser->isAdmin($xoopsModule->mid())) {
+ include_once XOOPS_ROOT_PATH . '/class/xoopsblock.php';
+ $op = "list";
+ if (isset($_POST)) {
+ foreach ($_POST as $k => $v) {
+ $$k = $v;
+ }
+ }
+
+ if (isset($_GET['op'])) {
+ if ($_GET['op'] == "edit" || $_GET['op'] == "delete" || $_GET['op'] == "delete_ok" || $_GET['op'] == "clone"
+ || $_GET['op'] == "edit"
+ ) {
+ $op = $_GET['op'];
+ $bid = isset($_GET['bid']) ? intval($_GET['bid']) : 0;
+ }
+ }
+
+
+ /**
+ *
+ */
+ function listBlocks()
+ {
+ global $xoopsUser, $xoopsConfig, $xoopsModule, $pathIcon16;
+ include_once XOOPS_ROOT_PATH . '/class/xoopslists.php';
+ $db =& XoopsDatabaseFactory::getDatabaseConnection();
+ if (file_exists(
+ XOOPS_ROOT_PATH . "/modules/system/language/" . $xoopsConfig['language'] . "/admin/blocksadmin.php"
+ )
+ ) {
+ include_once(XOOPS_ROOT_PATH . "/modules/system/language/" . $xoopsConfig['language'] . "/admin.php");
+ include_once(XOOPS_ROOT_PATH . "/modules/system/language/" . $xoopsConfig['language']
+ . "/admin/blocksadmin.php");
+ //include_once(XOOPS_ROOT_PATH."/modules/system/language/".$xoopsConfig['language']."/admin/groups.php");
+ } else {
+ include_once(XOOPS_ROOT_PATH . "/modules/system/language/portuguesebr/admin.php");...
[truncated message content] |