|
From: <tr...@us...> - 2012-12-05 19:49:46
|
Revision: 10323
http://sourceforge.net/p/xoops/svn/10323
Author: trabis
Date: 2012-12-05 19:49:43 +0000 (Wed, 05 Dec 2012)
Log Message:
-----------
Fixing bug :: Cannot use a module in front page
Making File green (code inspection)
Modified Paths:
--------------
XoopsCore/branches/2.6.x/2.6.0/htdocs/xoops_lib/Xoops.php
Modified: XoopsCore/branches/2.6.x/2.6.0/htdocs/xoops_lib/Xoops.php
===================================================================
--- XoopsCore/branches/2.6.x/2.6.0/htdocs/xoops_lib/Xoops.php 2012-12-05 19:28:19 UTC (rev 10322)
+++ XoopsCore/branches/2.6.x/2.6.0/htdocs/xoops_lib/Xoops.php 2012-12-05 19:49:43 UTC (rev 10323)
@@ -251,7 +251,7 @@
* @param string $path
* @param string $error_type
*
- * @return string|false
+ * @return string|bool
*/
public function pathExists($path, $error_type)
{
@@ -410,7 +410,8 @@
// Temporary solution for start page redirection
if (defined("XOOPS_STARTPAGE_REDIRECTED")) {
- $this->theme->headContent(null, "<base href='" . XOOPS_URL . '/modules/' . $this->getConfig('startpage') . "/' />", null, null);
+ $smarty = $repeat = null;
+ $this->theme->headContent(null, "<base href='" . XOOPS_URL . '/modules/' . $this->getConfig('startpage') . "/' />", $smarty, $repeat);
}
if (@is_object($this->theme->plugins['XoopsThemeBlocksPlugin'])) {
@@ -1764,9 +1765,10 @@
if ($count > 0) {
$xoopsTpl = new XoopsTpl();
$xoopsTpl->caching = 2;
- for ($i = 0; $i < $count; $i++) {
- if ($block_arr[$i]->getVar('template') != '') {
- $xoopsTpl->clear_cache(XOOPS_ROOT_PATH . "/modules/" . $block_arr[$i]->getVar('dirname') . "/templates/blocks/" . $block_arr[$i]->getVar('template'), 'blk_' . $block_arr[$i]->getVar('bid'));
+ /* @var XoopsBlock $block */
+ foreach($block_arr as $block) {
+ if ($block->getVar('template') != '') {
+ $xoopsTpl->clear_cache(XOOPS_ROOT_PATH . "/modules/" . $block->getVar('dirname') . "/templates/blocks/" . $block->getVar('template'), 'blk_' . $block->getVar('bid'));
}
}
}
|