From: <be...@us...> - 2011-12-26 03:23:54
|
Revision: 8552 http://xoops.svn.sourceforge.net/xoops/?rev=8552&view=rev Author: beckmi Date: 2011-12-26 03:23:47 +0000 (Mon, 26 Dec 2011) Log Message: ----------- Updating Trunk to XOOPS 2.5.2 Final Modified Paths: -------------- XoopsCore/trunk/docs/changelog.250.txt XoopsCore/trunk/htdocs/class/module.textsanitizer.php XoopsCore/trunk/htdocs/class/xoopsblock.php XoopsCore/trunk/htdocs/edituser.php XoopsCore/trunk/htdocs/include/version.php XoopsCore/trunk/htdocs/index.php XoopsCore/trunk/htdocs/modules/profile/edituser.php XoopsCore/trunk/htdocs/modules/system/blocks/system_blocks.php XoopsCore/trunk/htdocs/themes/zetagenesis/css/xoopseditor.css Added Paths: ----------- XoopsCore/trunk/docs/README.txt XoopsCore/trunk/docs/release_notes.txt XoopsCore/trunk/htdocs/Frameworks/moduleclasses/ XoopsCore/trunk/htdocs/install/img/xoops_2.5.2.png Removed Paths: ------------- XoopsCore/trunk/docs/README.txt XoopsCore/trunk/htdocs/install/img/xoops_2.5.2-RC1.png Property Changed: ---------------- XoopsCore/trunk/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/icons/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/icons/16/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/icons/32/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/icons/bookmarks/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/css/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/doc/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/images/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/language/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/language/english/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/language/french/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/language/german/ XoopsCore/trunk/htdocs/Frameworks/moduleclasses/moduleadmin/language/russian/ XoopsCore/trunk/htdocs/modules/ Property changes on: XoopsCore/trunk ___________________________________________________________________ Modified: svn:mergeinfo - /XoopsCore/branches/2.4.x/2.4.4:4083-4170 /XoopsCore/branches/2.4.x/2.4.5:4294-4943 /XoopsCore/branches/2.5.x/2.5.0:5408-5536 /XoopsCore/branches/2.5.x/2.5.1:6339-6621 /XoopsCore/branches/2.5.x/2.5.2:6625-7709 /XoopsCore/branches/tasks/2.5.0-formuss-trabis:4945-6327 /XoopsCore/releases/2.5.0:5727-8546 /XoopsCore/releases/2.5.0-beta:5409-8543 /XoopsCore/releases/2.5.0-rc:5537-8544 /XoopsCore/releases/2.5.0-rc2:5597-8545 /XoopsCore/releases/2.5.1:6526-8548 /XoopsCore/releases/2.5.1-rc:6408-8547 /XoopsCore/releases/2.5.1a:6706-8549 /XoopsCore/releases/2.5.2-rc:7711-8550 + /XoopsCore/branches/2.4.x/2.4.4:4083-4170 /XoopsCore/branches/2.4.x/2.4.5:4294-4943 /XoopsCore/branches/2.5.x/2.5.0:5408-5536 /XoopsCore/branches/2.5.x/2.5.1:6339-6621 /XoopsCore/branches/2.5.x/2.5.2:6625-7754 /XoopsCore/branches/tasks/2.5.0-formuss-trabis:4945-6327 /XoopsCore/releases/2.5.0:5727-8546 /XoopsCore/releases/2.5.0-beta:5409-8543 /XoopsCore/releases/2.5.0-rc:5537-8544 /XoopsCore/releases/2.5.0-rc2:5597-8545 /XoopsCore/releases/2.5.1:6526-8548 /XoopsCore/releases/2.5.1-rc:6408-8547 /XoopsCore/releases/2.5.1a:6706-8549 /XoopsCore/releases/2.5.2:7759-8551 /XoopsCore/releases/2.5.2-rc:7711-8550 Deleted: XoopsCore/trunk/docs/README.txt =================================================================== --- XoopsCore/trunk/docs/README.txt 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/docs/README.txt 2011-12-26 03:23:47 UTC (rev 8552) @@ -1,17 +0,0 @@ -XOOPS 2.5.2 RC (Release Candidate) - -The XOOPS Development Team is pleased to announce the release of XOOPS 2.5.2 RC. - -This release is focused on fixing bugs from previous versions and security enhancements based on report from High-Tech Bridge Security Research Lab. - -Download XOOPS 2.5.2 RC from [url=https://sourceforge.net/projects/xoops/files/XOOPS%20Core%20%28Beta%20Releases%29/XOOPS_2.5.2_RC/]Sourceforge repository[/url]. - -How to contribute ------------------------------------ -Bug report: http://sourceforge.net/tracker/?group_id=41586&atid=430840 -Patch and enhancement: http://sourceforge.net/tracker/?group_id=41586&atid=430842 -Feature design: http://sourceforge.net/tracker/?group_id=41586&atid=430843 -Release announcement: https://lists.sourceforge.net/lists/listinfo/xoops-announcement - -XOOPS Development Team -September 15th, 2011 \ No newline at end of file Copied: XoopsCore/trunk/docs/README.txt (from rev 8551, XoopsCore/releases/2.5.2/docs/README.txt) =================================================================== --- XoopsCore/trunk/docs/README.txt (rev 0) +++ XoopsCore/trunk/docs/README.txt 2011-12-26 03:23:47 UTC (rev 8552) @@ -0,0 +1,17 @@ +XOOPS 2.5.2 Final + +The XOOPS Development Team is pleased to announce the release of XOOPS 2.5.2 Final. + +This release is focused on fixing bugs from previous versions and security enhancements based on report from High-Tech Bridge Security Research Lab. + +Download XOOPS 2.5.2 Final from [url=http://sourceforge.net/projects/xoops/files/XOOPS%20Core%20%28stable%20releases%29/XOOPS%202.5.2/]Sourceforge repository[/url]. + +How to contribute +----------------------------------- +Bug report: http://sourceforge.net/tracker/?group_id=41586&atid=430840 +Patch and enhancement: http://sourceforge.net/tracker/?group_id=41586&atid=430842 +Feature design: http://sourceforge.net/tracker/?group_id=41586&atid=430843 +Release announcement: https://lists.sourceforge.net/lists/listinfo/xoops-announcement + +XOOPS Development Team +October 2nd, 2011 \ No newline at end of file Modified: XoopsCore/trunk/docs/changelog.250.txt =================================================================== --- XoopsCore/trunk/docs/changelog.250.txt 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/docs/changelog.250.txt 2011-12-26 03:23:47 UTC (rev 8552) @@ -1,4 +1,12 @@ XOOPS 2.5 Changelog +=============================== +2011/09/29: Version 2.5.2 Final +=============================== +Bugfixes: + - ID: 3416069 - avatars upload problem (cesag/trabis) + - MyTextSanitizer::htmlSpecialChars() using UTF-8 by default (trabis) + - System Waiting block produces queries for inactive modules (trabis) + - 'Selected modules does not exist' if using inactive module on startpage (trabis) =============================== 2011/09/06: Version 2.5.2 RC @@ -76,6 +84,7 @@ - "admin_warnings_enable" option in xoops_data/configs/xoopsconfig.php (trabis) - Preload event 'checkcache' on header.php to allow disable caching on specific conditions (trabis) - XoopsObject::getVar() case 'n' for XOBJ_DTYPE_ARRAY/XOBJ_DTYPE_UNICODE_ARRAY to allow getting raw value (trabis) + - ModuleAdmin class to /Frameworks (mage,mamba) Improved: - Changed "debugLevel" default option to 2(admins only) in xoops_data/configs/xoopsconfig.php(trabis) - XoopsGroupPermHandler::getRight() as new parameter $trueifadmin to allow modules to set admin permissions (trabis) Copied: XoopsCore/trunk/docs/release_notes.txt (from rev 8551, XoopsCore/releases/2.5.2/docs/release_notes.txt) =================================================================== --- XoopsCore/trunk/docs/release_notes.txt (rev 0) +++ XoopsCore/trunk/docs/release_notes.txt 2011-12-26 03:23:47 UTC (rev 8552) @@ -0,0 +1,113 @@ +XOOPS 2.5.2 Release Candidate (RC) + +The XOOPS Development Team is pleased to announce the release of XOOPS 2.5.2 RC. Several bugs have been fixed as well as security enhancement based on report from High-Tech Bridge Security Research Lab.. +Please be aware that the bugfix is not complete and 2.5 series will be following small but frequent release rule so that users can take advantage of quick fixes. + +This 2.5 series builds on the XOOPS 2.4.x series with objectives of usability improvements instead of architecture or API changes. +The system module is updated with a major redesign with jQuery based AJAX, done mainly by ForMusS, kraven_30, Mage with contributions from trabis, voltan, Kris_fr, onokazu etc. +Besides usability, some proof-of-concept experiments have also been proven for module and theme development. Unavoidably there are bugs and incompatibility introduced. + +Download XOOPS 2.5.2 from [url=https://sourceforge.net/projects/xoops/files/XOOPS%20Core%20%28stable%20releases%29/XOOPS%202.5.2/]Sourceforge repository[/url]. + +System requirements +----------------------------------- + +PHP: +Any PHP version >= 5.2 (PHP 5.3+ is strongly recommended) + +MySQL: +MySQL server 5.0+ + +Web server: +Any server supporting the required PHP version (Apache highly recommended) + + +Downloading XOOPS +----------------------------------- + +Your can get this release package from the sourceforge.net file repository. +There are .zip and .gz archives provided. + + +Installing XOOPS +----------------------------------- + + 1. Copy the content of the htdocs/ folder where it can be accessed by your server + 2. Ensure mainfile.php and uploads/ are writable by the web server + 3. For security considerations, you are encouraged to move directories "/xoops_lib" (for XOOPS libraries) and "/xoops_data" (for XOOPS data) out of Document Root, and change the folder names. + 4. Make the directory xoops_data/ writable; Create (if not already present) and make the directories xoops_data/caches/, xoops_data/caches/xoops_cache/, xoops_data/caches/smarty_cache/ and xoops_data/caches/smarty_compile/ writable. + 5. Access the folder where you installed the htdocs/ files using your web browser to launch the installation wizard + + +Installing Protector in XOOPS +----------------------------------- +We also highly recommend the installation of the PROTECTOR module which will bring additional security protection and logging capabilities to your site. + + +Upgrading from a previous version +----------------------------------- + +Upgrading from 2.5.0 to 2.5.2: + 1. Get the right update package from the sourceforge file repository + 2. Overwrite files in XOOPS directory on your server with the content of /htdocs + * make sure that you copy the content of /xoops_lib to whatever directory you keep it on the server now (it should be your current XOOPS_TRUST_PATH directory), then delete the /xoops_lib directory. There can NOT be two directories with the content of /xoops_lib + 3. Update the "system" module from the modules administration interface. Other modules, especially "Profile" and "Protector" are recommended to update as well + +Upgrading from previous versions older than 2.5.0: + The upgrade scripts from older versions to 2.5.0 are not complete, however it won't affect your XOOPS site. The scripts will be improved in next release. + Following is an instruction for upgrading from XOOPS 2.4.5 to 2.5 provided by John Healy: + 0. Verify the system requirements, in particular the version of PHP. Backup your XOOPS database and site directory. (There are several ways to do these actions, which are discussed elsewhere.) Turning your site off is optional. + Change the permissions on mainfile.php and /include/license.php to be writable, for example: + File Normal For upgrade + mainfile.php 400 700 + /include/license.php 444 777 + Get the correct update package from the SourceForge file repository. + 1. In the upgrade package folder, move the "upgrade" folder inside the "htdocs" folder, if it's not already there. Remove the install folder from the "htdocs" folder, if it's there. Remove the mainfile.php file from the "htdocs" folder, if it's there. + If you've moved the xoops_data and xoops_lib folders outside your site's root directory, move these folders out of the "htdocs" folder in the upgrade package folder. + 2. Delete the /modules/system directory on your current XOOPS site (to get rid of any old unnecessary files). + 3. Overwrite the files in the XOOPS directory on your current XOOPS site with the content of "htdocs" folder of the upgrade package. (There are several ways to do this action, which are discussed elsewhere.) + As noted above, if relocated, overwrite the files in your current xoops_data and xoops_lib with the content of those in the upgrade package. + 4. If you have Protector previously installed, open the "mainfile.php" file , and remove the Pre-check and Post-check lines (if they exist): + include XOOPS_TRUST_PATH.'/modules/protector/include/precheck.inc.php' ; + include XOOPS_TRUST_PATH.'/modules/protector/include/postcheck.inc.php' ; + 5. At your site's address (URL), login as administrator. Access <your.site.url>/upgrade/ with a browser, and follow the instructions (and any for updating your XOOPS database). After all updates have been applied (green checkmarks), note the link in the Updater to update the "system" module, and do so. + 6. Delete the "upgrade" folder from your site's "htdocs" directory. + 7. Update (reload) other modules, especially "Profile" and "Protector," if necessary. + 8. Change permissions on the files noted above back to their normal state. + 9. Turn your site back on, if you turned it off earlier. + + +Debug information display level +----------------------------------- + +Since XOOPS 2.3.1 debug information display level is enabled as a temporary solution for 2.3* to show debug information to different level of users: to all users, to members or to admins only. +The configuration can be set in /xoops_data/configs/xoopsconfig.php + + +Files integrity check +----------------------------------- + +The full XOOPS package is released with a script able to check if all the system files have been correctly uploaded to the server. To use it, follow these instructions: + + 1. Upload the checksum.php and checksum.md5 files located in the XOOPS package root to your XOOPS server folder (putting them next to mainfile.php). + 2. Execute checksum.php with your browser + 3. If necessary, re-upload the missing or corrupted system files + 4. Remove checksum.php and checksum.md5 from your server + + +Modules +----------------------------------- + +This release contains only the "system-related modules". You are invited to browse the XOOPS modules repository to if you need additional functionality. Note: as a new repository is being built, the current repository is not up-to-date, PLEASE VISIT INDIVIDUAL DEVELOPERS' WEBSITES TO MAKE SURE YOU ARE USING LATEST VERSION OF MODULES. + + +How to contribute +----------------------------------- +Bug report: http://sourceforge.net/tracker/?group_id=41586&atid=430840 +Patch and enhancement: http://sourceforge.net/tracker/?group_id=41586&atid=430842 +Feature design: http://sourceforge.net/tracker/?group_id=41586&atid=430843 +Release announcement: https://lists.sourceforge.net/lists/listinfo/xoops-announcement + + +XOOPS Development Team +September 15th, 2011 \ No newline at end of file Property changes on: XoopsCore/trunk/htdocs/Frameworks/moduleclasses ___________________________________________________________________ Added: bugtraq:number + true Modified: XoopsCore/trunk/htdocs/class/module.textsanitizer.php =================================================================== --- XoopsCore/trunk/htdocs/class/module.textsanitizer.php 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/htdocs/class/module.textsanitizer.php 2011-12-26 03:23:47 UTC (rev 8552) @@ -475,9 +475,8 @@ */ function htmlSpecialChars($text, $quote_style = ENT_QUOTES, $charset = null, $double_encode = true) { - // return preg_replace('/&/i', '&', htmlspecialchars($text, ENT_QUOTES)); if (version_compare(phpversion(), '5.2.3', '>=')) { - $text = htmlspecialchars($text, $quote_style, $charset ? $charset : 'UTF-8', $double_encode); + $text = htmlspecialchars($text, $quote_style, $charset ? $charset : (defined('_CHARSET') ? _CHARSET : 'UTF-8'), $double_encode); } else { $text = htmlspecialchars($text, $quote_style); } Modified: XoopsCore/trunk/htdocs/class/xoopsblock.php =================================================================== --- XoopsCore/trunk/htdocs/class/xoopsblock.php 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/htdocs/class/xoopsblock.php 2011-12-26 03:23:47 UTC (rev 8552) @@ -192,15 +192,15 @@ if (!$show_func) { return false; } - // must get lang files b4 execution of the function if (!file_exists($func_file = $GLOBALS['xoops']->path('modules/' . $this->getVar('dirname') . '/blocks/' . $this->getVar('func_file')))) { return false; } + // must get lang files b4 including the file + // some modules require it for code that is outside the function + xoops_loadLanguage('blocks', $this->getVar('dirname')); include_once $func_file; if (function_exists($show_func)) { - //Load Languages - xoops_loadLanguage('blocks', $this->getVar('dirname')); // execute the function $options = explode('|', $this->getVar('options')); $block = $show_func($options); Modified: XoopsCore/trunk/htdocs/edituser.php =================================================================== --- XoopsCore/trunk/htdocs/edituser.php 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/htdocs/edituser.php 2011-12-26 03:23:47 UTC (rev 8552) @@ -322,8 +322,8 @@ $avatars = $avt_handler->getObjects(new Criteria('avatar_file', $oldavatar)); if (! empty($avatars) && count($avatars) == 1 && is_object($avatars[0])) { $avt_handler->delete($avatars[0]); - $oldavatar_path = str_replace("\\", "/", realpath(XOOPS_UPLOAD_PATH . '/' . $oldavatar)); - if (false !== strpos($oldavatar_path, XOOPS_UPLOAD_PATH) && is_file($oldavatar_path)) { + $oldavatar_path = realpath(XOOPS_UPLOAD_PATH . '/' . $oldavatar); + if (0 === strpos($oldavatar_path, XOOPS_UPLOAD_PATH) && is_file($oldavatar_path)) { unlink($oldavatar_path); } } @@ -364,8 +364,8 @@ } unset($avatars, $criteria_avatar); } - $user_avatarpath = str_replace("\\", "/", realpath(XOOPS_UPLOAD_PATH . '/' . $user_avatar)); - if (false === strpos($user_avatarpath, realpath(XOOPS_UPLOAD_PATH)) && is_file($user_avatarpath)) { + $user_avatarpath = realpath(XOOPS_UPLOAD_PATH . '/' . $user_avatar); + if (0 === strpos($user_avatarpath, realpath(XOOPS_UPLOAD_PATH)) && is_file($user_avatarpath)) { $oldavatar = $xoopsUser->getVar('user_avatar'); $xoopsUser->setVar('user_avatar', $user_avatar); $member_handler =& xoops_gethandler('member'); @@ -379,8 +379,8 @@ $avatars = $avt_handler->getObjects(new Criteria('avatar_file', $oldavatar)); if (!empty($avatars) && count($avatars) == 1 && is_object($avatars[0])) { $avt_handler->delete($avatars[0]); - $oldavatar_path = str_replace("\\", "/", realpath(XOOPS_UPLOAD_PATH . '/' . $oldavatar)); - if (false === strpos($oldavatar_path, realpath(XOOPS_UPLOAD_PATH)) && is_file($oldavatar_path)) { + $oldavatar_path = realpath(XOOPS_UPLOAD_PATH . '/' . $oldavatar); + if (0 === strpos($oldavatar_path, realpath(XOOPS_UPLOAD_PATH)) && is_file($oldavatar_path)) { unlink($oldavatar_path); } } Modified: XoopsCore/trunk/htdocs/include/version.php =================================================================== --- XoopsCore/trunk/htdocs/include/version.php 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/htdocs/include/version.php 2011-12-26 03:23:47 UTC (rev 8552) @@ -30,6 +30,6 @@ /** * Define XOOPS version */ -define('XOOPS_VERSION', 'XOOPS 2.5.2-RC1'); +define('XOOPS_VERSION', 'XOOPS 2.5.2'); ?> \ No newline at end of file Modified: XoopsCore/trunk/htdocs/index.php =================================================================== --- XoopsCore/trunk/htdocs/index.php 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/htdocs/index.php 2011-12-26 03:23:47 UTC (rev 8552) @@ -25,7 +25,7 @@ $xoopsPreload->triggerEvent('core.index.start'); //check if start page is defined -if (isset($xoopsConfig['startpage']) && $xoopsConfig['startpage'] != "" && $xoopsConfig['startpage'] != "--") { +if (isset($xoopsConfig['startpage']) && $xoopsConfig['startpage'] != "" && $xoopsConfig['startpage'] != "--" && xoops_isActiveModule($xoopsConfig['startpage'])) { // Temporary solution for start page redirection define("XOOPS_STARTPAGE_REDIRECTED", 1); Deleted: XoopsCore/trunk/htdocs/install/img/xoops_2.5.2-RC1.png =================================================================== (Binary files differ) Copied: XoopsCore/trunk/htdocs/install/img/xoops_2.5.2.png (from rev 8551, XoopsCore/releases/2.5.2/htdocs/install/img/xoops_2.5.2.png) =================================================================== (Binary files differ) Property changes on: XoopsCore/trunk/htdocs/modules ___________________________________________________________________ Modified: svn:mergeinfo - /XoopsCore/branches/2.5.x/2.5.1/htdocs/modules:6339-6621 /XoopsCore/branches/2.5.x/2.5.2/htdocs/modules:6625-7709 /XoopsCore/branches/tasks/2.5.0-formuss-trabis/htdocs/modules:5405-6327 /XoopsCore/releases/2.5.0/htdocs/modules:5727-8546 /XoopsCore/releases/2.5.0-rc2/htdocs/modules:5597-8545 /XoopsCore/releases/2.5.1/htdocs/modules:6526-8548 /XoopsCore/releases/2.5.1-rc/htdocs/modules:6408-8547 /XoopsCore/releases/2.5.1a/htdocs/modules:6706-8549 /XoopsCore/releases/2.5.2-rc/htdocs/modules:7711-8550 /XoopsModules/protector/releases/3.40/modules:4782-5620 + /XoopsCore/branches/2.5.x/2.5.1/htdocs/modules:6339-6621 /XoopsCore/branches/2.5.x/2.5.2/htdocs/modules:6625-7754 /XoopsCore/branches/tasks/2.5.0-formuss-trabis/htdocs/modules:5405-6327 /XoopsCore/releases/2.5.0/htdocs/modules:5727-8546 /XoopsCore/releases/2.5.0-rc2/htdocs/modules:5597-8545 /XoopsCore/releases/2.5.1/htdocs/modules:6526-8548 /XoopsCore/releases/2.5.1-rc/htdocs/modules:6408-8547 /XoopsCore/releases/2.5.1a/htdocs/modules:6706-8549 /XoopsCore/releases/2.5.2/htdocs/modules:7759-8551 /XoopsCore/releases/2.5.2-rc/htdocs/modules:7711-8550 /XoopsModules/protector/releases/3.40/modules:4782-5620 Modified: XoopsCore/trunk/htdocs/modules/profile/edituser.php =================================================================== --- XoopsCore/trunk/htdocs/modules/profile/edituser.php 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/htdocs/modules/profile/edituser.php 2011-12-26 03:23:47 UTC (rev 8552) @@ -180,8 +180,8 @@ $avatars = $avt_handler->getObjects(new Criteria('avatar_file', $oldavatar)); if (!empty($avatars) && count($avatars) == 1 && is_object($avatars[0])) { $avt_handler->delete($avatars[0]); - $oldavatar_path = str_replace("\\", "/", realpath(XOOPS_UPLOAD_PATH . '/' . $oldavatar)); - if (false !== strpos($oldavatar_path, XOOPS_UPLOAD_PATH) && is_file($oldavatar_path)) { + $oldavatar_path = realpath(XOOPS_UPLOAD_PATH . '/' . $oldavatar); + if (0 === strpos($oldavatar_path, XOOPS_UPLOAD_PATH) && is_file($oldavatar_path)) { unlink($oldavatar_path); } } @@ -221,9 +221,9 @@ $user_avatar = 'avatars/blank.gif'; } unset($avatars, $criteria_avatar); - } - $user_avatarpath = str_replace("\\", "/", realpath(XOOPS_UPLOAD_PATH.'/'.$user_avatar)); - if (false === strpos($user_avatarpath, realpath(XOOPS_UPLOAD_PATH)) && is_file($user_avatarpath)) { + } + $user_avatarpath = realpath(XOOPS_UPLOAD_PATH . '/' . $user_avatar); + if (0 === strpos($user_avatarpath, realpath(XOOPS_UPLOAD_PATH)) && is_file($user_avatarpath)) { $oldavatar = $GLOBALS['xoopsUser']->getVar('user_avatar'); $GLOBALS['xoopsUser']->setVar('user_avatar', $user_avatar); $member_handler =& xoops_gethandler('member'); @@ -237,8 +237,8 @@ $avatars = $avt_handler->getObjects(new Criteria('avatar_file', $oldavatar)); if (!empty($avatars) && count($avatars) == 1 && is_object($avatars[0])) { $avt_handler->delete($avatars[0]); - $oldavatar_path = str_replace("\\", "/", realpath(XOOPS_UPLOAD_PATH . '/' . $oldavatar)); - if (false === strpos($oldavatar_path, realpath(XOOPS_UPLOAD_PATH)) && is_file($oldavatar_path)) { + $oldavatar_path = realpath(XOOPS_UPLOAD_PATH . '/' . $oldavatar); + if (0 === strpos($oldavatar_path, realpath(XOOPS_UPLOAD_PATH)) && is_file($oldavatar_path)) { unlink($oldavatar_path); } } Modified: XoopsCore/trunk/htdocs/modules/system/blocks/system_blocks.php =================================================================== --- XoopsCore/trunk/htdocs/modules/system/blocks/system_blocks.php 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/htdocs/modules/system/blocks/system_blocks.php 2011-12-26 03:23:47 UTC (rev 8552) @@ -121,12 +121,12 @@ $block['modules'][$i]['name'] = $modules[$i]->getVar('name'); $block['modules'][$i]['directory'] = $modules[$i]->getVar('dirname'); $sublinks = $modules[$i]->subLink(); - if ((!empty($xoopsModule)) && ($i == $xoopsModule->getVar('mid'))) { - $block['modules'][$i]['highlight'] = true; - $block['nothome'] = true; - }if ((!empty($xoopsModule)) && ($i == $xoopsModule->getVar('mid'))) { - $block['modules'][$i]['highlight'] = true; - $block['nothome'] = true; + if ((!empty($xoopsModule)) && ($i == $xoopsModule->getVar('mid'))) { + $block['modules'][$i]['highlight'] = true; + $block['nothome'] = true; + }if ((!empty($xoopsModule)) && ($i == $xoopsModule->getVar('mid'))) { + $block['modules'][$i]['highlight'] = true; + $block['nothome'] = true; } if ((count($sublinks) > 0) && (!empty($xoopsModule)) && ($i == $xoopsModule->getVar('mid'))) { foreach($sublinks as $sublink){ @@ -162,9 +162,9 @@ $block['lang_logout'] = _MB_SYSTEM_LOUT; $criteria = new CriteriaCompo(new Criteria('read_msg', 0)); $criteria->add(new Criteria('to_userid', $xoopsUser->getVar('uid'))); - + $pm_handler =& xoops_gethandler('privmessage'); - + $xoopsPreload =& XoopsPreload::getInstance(); $xoopsPreload->triggerEvent('system.blocks.system_blocks.usershow', array(&$pm_handler)); @@ -180,20 +180,20 @@ global $xoopsUser; $xoopsDB =& Database::getInstance(); $module_handler =& xoops_gethandler('module'); - $block = array(); - - // waiting content for news - if ($module_handler->getCount(new Criteria('dirname', 'news'))) { + $block = array(); + + // waiting content for news + if (xoops_isActiveModule('news') && $module_handler->getCount(new Criteria('dirname', 'news'))) { $result = $xoopsDB->query("SELECT COUNT(*) FROM ".$xoopsDB->prefix("stories")." WHERE published=0"); if ( $result ) { $block['modules'][0]['adminlink'] = XOOPS_URL."/modules/news/admin/index.php?op=newarticle"; list($block['modules'][0]['pendingnum']) = $xoopsDB->fetchRow($result); $block['modules'][0]['lang_linkname'] = _MB_SYSTEM_SUBMS; } - } - + } + // waiting content for mylinks - if ($module_handler->getCount(new Criteria('dirname', 'mylinks'))) { + if (xoops_isActiveModule('mylinks') &&$module_handler->getCount(new Criteria('dirname', 'mylinks'))) { $result = $xoopsDB->query("SELECT COUNT(*) FROM ".$xoopsDB->prefix("mylinks_links")." WHERE status=0"); if ( $result ) { $block['modules'][1]['adminlink'] = XOOPS_URL."/modules/mylinks/admin/index.php?op=listNewLinks"; @@ -212,10 +212,10 @@ list($block['modules'][3]['pendingnum']) = $xoopsDB->fetchRow($result); $block['modules'][3]['lang_linkname'] = _MB_SYSTEM_MLNKS; } - } - + } + // waiting content for mydownloads - if ($module_handler->getCount(new Criteria('dirname', 'mydownloads'))) { + if (xoops_isActiveModule('mydownloads') && $module_handler->getCount(new Criteria('dirname', 'mydownloads'))) { $result = $xoopsDB->query("SELECT COUNT(*) FROM ".$xoopsDB->prefix("mydownloads_downloads")." WHERE status=0"); if ( $result ) { $block['modules'][4]['adminlink'] = XOOPS_URL."/modules/mydownloads/admin/index.php?op=listNewDownloads"; @@ -234,46 +234,46 @@ list($block['modules'][6]['pendingnum']) = $xoopsDB->fetchRow($result); $block['modules'][6]['lang_linkname'] = _MB_SYSTEM_MFLS; } - } - + } + // waiting content for xoops comments $result = $xoopsDB->query("SELECT COUNT(*) FROM ".$xoopsDB->prefix("xoopscomments")." WHERE com_status=1"); if ( $result ) { $block['modules'][7]['adminlink'] = XOOPS_URL."/modules/system/admin.php?module=0&status=1&fct=comments"; list($block['modules'][7]['pendingnum']) = $xoopsDB->fetchRow($result); $block['modules'][7]['lang_linkname'] =_MB_SYSTEM_COMPEND; - } - - // waiting content for TDMDownloads - if ($module_handler->getCount(new Criteria('dirname', 'TDMDownloads'))) { + } + + // waiting content for TDMDownloads + if (xoops_isActiveModule('TDMdownloads') && $module_handler->getCount(new Criteria('dirname', 'TDMDownloads'))) { $result = $xoopsDB->query("SELECT COUNT(*) FROM ".$xoopsDB->prefix("tdmdownloads_downloads")." WHERE status=0"); if ( $result ) { $block['modules'][8]['adminlink'] = XOOPS_URL."/modules/TDMDownloads/admin/downloads.php?op=list&statut_display=0"; list($block['modules'][8]['pendingnum']) = $xoopsDB->fetchRow($result); $block['modules'][8]['lang_linkname'] = _MB_SYSTEM_TDMDOWNLOADS; } - } - - // waiting content for extgallery - if ($module_handler->getCount(new Criteria('dirname', 'extgallery'))) { + } + + // waiting content for extgallery + if (xoops_isActiveModule('extgallery') && $module_handler->getCount(new Criteria('dirname', 'extgallery'))) { $result = $xoopsDB->query("SELECT COUNT(*) FROM ".$xoopsDB->prefix("extgallery_publicphoto")." WHERE photo_approved=0"); if ( $result ) { $block['modules'][9]['adminlink'] = XOOPS_URL."/modules/extgallery/admin/photo.php#pending-photo"; list($block['modules'][9]['pendingnum']) = $xoopsDB->fetchRow($result); $block['modules'][9]['lang_linkname'] = _MB_SYSTEM_EXTGALLERY; } - } - - // waiting content for smartsection - if ($module_handler->getCount(new Criteria('dirname', 'smartsection'))) { + } + + // waiting content for smartsection + if (xoops_isActiveModule('smartsection') && $module_handler->getCount(new Criteria('dirname', 'smartsection'))) { $result = $xoopsDB->query("SELECT COUNT(*) FROM ".$xoopsDB->prefix("smartsection_items")." WHERE status=1"); if ( $result ) { $block['modules'][10]['adminlink'] = XOOPS_URL."/modules/smartsection/admin/item.php"; list($block['modules'][10]['pendingnum']) = $xoopsDB->fetchRow($result); $block['modules'][10]['lang_linkname'] = _MB_SYSTEM_SMARTSECTION; } - } - + } + return $block; } Modified: XoopsCore/trunk/htdocs/themes/zetagenesis/css/xoopseditor.css =================================================================== --- XoopsCore/trunk/htdocs/themes/zetagenesis/css/xoopseditor.css 2011-12-25 23:49:19 UTC (rev 8551) +++ XoopsCore/trunk/htdocs/themes/zetagenesis/css/xoopseditor.css 2011-12-26 03:23:47 UTC (rev 8552) @@ -1,7 +1,7 @@ /*======= Tinymce background textarea ========*/ body.mceContentBody { margin: 0 !important; - padding: 0 !important;; + padding: 0 !important; background-color: #fff; background-image: none; color: #000; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |