Completed
Push — master ( 2d4977...3189d6 )
by Michael
10:50
created
blocks/addto.php 1 patch
Indentation   +14 added lines, -14 removed lines patch added patch discarded remove patch
@@ -8,12 +8,12 @@  discard block
 block discarded – undo
8 8
  */
9 9
 function smartobject_addto_show($options)
10 10
 {
11
-    include_once(XOOPS_ROOT_PATH . '/modules/smartobject/include/common.php');
12
-    include_once(SMARTOBJECT_ROOT_PATH . 'class/smartaddto.php');
13
-    $smartaddto = new SmartAddTo($options[0]);
14
-    $block      = $smartaddto->renderForBlock();
11
+	include_once(XOOPS_ROOT_PATH . '/modules/smartobject/include/common.php');
12
+	include_once(SMARTOBJECT_ROOT_PATH . 'class/smartaddto.php');
13
+	$smartaddto = new SmartAddTo($options[0]);
14
+	$block      = $smartaddto->renderForBlock();
15 15
 
16
-    return $block;
16
+	return $block;
17 17
 }
18 18
 
19 19
 /**
@@ -22,16 +22,16 @@  discard block
 block discarded – undo
22 22
  */
23 23
 function smartobject_addto_edit($options)
24 24
 {
25
-    include_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
25
+	include_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
26 26
 
27
-    $form = '';
27
+	$form = '';
28 28
 
29
-    $layout_select = new XoopsFormSelect(_MB_SOBJECT_BLOCKS_ADDTO_LAYOUT, 'options[]', $options[0]);
30
-    $layout_select->addOption(0, _MB_SOBJECT_BLOCKS_ADDTO_LAYOUT_OPTION0);
31
-    $layout_select->addOption(1, _MB_SOBJECT_BLOCKS_ADDTO_LAYOUT_OPTION1);
32
-    $layout_select->addOption(2, _MB_SOBJECT_BLOCKS_ADDTO_LAYOUT_OPTION2);
33
-    $layout_select->addOption(3, _MB_SOBJECT_BLOCKS_ADDTO_LAYOUT_OPTION3);
34
-    $form .= $layout_select->getCaption() . ' ' . $layout_select->render() . '<br />';
29
+	$layout_select = new XoopsFormSelect(_MB_SOBJECT_BLOCKS_ADDTO_LAYOUT, 'options[]', $options[0]);
30
+	$layout_select->addOption(0, _MB_SOBJECT_BLOCKS_ADDTO_LAYOUT_OPTION0);
31
+	$layout_select->addOption(1, _MB_SOBJECT_BLOCKS_ADDTO_LAYOUT_OPTION1);
32
+	$layout_select->addOption(2, _MB_SOBJECT_BLOCKS_ADDTO_LAYOUT_OPTION2);
33
+	$layout_select->addOption(3, _MB_SOBJECT_BLOCKS_ADDTO_LAYOUT_OPTION3);
34
+	$form .= $layout_select->getCaption() . ' ' . $layout_select->render() . '<br />';
35 35
 
36
-    return $form;
36
+	return $form;
37 37
 }
Please login to merge, or discard this patch.
include/custom_code/footer_start.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,5 +2,5 @@
 block discarded – undo
2 2
 
3 3
 function smarthook_footer_start()
4 4
 {
5
-    // code...
5
+	// code...
6 6
 }
Please login to merge, or discard this patch.
include/common.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -14,22 +14,22 @@
 block discarded – undo
14 14
  * SmartObject library path
15 15
  */
16 16
 if (!defined('SMARTOBJECT_URL')) {
17
-    define('SMARTOBJECT_URL', XOOPS_URL . '/modules/smartobject/');
17
+	define('SMARTOBJECT_URL', XOOPS_URL . '/modules/smartobject/');
18 18
 }
19 19
 if (!defined('SMARTOBJECT_ROOT_PATH')) {
20
-    define('SMARTOBJECT_ROOT_PATH', XOOPS_ROOT_PATH . '/modules/smartobject/');
20
+	define('SMARTOBJECT_ROOT_PATH', XOOPS_ROOT_PATH . '/modules/smartobject/');
21 21
 }
22 22
 if (!defined('SMARTOBJECT_IMAGES_URL')) {
23
-    define('SMARTOBJECT_IMAGES_URL', SMARTOBJECT_URL . 'assets/images/');
23
+	define('SMARTOBJECT_IMAGES_URL', SMARTOBJECT_URL . 'assets/images/');
24 24
 }
25 25
 if (!defined('SMARTOBJECT_IMAGES_ROOT_PATH')) {
26
-    define('SMARTOBJECT_IMAGES_ROOT_PATH', SMARTOBJECT_ROOT_PATH . 'assets/images/');
26
+	define('SMARTOBJECT_IMAGES_ROOT_PATH', SMARTOBJECT_ROOT_PATH . 'assets/images/');
27 27
 }
28 28
 if (!defined('SMARTOBJECT_IMAGES_ACTIONS_URL')) {
29
-    define('SMARTOBJECT_IMAGES_ACTIONS_URL', SMARTOBJECT_URL . 'assets/images/actions/');
29
+	define('SMARTOBJECT_IMAGES_ACTIONS_URL', SMARTOBJECT_URL . 'assets/images/actions/');
30 30
 }
31 31
 if (!defined('SMARTOBJECT_IMAGES_ACTIONS_ROOT_PATH')) {
32
-    define('SMARTOBJECT_IMAGES_ACTIONS_ROOT_PATH', SMARTOBJECT_ROOT_PATH . 'assets/images/actions/');
32
+	define('SMARTOBJECT_IMAGES_ACTIONS_ROOT_PATH', SMARTOBJECT_ROOT_PATH . 'assets/images/actions/');
33 33
 }
34 34
 
35 35
 /**
Please login to merge, or discard this patch.
include/adsense.php 2 patches
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -10,16 +10,16 @@
 block discarded – undo
10 10
 
11 11
 function smart_adsense_initiate_smartytags()
12 12
 {
13
-    global $xoopsTpl, $smartobjectAdsenseHandler;
14
-    if (is_object($xoopsTpl)) {
15
-        foreach ($smartobjectAdsenseHandler->objects as $k => $v) {
16
-            $xoopsTpl->assign('adsense_' . $k, $v->render());
17
-        }
18
-    }
13
+	global $xoopsTpl, $smartobjectAdsenseHandler;
14
+	if (is_object($xoopsTpl)) {
15
+		foreach ($smartobjectAdsenseHandler->objects as $k => $v) {
16
+			$xoopsTpl->assign('adsense_' . $k, $v->render());
17
+		}
18
+	}
19 19
 }
20 20
 
21 21
 if (!defined('SMARTOBJECT_URL')) {
22
-    include_once(XOOPS_ROOT_PATH . '/modules/smartobject/include/common.php');
22
+	include_once(XOOPS_ROOT_PATH . '/modules/smartobject/include/common.php');
23 23
 }
24 24
 
25 25
 include_once XOOPS_ROOT_PATH . '/modules/smartobject/include/functions.php';
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -26,4 +26,4 @@
 block discarded – undo
26 26
 include_once(SMARTOBJECT_ROOT_PATH . 'class/adsense.php');
27 27
 
28 28
 $smartobjectAdsenseHandler = xoops_getModuleHandler('adsense', 'smartobject');
29
-$smartobjectAdsensesObj     = $smartobjectAdsenseHandler->getAdsensesByTag();
29
+$smartobjectAdsensesObj = $smartobjectAdsenseHandler->getAdsensesByTag();
Please login to merge, or discard this patch.
include/rating.rate.php 2 patches
Indentation   +47 added lines, -47 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
 // defined('XOOPS_ROOT_PATH') || exit('XOOPS root path not defined');
10 10
 
11 11
 if (!defined('SMARTOBJECT_URL')) {
12
-    include_once(XOOPS_ROOT_PATH . '/modules/smartobject/include/common.php');
12
+	include_once(XOOPS_ROOT_PATH . '/modules/smartobject/include/common.php');
13 13
 }
14 14
 include_once(SMARTOBJECT_ROOT_PATH . 'class/rating.php');
15 15
 include_once(SMARTOBJECT_ROOT_PATH . 'include/functions.php');
@@ -23,53 +23,53 @@  discard block
 block discarded – undo
23 23
 $smartobjectPluginHandler = new SmartPluginHandler();
24 24
 $pluginObj                  = $smartobjectPluginHandler->getPlugin($module_dirname);
25 25
 if ($pluginObj) {
26
-    $rating_item = $pluginObj->getItem();
27
-    if ($rating_item) {
28
-        $rating_itemid = $pluginObj->getItemIdForItem($rating_item);
29
-        $stats         = $smartobjectRatingHandler->getRatingAverageByItemId($rating_itemid, $module_dirname, $rating_item);
30
-        $xoopsTpl->assign('smartobject_rating_stats_total', $stats['sum']);
31
-        $xoopsTpl->assign('smartobject_rating_stats_average', $stats['average']);
32
-        $xoopsTpl->assign('smartobject_rating_item', $rating_item);
33
-        if (is_object($xoopsUser)) {
34
-            $ratingObj = $smartobjectRatingHandler->already_rated($rating_item, $rating_itemid, $module_dirname, $xoopsUser->getVar('uid'));
35
-            $xoopsTpl->assign('smartobject_user_can_rate', true);
36
-        }
37
-        if (isset($ratingObj) && is_object($ratingObj)) {
38
-            $xoopsTpl->assign('smartobject_user_rate', $ratingObj->getVar('rate'));
39
-            $xoopsTpl->assign('smartobject_rated', true);
40
-        } else {
41
-            $xoopsTpl->assign('smartobject_rating_dirname', $module_dirname);
42
-            $xoopsTpl->assign('smartobject_rating_itemid', $rating_itemid);
43
-            $urls = smart_getCurrentUrls();
44
-            $xoopsTpl->assign('smartobject_rating_current_page', $urls['full']);
45
-            if (isset($xoTheme) && is_object($xoTheme)) {
46
-                $xoTheme->addStylesheet(SMARTOBJECT_URL . 'assets/css/module.css');
47
-            } else {
48
-                //probleme d'inclusion de css apres le flashplayer. Style plac� dans css du theme
49
-                //$xoopsTpl->assign('smartobject_css',"<link rel='stylesheet' type='text/css' href='".XOOPS_URL."/modules/smartobject/assets/css/module.css' />");
50
-            }
51
-        }
52
-    }
26
+	$rating_item = $pluginObj->getItem();
27
+	if ($rating_item) {
28
+		$rating_itemid = $pluginObj->getItemIdForItem($rating_item);
29
+		$stats         = $smartobjectRatingHandler->getRatingAverageByItemId($rating_itemid, $module_dirname, $rating_item);
30
+		$xoopsTpl->assign('smartobject_rating_stats_total', $stats['sum']);
31
+		$xoopsTpl->assign('smartobject_rating_stats_average', $stats['average']);
32
+		$xoopsTpl->assign('smartobject_rating_item', $rating_item);
33
+		if (is_object($xoopsUser)) {
34
+			$ratingObj = $smartobjectRatingHandler->already_rated($rating_item, $rating_itemid, $module_dirname, $xoopsUser->getVar('uid'));
35
+			$xoopsTpl->assign('smartobject_user_can_rate', true);
36
+		}
37
+		if (isset($ratingObj) && is_object($ratingObj)) {
38
+			$xoopsTpl->assign('smartobject_user_rate', $ratingObj->getVar('rate'));
39
+			$xoopsTpl->assign('smartobject_rated', true);
40
+		} else {
41
+			$xoopsTpl->assign('smartobject_rating_dirname', $module_dirname);
42
+			$xoopsTpl->assign('smartobject_rating_itemid', $rating_itemid);
43
+			$urls = smart_getCurrentUrls();
44
+			$xoopsTpl->assign('smartobject_rating_current_page', $urls['full']);
45
+			if (isset($xoTheme) && is_object($xoTheme)) {
46
+				$xoTheme->addStylesheet(SMARTOBJECT_URL . 'assets/css/module.css');
47
+			} else {
48
+				//probleme d'inclusion de css apres le flashplayer. Style plac� dans css du theme
49
+				//$xoopsTpl->assign('smartobject_css',"<link rel='stylesheet' type='text/css' href='".XOOPS_URL."/modules/smartobject/assets/css/module.css' />");
50
+			}
51
+		}
52
+	}
53 53
 }
54 54
 
55 55
 if (isset($_POST['smartobject_rating_submit'])) {
56
-    // The rating form has just been posted. Let's save the info
57
-    $ratingObj = $smartobjectRatingHandler->create();
58
-    $ratingObj->setVar('dirname', $module_dirname);
59
-    $ratingObj->setVar('item', $rating_item);
60
-    $ratingObj->setVar('itemid', $rating_itemid);
61
-    $ratingObj->setVar('uid', $xoopsUser->getVar('uid'));
62
-    $ratingObj->setVar('date', time());
63
-    $ratingObj->setVar('rate', $_POST['smartobject_rating_value']);
64
-    if (!$smartobjectRatingHandler->insert($ratingObj)) {
65
-        if ($xoopsDB->errno() == 1062) {
66
-            $message = _SOBJECT_RATING_DUPLICATE_ENTRY;
67
-        } else {
68
-            $message = _SOBJECT_RATING_ERROR;
69
-        }
70
-    } else {
71
-        $message = _SOBJECT_RATING_SUCCESS;
72
-    }
73
-    redirect_header('', 3, $message);
74
-    exit;
56
+	// The rating form has just been posted. Let's save the info
57
+	$ratingObj = $smartobjectRatingHandler->create();
58
+	$ratingObj->setVar('dirname', $module_dirname);
59
+	$ratingObj->setVar('item', $rating_item);
60
+	$ratingObj->setVar('itemid', $rating_itemid);
61
+	$ratingObj->setVar('uid', $xoopsUser->getVar('uid'));
62
+	$ratingObj->setVar('date', time());
63
+	$ratingObj->setVar('rate', $_POST['smartobject_rating_value']);
64
+	if (!$smartobjectRatingHandler->insert($ratingObj)) {
65
+		if ($xoopsDB->errno() == 1062) {
66
+			$message = _SOBJECT_RATING_DUPLICATE_ENTRY;
67
+		} else {
68
+			$message = _SOBJECT_RATING_ERROR;
69
+		}
70
+	} else {
71
+		$message = _SOBJECT_RATING_SUCCESS;
72
+	}
73
+	redirect_header('', 3, $message);
74
+	exit;
75 75
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
 // Retreive the SmartObject Rating plugin for the current module if it exists
22 22
 $smartobjectRatingHandler = xoops_getModuleHandler('rating', 'smartobject');
23 23
 $smartobjectPluginHandler = new SmartPluginHandler();
24
-$pluginObj                  = $smartobjectPluginHandler->getPlugin($module_dirname);
24
+$pluginObj = $smartobjectPluginHandler->getPlugin($module_dirname);
25 25
 if ($pluginObj) {
26 26
     $rating_item = $pluginObj->getItem();
27 27
     if ($rating_item) {
Please login to merge, or discard this patch.
include/version.php 1 patch
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -1,12 +1,12 @@
 block discarded – undo
1 1
 <?php
2 2
 /**
3
- * Contains the version information of the SmartObject Framework
4
- *
5
- * @license    GNU
6
- * @author     marcan <[email protected]>
7
- * @link       http://smartfactory.ca The SmartFactory
8
- * @package    SmartObject
9
- * @subpackage SmartObjectCore
10
- */
3
+	 * Contains the version information of the SmartObject Framework
4
+	 *
5
+	 * @license    GNU
6
+	 * @author     marcan <[email protected]>
7
+	 * @link       http://smartfactory.ca The SmartFactory
8
+	 * @package    SmartObject
9
+	 * @subpackage SmartObjectCore
10
+	 */
11 11
 
12 12
 define('SMARTOBJECT_VERSION', 1.0);
Please login to merge, or discard this patch.
include/customtag.php 2 patches
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -10,16 +10,16 @@
 block discarded – undo
10 10
 
11 11
 function smart_customtag_initiate()
12 12
 {
13
-    global $xoopsTpl, $smartobjectCustomtagHandler;
14
-    if (is_object($xoopsTpl)) {
15
-        foreach ($smartobjectCustomtagHandler->objects as $k => $v) {
16
-            $xoopsTpl->assign($k, $v->render());
17
-        }
18
-    }
13
+	global $xoopsTpl, $smartobjectCustomtagHandler;
14
+	if (is_object($xoopsTpl)) {
15
+		foreach ($smartobjectCustomtagHandler->objects as $k => $v) {
16
+			$xoopsTpl->assign($k, $v->render());
17
+		}
18
+	}
19 19
 }
20 20
 
21 21
 if (!defined('SMARTOBJECT_URL')) {
22
-    include_once(XOOPS_ROOT_PATH . '/modules/smartobject/include/common.php');
22
+	include_once(XOOPS_ROOT_PATH . '/modules/smartobject/include/common.php');
23 23
 }
24 24
 
25 25
 smart_loadLanguageFile('smartobject', 'customtag');
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,4 +28,4 @@
 block discarded – undo
28 28
 include_once(SMARTOBJECT_ROOT_PATH . 'class/customtag.php');
29 29
 
30 30
 $smartobjectCustomtagHandler = xoops_getModuleHandler('customtag', 'smartobject');
31
-$smartobjectCustomTagsObj     = $smartobjectCustomtagHandler->getCustomtagsByName();
31
+$smartobjectCustomTagsObj = $smartobjectCustomtagHandler->getCustomtagsByName();
Please login to merge, or discard this patch.
include/projax/projax.php 1 patch
Indentation   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -14,15 +14,15 @@
 block discarded – undo
14 14
  */
15 15
 
16 16
 if (!class_exists('Projax')) {
17
-    include __DIR__ . '/classes/JavaScript.php';
18
-    include 'classes/Prototype.php';
19
-    include 'classes/Scriptaculous.php';
17
+	include __DIR__ . '/classes/JavaScript.php';
18
+	include 'classes/Prototype.php';
19
+	include 'classes/Scriptaculous.php';
20 20
 
21
-    // For $projax = new Projax();
22
-    /**
23
-     * Class projax
24
-     */
25
-    class projax extends Scriptaculous
26
-    {
27
-    }
21
+	// For $projax = new Projax();
22
+	/**
23
+	 * Class projax
24
+	 */
25
+	class projax extends Scriptaculous
26
+	{
27
+	}
28 28
 }
Please login to merge, or discard this patch.
include/currency.php 1 patch
Indentation   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -17,13 +17,13 @@
 block discarded – undo
17 17
 $smartobjectCurrencyHandler = xoops_getModuleHandler('currency', 'smartobject');
18 18
 
19 19
 if (!$smartobjectCurrenciesObj) {
20
-    $smartobjectCurrenciesObj = $smartobjectCurrencyHandler->getCurrencies();
20
+	$smartobjectCurrenciesObj = $smartobjectCurrencyHandler->getCurrencies();
21 21
 }
22 22
 if (!$smartobjectCurrenciesArray) {
23
-    foreach ($smartobjectCurrenciesObj as $currencyid => $currencyObj) {
24
-        if ($currencyObj->getVar('default_currency', 'e')) {
25
-            $smartobjectDefaultCurrency = $currencyObj;
26
-        }
27
-        $smartobjectCurrenciesArray[$currencyid] = $currencyObj->getCode();
28
-    }
23
+	foreach ($smartobjectCurrenciesObj as $currencyid => $currencyObj) {
24
+		if ($currencyObj->getVar('default_currency', 'e')) {
25
+			$smartobjectDefaultCurrency = $currencyObj;
26
+		}
27
+		$smartobjectCurrenciesArray[$currencyid] = $currencyObj->getCode();
28
+	}
29 29
 }
Please login to merge, or discard this patch.