@@ -11,28 +11,28 @@ |
||
11 | 11 | $current_path = str_replace(strpos($current_path, "\\\\", 2) ? "\\\\" : DIRECTORY_SEPARATOR, '/', $current_path); |
12 | 12 | } |
13 | 13 | $url_arr = explode('/', strstr($current_path, '/modules/')); |
14 | -include XOOPS_ROOT_PATH . '/modules/' . $url_arr[2] . '/include/vars.php'; |
|
14 | +include XOOPS_ROOT_PATH.'/modules/'.$url_arr[2].'/include/vars.php'; |
|
15 | 15 | |
16 | -if (defined($GLOBALS['VAR_PREFIXU'] . '_LANG_EN_BLOCKS')) { |
|
16 | +if (defined($GLOBALS['VAR_PREFIXU'].'_LANG_EN_BLOCKS')) { |
|
17 | 17 | return; |
18 | 18 | } |
19 | -define($GLOBALS['VAR_PREFIXU'] . '_LANG_EN_BLOCKS', 1); |
|
19 | +define($GLOBALS['VAR_PREFIXU'].'_LANG_EN_BLOCKS', 1); |
|
20 | 20 | |
21 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TYPE', 'Type'); |
|
22 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TYPE_TIME', 'Publish time'); |
|
23 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TYPE_VIEWS', 'Views'); |
|
24 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TYPE_RATES', 'Rate times'); |
|
25 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TYPE_RATING', 'Rating'); |
|
26 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TYPE_RANDOM', 'Random'); |
|
27 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TYPE_BOOKMARKS', 'Bookmarks'); |
|
28 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TYPE_FEATURED', 'Featured'); |
|
29 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_ITEMS', 'Item count'); |
|
30 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TITLE_LENGTH', 'Title length'); |
|
31 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TIMEFORMAT', 'Time format'); |
|
32 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TIMEFORMAT_CUSTOM', 'Custom'); |
|
33 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_SUMMARY_LENGTH', 'Show summary length'); |
|
34 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_SHOWDESC', 'Show description'); |
|
35 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_CATEGORYLIST', 'Allowed categories'); |
|
21 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TYPE', 'Type'); |
|
22 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TYPE_TIME', 'Publish time'); |
|
23 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TYPE_VIEWS', 'Views'); |
|
24 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TYPE_RATES', 'Rate times'); |
|
25 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TYPE_RATING', 'Rating'); |
|
26 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TYPE_RANDOM', 'Random'); |
|
27 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TYPE_BOOKMARKS', 'Bookmarks'); |
|
28 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TYPE_FEATURED', 'Featured'); |
|
29 | +define($GLOBALS['VAR_PREFIXU'].'_MB_ITEMS', 'Item count'); |
|
30 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TITLE_LENGTH', 'Title length'); |
|
31 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TIMEFORMAT', 'Time format'); |
|
32 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TIMEFORMAT_CUSTOM', 'Custom'); |
|
33 | +define($GLOBALS['VAR_PREFIXU'].'_MB_SUMMARY_LENGTH', 'Show summary length'); |
|
34 | +define($GLOBALS['VAR_PREFIXU'].'_MB_SHOWDESC', 'Show description'); |
|
35 | +define($GLOBALS['VAR_PREFIXU'].'_MB_CATEGORYLIST', 'Allowed categories'); |
|
36 | 36 | |
37 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_AUTHOR', 'Author'); |
|
38 | -define($GLOBALS['VAR_PREFIXU'] . '_MB_TIME', 'Time'); |
|
37 | +define($GLOBALS['VAR_PREFIXU'].'_MB_AUTHOR', 'Author'); |
|
38 | +define($GLOBALS['VAR_PREFIXU'].'_MB_TIME', 'Time'); |
@@ -32,8 +32,8 @@ |
||
32 | 32 | $current_path = str_replace(strpos($current_path, "\\\\", 2) ? "\\\\" : DIRECTORY_SEPARATOR, '/', $current_path); |
33 | 33 | } |
34 | 34 | $url_arr = explode('/', strstr($current_path, '/modules/')); |
35 | -include XOOPS_ROOT_PATH . '/modules/' . $url_arr[2] . '/include/vars.php'; |
|
36 | -include XOOPS_ROOT_PATH . '/modules/' . $url_arr[2] . '/class/utility.php'; |
|
35 | +include XOOPS_ROOT_PATH.'/modules/'.$url_arr[2].'/include/vars.php'; |
|
36 | +include XOOPS_ROOT_PATH.'/modules/'.$url_arr[2].'/class/utility.php'; |
|
37 | 37 | //require_once XOOPS_ROOT_PATH . '/modules/' . $GLOBALS['moddirname'] . '/include/functions.php'; |
38 | 38 | |
39 | 39 | /** |
@@ -26,7 +26,7 @@ discard block |
||
26 | 26 | // ------------------------------------------------------------------------ // |
27 | 27 | use Xmf\Request; |
28 | 28 | |
29 | -include __DIR__ . '/header.php'; |
|
29 | +include __DIR__.'/header.php'; |
|
30 | 30 | |
31 | 31 | $rate = Request::getInt('rate', Request::getInt('rate', 0, 'POST'), 'GET'); //(int)(!empty($_POST['rate']) ? $_POST['rate'] : (!empty($_GET['rate']) ? $_GET['rate'] : 0)); |
32 | 32 | $article_id = Request::getInt('article', Request::getInt('article', 0, 'POST'), 'GET'); //(int)(!empty($_POST['article']) ? $_POST['article'] : (!empty($_GET['article']) ? $_GET['article'] : 0)); |
@@ -40,28 +40,28 @@ discard block |
||
40 | 40 | $blogHandler = xoops_getModuleHandler('blog', $GLOBALS['moddirname']); |
41 | 41 | if (empty($xoopsModuleConfig['anonymous_rate']) && !is_object($xoopsUser)) { |
42 | 42 | $message = planet_constant('MD_NOACCESS'); |
43 | -} else { |
|
43 | +}else { |
|
44 | 44 | $uid = is_object($xoopsUser) ? $xoopsUser->getVar('uid') : 0; |
45 | 45 | $ip = PlanetUtility::planetGetIP(); |
46 | - if ($article_id > 0) { |
|
46 | + if ($article_id>0) { |
|
47 | 47 | $criteria = new CriteriaCompo(new Criteria('art_id', $article_id)); |
48 | - } else { |
|
48 | + }else { |
|
49 | 49 | $criteria = new CriteriaCompo(new Criteria('blog_id', $blog_id)); |
50 | 50 | } |
51 | - if ($uid > 0) { |
|
51 | + if ($uid>0) { |
|
52 | 52 | $criteria->add(new Criteria('rate_uid', $uid)); |
53 | - } else { |
|
53 | + }else { |
|
54 | 54 | $criteria->add(new Criteria('rate_ip', $ip)); |
55 | - $criteria->add(new Criteria('rate_time', time() - 24 * 3600, '>')); |
|
55 | + $criteria->add(new Criteria('rate_time', time()-24*3600, '>')); |
|
56 | 56 | } |
57 | 57 | $rateHandler = xoops_getModuleHandler('rate', $GLOBALS['moddirname']); |
58 | 58 | if ($count = $rateHandler->getCount($criteria)) { |
59 | 59 | $message = planet_constant('MD_ALREADYRATED'); |
60 | - } else { |
|
60 | + }else { |
|
61 | 61 | $rate_obj = $rateHandler->create(); |
62 | - if ($article_id > 0) { |
|
62 | + if ($article_id>0) { |
|
63 | 63 | $rate_obj->setVar('art_id', $article_id); |
64 | - } else { |
|
64 | + }else { |
|
65 | 65 | $rate_obj->setVar('blog_id', $blog_id); |
66 | 66 | } |
67 | 67 | $rate_obj->setVar('rate_uid', $uid); |
@@ -71,23 +71,23 @@ discard block |
||
71 | 71 | if (!$rate_id = $rateHandler->insert($rate_obj, true)) { |
72 | 72 | redirect_header('javascript:history.go(-1);', 1, planet_constant('MD_NOTSAVED')); |
73 | 73 | } |
74 | - if ($article_id > 0) { |
|
74 | + if ($article_id>0) { |
|
75 | 75 | $article_obj = $articleHandler->get($article_id); |
76 | - $article_obj->setVar('art_rating', $article_obj->getVar('art_rating') + $rate); |
|
77 | - $article_obj->setVar('art_rates', $article_obj->getVar('art_rates') + 1); |
|
76 | + $article_obj->setVar('art_rating', $article_obj->getVar('art_rating')+$rate); |
|
77 | + $article_obj->setVar('art_rates', $article_obj->getVar('art_rates')+1); |
|
78 | 78 | $articleHandler->insert($article_obj, true); |
79 | - } else { |
|
79 | + }else { |
|
80 | 80 | $blog_obj = $blogHandler->get($blog_id); |
81 | - $blog_obj->setVar('blog_rating', $blog_obj->getVar('blog_rating') + $rate); |
|
82 | - $blog_obj->setVar('blog_rates', $blog_obj->getVar('blog_rates') + 1); |
|
81 | + $blog_obj->setVar('blog_rating', $blog_obj->getVar('blog_rating')+$rate); |
|
82 | + $blog_obj->setVar('blog_rates', $blog_obj->getVar('blog_rates')+1); |
|
83 | 83 | $blogHandler->insert($blog_obj, true); |
84 | 84 | } |
85 | 85 | $message = planet_constant('MD_ACTIONDONE'); |
86 | 86 | } |
87 | 87 | } |
88 | -if ($article_id > 0) { |
|
89 | - redirect_header(XOOPS_URL . '/modules/' . $GLOBALS['moddirname'] . '/view.article.php' . URL_DELIMITER . '' . $article_id, 2, $message); |
|
90 | -} else { |
|
91 | - redirect_header(XOOPS_URL . '/modules/' . $GLOBALS['moddirname'] . '/index.php' . URL_DELIMITER . 'b' . $blog_id, 2, $message); |
|
88 | +if ($article_id>0) { |
|
89 | + redirect_header(XOOPS_URL.'/modules/'.$GLOBALS['moddirname'].'/view.article.php'.URL_DELIMITER.''.$article_id, 2, $message); |
|
90 | +}else { |
|
91 | + redirect_header(XOOPS_URL.'/modules/'.$GLOBALS['moddirname'].'/index.php'.URL_DELIMITER.'b'.$blog_id, 2, $message); |
|
92 | 92 | } |
93 | -include __DIR__ . '/footer.php'; |
|
93 | +include __DIR__.'/footer.php'; |
@@ -29,7 +29,7 @@ discard block |
||
29 | 29 | define('PLANET_INI', 1); |
30 | 30 | } |
31 | 31 | |
32 | -require_once __DIR__ . '/../class/utility.php'; |
|
32 | +require_once __DIR__.'/../class/utility.php'; |
|
33 | 33 | /* |
34 | 34 | * The prefix for database table name prefix |
35 | 35 | * You can change to any term but be consistent with the table names in /sql/mysql.sql, and be unique , no conflict with other modules |
@@ -37,7 +37,7 @@ discard block |
||
37 | 37 | $GLOBALS['MOD_DB_PREFIX'] = 'planet'; |
38 | 38 | |
39 | 39 | /* You are not supposed to modify following contents */ |
40 | -defined('FRAMEWORKS_ART_FUNCTIONS_INI') || require_once XOOPS_ROOT_PATH . '/Frameworks/art/functions.ini.php'; |
|
40 | +defined('FRAMEWORKS_ART_FUNCTIONS_INI') || require_once XOOPS_ROOT_PATH.'/Frameworks/art/functions.ini.php'; |
|
41 | 41 | $GLOBALS['moddirname'] = mod_getDirname(__FILE__); |
42 | 42 | |
43 | 43 | /* |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | * You can change to any term but be capital and unique, no conflict with other modules |
52 | 52 | */ |
53 | 53 | $GLOBALS['VAR_PREFIXU'] = strtoupper($GLOBALS['moddirname']); |
54 | -require_once XOOPS_ROOT_PATH . '/modules/' . $GLOBALS['moddirname'] . '/include/functions.ini.php'; |
|
54 | +require_once XOOPS_ROOT_PATH.'/modules/'.$GLOBALS['moddirname'].'/include/functions.ini.php'; |
|
55 | 55 | |
56 | 56 | // include customized variables |
57 | 57 | if (is_object($GLOBALS['xoopsModule']) && $GLOBALS['moddirname'] == $GLOBALS['xoopsModule']->getVar('dirname', 'n')) { |
@@ -26,21 +26,21 @@ discard block |
||
26 | 26 | // ------------------------------------------------------------------------ // |
27 | 27 | use Xmf\Request; |
28 | 28 | |
29 | -include __DIR__ . '/header.php'; |
|
29 | +include __DIR__.'/header.php'; |
|
30 | 30 | |
31 | 31 | // trackback is done by a POST |
32 | 32 | $art_id = explode('/', Request::getString('REQUEST_URI', '', 'SERVER')); |
33 | -$article_id = (int)$art_id[count($art_id) - 1]; |
|
34 | -$url = Request::getString('url', '', 'POST');//$_POST['url']; |
|
35 | -$title = Request::getString('title', '', 'POST');//$_POST['title']; |
|
36 | -$excerpt = Request::getString('excerpt', '', 'POST');//$_POST['excerpt']; |
|
37 | -$blog_name = Request::getString('blog_name', '', 'POST');//$_POST['blog_name']; |
|
38 | -$charset = trim(Request::getString('charset', '', 'POST'));//trim($_POST['charset']); |
|
33 | +$article_id = (int) $art_id[count($art_id)-1]; |
|
34 | +$url = Request::getString('url', '', 'POST'); //$_POST['url']; |
|
35 | +$title = Request::getString('title', '', 'POST'); //$_POST['title']; |
|
36 | +$excerpt = Request::getString('excerpt', '', 'POST'); //$_POST['excerpt']; |
|
37 | +$blog_name = Request::getString('blog_name', '', 'POST'); //$_POST['blog_name']; |
|
38 | +$charset = trim(Request::getString('charset', '', 'POST')); //trim($_POST['charset']); |
|
39 | 39 | |
40 | 40 | if (empty($xoopsModuleConfig['trackback_option'])) { |
41 | 41 | PlanetUtility::planetRespondToTrackback(1, 'Trackback is closed'); |
42 | 42 | } |
43 | -if (!strlen($title . $url . $blog_name)) { |
|
43 | +if (!strlen($title.$url.$blog_name)) { |
|
44 | 44 | PlanetUtility::planetRespondToTrackback(1, planet_constant('MD_INVALID')); |
45 | 45 | } |
46 | 46 | |
@@ -48,7 +48,7 @@ discard block |
||
48 | 48 | $trackbackHandler = xoops_getModuleHandler('trackback', $GLOBALS['moddirname']); |
49 | 49 | $criteria = new CriteriaCompo(new Criteria('art_id', $article_id)); |
50 | 50 | $criteria->add(new Criteria('tb_url', $url)); |
51 | - if ($trackbackHandler->getCount($criteria) > 0) { |
|
51 | + if ($trackbackHandler->getCount($criteria)>0) { |
|
52 | 52 | PlanetUtility::planetRespondToTrackback(1, 'We already have a ping from that URI for this article.'); |
53 | 53 | } |
54 | 54 | |
@@ -56,17 +56,17 @@ discard block |
||
56 | 56 | $title = XoopsLocal::convert_encoding($title, _CHARSET, $charset); |
57 | 57 | $excerpt = XoopsLocal::convert_encoding($excerpt, _CHARSET, $charset); |
58 | 58 | $blog_name = XoopsLocal::convert_encoding($blog_name, _CHARSET, $charset); |
59 | - $tb_status = (int)$xoopsModuleConfig['trackback_option']; |
|
59 | + $tb_status = (int) $xoopsModuleConfig['trackback_option']; |
|
60 | 60 | |
61 | 61 | $com_pid = 0; |
62 | 62 | $com_itemid = $article_id; |
63 | 63 | $com_rootid = 0; |
64 | 64 | $com_title = $title; |
65 | 65 | $com_text = $excerpt; |
66 | - $com_text .= "\n\n[TRACKBACK]" . _POSTEDBY . ': '; |
|
66 | + $com_text .= "\n\n[TRACKBACK]"._POSTEDBY.': '; |
|
67 | 67 | if (!empty($url)) { |
68 | - $com_text .= '[url=' . $url . ']' . $blog_name . '[/url]'; |
|
69 | - } else { |
|
68 | + $com_text .= '[url='.$url.']'.$blog_name.'[/url]'; |
|
69 | + }else { |
|
70 | 70 | $com_text .= $blog_name; |
71 | 71 | } |
72 | 72 | $com_modid = $xoopsModule->getVar('mid'); |
@@ -122,13 +122,13 @@ discard block |
||
122 | 122 | if (isset($comment_config['callbackFile'])) { |
123 | 123 | $callbackfile = trim($comment_config['callbackFile']); |
124 | 124 | if ($callbackfile != '' |
125 | - && file_exists(XOOPS_ROOT_PATH . '/modules/' . $moddir . '/' . $callbackfile)) { |
|
126 | - require_once XOOPS_ROOT_PATH . '/modules/' . $moddir . '/' . $callbackfile; |
|
125 | + && file_exists(XOOPS_ROOT_PATH.'/modules/'.$moddir.'/'.$callbackfile)) { |
|
126 | + require_once XOOPS_ROOT_PATH.'/modules/'.$moddir.'/'.$callbackfile; |
|
127 | 127 | } |
128 | 128 | if (!function_exists($comment_config['callback']['approve'])) { |
129 | 129 | $skip = true; |
130 | 130 | } |
131 | - } else { |
|
131 | + }else { |
|
132 | 132 | $skip = true; |
133 | 133 | } |
134 | 134 | } |
@@ -145,13 +145,13 @@ discard block |
||
145 | 145 | if (isset($comment_config['callbackFile'])) { |
146 | 146 | $callbackfile = trim($comment_config['callbackFile']); |
147 | 147 | if ($callbackfile != '' |
148 | - && file_exists(XOOPS_ROOT_PATH . '/modules/' . $moddir . '/' . $callbackfile)) { |
|
149 | - require_once XOOPS_ROOT_PATH . '/modules/' . $moddir . '/' . $callbackfile; |
|
148 | + && file_exists(XOOPS_ROOT_PATH.'/modules/'.$moddir.'/'.$callbackfile)) { |
|
149 | + require_once XOOPS_ROOT_PATH.'/modules/'.$moddir.'/'.$callbackfile; |
|
150 | 150 | } |
151 | 151 | if (!function_exists($comment_config['callback']['update'])) { |
152 | 152 | $skip = true; |
153 | 153 | } |
154 | - } else { |
|
154 | + }else { |
|
155 | 155 | $skip = true; |
156 | 156 | } |
157 | 157 | } |
@@ -181,16 +181,16 @@ discard block |
||
181 | 181 | $not_module = $xoopsModule; |
182 | 182 | if (!isset($comment_url)) { |
183 | 183 | $com_config = $not_module->getInfo('comments'); |
184 | - $comment_url = $com_config['pageName'] . '?'; |
|
184 | + $comment_url = $com_config['pageName'].'?'; |
|
185 | 185 | $comment_url .= $com_config['itemName']; |
186 | 186 | } |
187 | - $comment_tags['X_COMMENT_URL'] = XOOPS_URL . '/modules/' . $not_module->getVar('dirname') . '/' . $comment_url . '=' . $com_itemid . '&com_id=' . $newcid . '&com_rootid=' . $com_rootid . '&com_mode=' . $com_mode . '&com_order=' . $com_order . '#comment' . $newcid; |
|
187 | + $comment_tags['X_COMMENT_URL'] = XOOPS_URL.'/modules/'.$not_module->getVar('dirname').'/'.$comment_url.'='.$com_itemid.'&com_id='.$newcid.'&com_rootid='.$com_rootid.'&com_mode='.$com_mode.'&com_order='.$com_order.'#comment'.$newcid; |
|
188 | 188 | $notificationHandler = xoops_getHandler('notification'); |
189 | 189 | $notificationHandler->triggerEvent($not_category, $not_itemid, $not_event, $comment_tags, false, $not_modid); |
190 | 190 | } |
191 | 191 | |
192 | 192 | PlanetUtility::planetRespondToTrackback(0); |
193 | - } else { |
|
193 | + }else { |
|
194 | 194 | PlanetUtility::planetRespondToTrackback(1, xoops_error($comment->getHtmlErrors())); |
195 | 195 | } |
196 | 196 | } |
@@ -24,11 +24,11 @@ |
||
24 | 24 | // URL: https://xoops.org // |
25 | 25 | // Project: Article Project // |
26 | 26 | // ------------------------------------------------------------------------ // |
27 | -include __DIR__ . '/header.php'; |
|
28 | -$com_itemid = isset($_GET['com_itemid']) ? (int)$_GET['com_itemid'] : 0; |
|
29 | -if ($com_itemid > 0) { |
|
27 | +include __DIR__.'/header.php'; |
|
28 | +$com_itemid = isset($_GET['com_itemid']) ? (int) $_GET['com_itemid'] : 0; |
|
29 | +if ($com_itemid>0) { |
|
30 | 30 | $articleHandler = xoops_getModuleHandler('article', $GLOBALS['moddirname']); |
31 | 31 | $article_obj = $articleHandler->get($com_itemid); |
32 | 32 | $com_replytitle = $article_obj->getVar('art_title'); |
33 | - require_once XOOPS_ROOT_PATH . '/include/comment_new.php'; |
|
33 | + require_once XOOPS_ROOT_PATH.'/include/comment_new.php'; |
|
34 | 34 | } |
@@ -26,7 +26,7 @@ discard block |
||
26 | 26 | // ------------------------------------------------------------------------ // |
27 | 27 | use Xmf\Request; |
28 | 28 | |
29 | -include __DIR__ . '/header.php'; |
|
29 | +include __DIR__.'/header.php'; |
|
30 | 30 | |
31 | 31 | $blog_id = Request::getInt('blog', Request::getInt('blog', 0, 'POST'), 'GET'); //(int)(isset($_GET['blog']) ? $_GET['blog'] : (isset($_POST['blog']) ? $_POST['blog'] : 0)); |
32 | 32 | |
@@ -40,19 +40,19 @@ discard block |
||
40 | 40 | $criteria->add(new Criteria('bm_uid', $uid)); |
41 | 41 | if ($count = $bookmarkHandler->getCount($criteria)) { |
42 | 42 | $message = planet_constant('MD_ALREADYBOOKMARKED'); |
43 | - redirect_header(XOOPS_URL . '/modules/' . $GLOBALS['moddirname'] . '/index.php' . URL_DELIMITER . 'u' . $uid, 2, $message); |
|
43 | + redirect_header(XOOPS_URL.'/modules/'.$GLOBALS['moddirname'].'/index.php'.URL_DELIMITER.'u'.$uid, 2, $message); |
|
44 | 44 | } |
45 | 45 | $bookmark_obj = $bookmarkHandler->create(); |
46 | 46 | $bookmark_obj->setVar('blog_id', $blog_id); |
47 | 47 | $bookmark_obj->setVar('bm_uid', $uid); |
48 | 48 | if (!$bookmark_id = $bookmarkHandler->insert($bookmark_obj, true)) { |
49 | - redirect_header(XOOPS_URL . '/modules/' . $GLOBALS['moddirname'] . '/index.php' . URL_DELIMITER . 'b' . $blog_id, 2, planet_constant('MD_NOTSAVED')); |
|
49 | + redirect_header(XOOPS_URL.'/modules/'.$GLOBALS['moddirname'].'/index.php'.URL_DELIMITER.'b'.$blog_id, 2, planet_constant('MD_NOTSAVED')); |
|
50 | 50 | } |
51 | 51 | $blogHandler = xoops_getModuleHandler('blog', $GLOBALS['moddirname']); |
52 | 52 | $blog_obj = $blogHandler->get($blog_id); |
53 | -$marks = $blog_obj->getVar('blog_marks') + 1; |
|
54 | -$blog_obj->setVar('blog_marks', $blog_obj->getVar('blog_marks') + 1); |
|
53 | +$marks = $blog_obj->getVar('blog_marks')+1; |
|
54 | +$blog_obj->setVar('blog_marks', $blog_obj->getVar('blog_marks')+1); |
|
55 | 55 | $blogHandler->insert($blog_obj, true); |
56 | 56 | $message = planet_constant('MD_ACTIONDONE'); |
57 | -redirect_header(XOOPS_URL . '/modules/' . $GLOBALS['moddirname'] . '/index.php' . URL_DELIMITER . 'b' . $blog_id, 2, $message); |
|
58 | -include __DIR__ . '/footer.php'; |
|
57 | +redirect_header(XOOPS_URL.'/modules/'.$GLOBALS['moddirname'].'/index.php'.URL_DELIMITER.'b'.$blog_id, 2, $message); |
|
58 | +include __DIR__.'/footer.php'; |
@@ -29,21 +29,21 @@ discard block |
||
29 | 29 | |
30 | 30 | use Xmf\Request; |
31 | 31 | |
32 | -include __DIR__ . '/header.php'; |
|
32 | +include __DIR__.'/header.php'; |
|
33 | 33 | global $pdf_data; |
34 | 34 | if (!empty($_POST['pdf_data'])) { |
35 | 35 | $pdf_data = unserialize(base64_decode(Request::getText('pdf_data', '', 'POST'))); |
36 | 36 | } elseif (!empty($pdf_data)) { |
37 | -} else { |
|
37 | +}else { |
|
38 | 38 | error_reporting(0); |
39 | - include __DIR__ . '/header.php'; |
|
39 | + include __DIR__.'/header.php'; |
|
40 | 40 | error_reporting(0); |
41 | 41 | |
42 | 42 | if (PlanetUtility::planetParseArguments($args_num, $args, $args_str)) { |
43 | 43 | $args['article'] = @$args_num[0]; |
44 | 44 | } |
45 | 45 | |
46 | - $article_id = (int)(empty($_GET['article']) ? @$args['article'] : $_GET['article']); |
|
46 | + $article_id = (int) (empty($_GET['article']) ? @$args['article'] : $_GET['article']); |
|
47 | 47 | |
48 | 48 | $articleHandler = xoops_getModuleHandler('article', $GLOBALS['moddirname']); |
49 | 49 | $article_obj = $articleHandler->get($article_id); |
@@ -73,14 +73,14 @@ discard block |
||
73 | 73 | $pdf_data['date'] = $article_data['time']; |
74 | 74 | $pdf_data['content'] = ''; |
75 | 75 | if ($article_data['summary']) { |
76 | - $pdf_data['content'] .= planet_constant('MD_SUMMARY') . ': ' . $article_data['summary'] . '<br><br>'; |
|
76 | + $pdf_data['content'] .= planet_constant('MD_SUMMARY').': '.$article_data['summary'].'<br><br>'; |
|
77 | 77 | } |
78 | - $pdf_data['content'] .= $article_data['text'] . '<br>'; |
|
79 | - $pdf_data['url'] = XOOPS_URL . '/modules/' . $GLOBALS['artdirname'] . '/view.article.php' . URL_DELIMITER . $article_obj->getVar('art_id'); |
|
78 | + $pdf_data['content'] .= $article_data['text'].'<br>'; |
|
79 | + $pdf_data['url'] = XOOPS_URL.'/modules/'.$GLOBALS['artdirname'].'/view.article.php'.URL_DELIMITER.$article_obj->getVar('art_id'); |
|
80 | 80 | } |
81 | 81 | $pdf_data['filename'] = preg_replace("/[^0-9a-z\-_\.]/i", '', $pdf_data['title']); |
82 | 82 | |
83 | -include XOOPS_ROOT_PATH . '/Frameworks/fpdf/init.php'; |
|
83 | +include XOOPS_ROOT_PATH.'/Frameworks/fpdf/init.php'; |
|
84 | 84 | error_reporting(0); |
85 | 85 | ob_end_clean(); |
86 | 86 |
@@ -18,6 +18,6 @@ |
||
18 | 18 | */ |
19 | 19 | |
20 | 20 | $pathIcon32 = \Xmf\Module\Admin::iconUrl('', 32); |
21 | -echo "<div class='adminfooter'>\n" . " <div style='text-align: center;'>\n" . " <a href='https://xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n" . " </div>\n" . ' ' . _AM_MODULEADMIN_ADMIN_FOOTER . "\n" . '</div>'; |
|
21 | +echo "<div class='adminfooter'>\n"." <div style='text-align: center;'>\n"." <a href='https://xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n"." </div>\n".' '._AM_MODULEADMIN_ADMIN_FOOTER."\n".'</div>'; |
|
22 | 22 | |
23 | 23 | xoops_cp_footer(); |