Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Geeklog-Core/geeklog
Browse files Browse the repository at this point in the history
  • Loading branch information
mystralkk committed Nov 12, 2019
2 parents 5ebf311 + 05e3e9d commit 0d029fc
Show file tree
Hide file tree
Showing 10 changed files with 44 additions and 42 deletions.
18 changes: 9 additions & 9 deletions language/english.php
Expand Up @@ -310,22 +310,22 @@
37 => 'Applied to your comments and other posts which support signatures',
38 => 'It\'s all about you! Everyone can read this',
39 => 'Your public PGP key to share',
40 => 'No Topic Icons',
40 => 'Disable Topic Icons',
41 => 'Willing to Moderate',
42 => 'Date Format',
43 => 'Maximum Articles',
44 => 'No boxes',
44 => 'Required Core System Blocks Only',
45 => 'Display Preferences for',
46 => 'Excluded Items for',
47 => 'News box Configuration for',
48 => 'Topics',
49 => 'No icons in articles',
49 => 'Topics with icons will not display on Topic and Article pages',
50 => 'Uncheck this if you aren\'t interested',
51 => 'Just the news articles',
51 => 'This will only display Blocks that are deemed absolutely necessary to use the website',
52 => 'The default is',
53 => 'Receive the days articles every night',
54 => 'Check the boxes for the topics and authors you don\'t want to see.',
55 => 'If you leave these all unchecked, it means you want the default selection of boxes. If you start selecting boxes, remember to set all of them that you want because the default selection will be ignored. Default entries are displayed in bold.',
54 => 'Check the boxes for the topics and authors you don\'t want to see. Please note that filtering a parent topic will also filter all child topics.',
55 => 'If all Blocks are unchecked, then all Blocks will be displayed. If you check 1 or more Blocks, then these are the only Blocks that will be displayed along with any Dynamic Plugin Blocks, and required Core System Blocks. Bold Blocks are Core System Blocks that you can enable or disable. <em>Please note that if the "Required Core System Blocks Only" setting is checked, then the first Blocks filter setting is ignored.</em>',
56 => 'Authors',
57 => 'Display Mode',
58 => 'Sort Order',
Expand Down Expand Up @@ -400,20 +400,20 @@
128 => 'Your Name',
129 => 'Password &amp; Email',
130 => 'About You',
131 => 'Daily Digest Options',
131 => 'Daily Digest Settings',
132 => 'Daily Digest Feature',
133 => 'Comment Display',
134 => 'Comment Options',
135 => '<li>Default mode for how comments will be displayed</li><li>Default order to display comments</li><li>Set maximum number of comments to show - default is 100</li>',
136 => 'Exclude Topics and Authors',
136 => 'Topics and Authors Filter',
137 => 'Filter Article Content',
138 => 'Misc Settings',
139 => 'Layout and Language',
140 => '<li>No Topic Icons if checked will not display the article topic icons</li><li>No boxes if checked will only show the Admin Menu, User Menu and Topics</li><li>Set the maximum number of articles to show per page</li><li>Set your theme, timezone and preferred date format</li>',
141 => 'Privacy Settings',
142 => 'The default setting is to allow users &amp; admins to email fellow site members and show your status as online. Un-check these options to protect your privacy.',
143 => 'Filter Block Content',
144 => 'Show &amp; hide boxes',
144 => 'Blocks Filter',
145 => 'Your Public Profile',
146 => 'Password and email',
147 => 'Password fields for non-remote accounts only. Edit your account password, email and autologin feature. You will need to enter the same password or email address twice as a confirmation.',
Expand Down
18 changes: 9 additions & 9 deletions language/english_utf-8.php
Expand Up @@ -310,22 +310,22 @@
37 => 'Applied to your comments and other posts which support signatures',
38 => 'It\'s all about you! Everyone can read this',
39 => 'Your public PGP key to share',
40 => 'No Topic Icons',
40 => 'Disable Topic Icons',
41 => 'Willing to Moderate',
42 => 'Date Format',
43 => 'Maximum Articles',
44 => 'No boxes',
44 => 'Required Core System Blocks Only',
45 => 'Display Preferences for',
46 => 'Excluded Items for',
47 => 'News box Configuration for',
48 => 'Topics',
49 => 'No icons in articles',
49 => 'Topics with icons will not display on Topic and Article pages',
50 => 'Uncheck this if you aren\'t interested',
51 => 'Just the news articles',
51 => 'This will only display Blocks that are deemed absolutely necessary to use the website',
52 => 'The default is',
53 => 'Receive the days articles every night',
54 => 'Check the boxes for the topics and authors you don\'t want to see.',
55 => 'If you leave these all unchecked, it means you want the default selection of boxes. If you start selecting boxes, remember to set all of them that you want because the default selection will be ignored. Default entries are displayed in bold.',
54 => 'Check the boxes for the topics and authors you don\'t want to see. Please note that filtering a parent topic will also filter all child topics.',
55 => 'If all Blocks are unchecked, then all Blocks will be displayed. If you check 1 or more Blocks, then these are the only Blocks that will be displayed along with any Dynamic Plugin Blocks, and required Core System Blocks. Bold Blocks are Core System Blocks that you can enable or disable. <em>Please note that if the "Required Core System Blocks Only" setting is checked, then the first Blocks filter setting is ignored.</em>',
56 => 'Authors',
57 => 'Display Mode',
58 => 'Sort Order',
Expand Down Expand Up @@ -400,20 +400,20 @@
128 => 'Your Name',
129 => 'Password &amp; Email',
130 => 'About You',
131 => 'Daily Digest Options',
131 => 'Daily Digest Settings',
132 => 'Daily Digest Feature',
133 => 'Comment Display',
134 => 'Comment Options',
135 => '<li>Default mode for how comments will be displayed</li><li>Default order to display comments</li><li>Set maximum number of comments to show - default is 100</li>',
136 => 'Exclude Topics and Authors',
136 => 'Topics and Authors Filter',
137 => 'Filter Article Content',
138 => 'Misc Settings',
139 => 'Layout and Language',
140 => '<li>No Topic Icons if checked will not display the article topic icons</li><li>No boxes if checked will only show the Admin Menu, User Menu and Topics</li><li>Set the maximum number of articles to show per page</li><li>Set your theme, timezone and preferred date format</li>',
141 => 'Privacy Settings',
142 => 'The default setting is to allow users &amp; admins to email fellow site members and show your status as online. Un-check these options to protect your privacy.',
143 => 'Filter Block Content',
144 => 'Show &amp; hide boxes',
144 => 'Blocks Filter',
145 => 'Your Public Profile',
146 => 'Password and email',
147 => 'Password fields for non-remote accounts only. Edit your account password, email and autologin feature. You will need to enter the same password or email address twice as a confirmation.',
Expand Down
3 changes: 3 additions & 0 deletions public_html/layout/denim/preferences/boxesblock.thtml
Expand Up @@ -17,6 +17,9 @@
<dl class="form_block">
<dt><label>{lang_blocks}</label></dt>
<dd><div id="exclude_blocks" class="uk-scrollable-box">{boxes_checklist}</div></dd>

<dt><label for="displayprefs-noboxes">{lang_noboxes}</label></dt>
<dd class="controls_text"><label><input type="checkbox" {noboxes_checked} name="noboxes" id="displayprefs-noboxes"{xhtml}>{lang_noboxes_text}</label></dd>
</dl>
</div>
</fieldset>
Expand Down
3 changes: 0 additions & 3 deletions public_html/layout/denim/preferences/displayblock.thtml
Expand Up @@ -21,9 +21,6 @@
<dt><label for="displayprefs-noicons">{lang_noicons}</label></dt>
<dd class="controls_text"><label><input type="checkbox" {noicons_checked} name="noicons" id="displayprefs-noicons"{xhtml}>{lang_noicons_text}</label></dd>

<dt><label for="displayprefs-noboxes">{lang_noboxes}</label></dt>
<dd class="controls_text"><label><input type="checkbox" {noboxes_checked} name="noboxes" id="displayprefs-noboxes"{xhtml}>{lang_noboxes_text}</label></dd>

<dt><label for="displayprefs-maxstories">{lang_maxstories}</label></dt>
<dd><input type="text" maxlength="3" value="{maxstories_value}" name="maxstories" id="displayprefs-maxstories" class="size1"{xhtml}></dd>

Expand Down
3 changes: 3 additions & 0 deletions public_html/layout/denim_three/preferences/boxesblock.thtml
Expand Up @@ -17,6 +17,9 @@
<dl class="form_block">
<dt><label>{lang_blocks}</label></dt>
<dd><div id="exclude_blocks" class="uk-panel uk-panel-scrollable">{boxes_checklist}</div></dd>

<dt><label for="displayprefs-noboxes">{lang_noboxes}</label></dt>
<dd class="controls_text"><label><input type="checkbox" {noboxes_checked} name="noboxes" id="displayprefs-noboxes" class="uk-checkbox"{xhtml}>{lang_noboxes_text}</label></dd>
</dl>
</div>
</fieldset>
Expand Down
3 changes: 0 additions & 3 deletions public_html/layout/denim_three/preferences/displayblock.thtml
Expand Up @@ -21,9 +21,6 @@
<dt><label for="displayprefs-noicons">{lang_noicons}</label></dt>
<dd class="controls_text"><label><input type="checkbox" {noicons_checked} name="noicons" id="displayprefs-noicons" class="uk-checkbox"{xhtml}>{lang_noicons_text}</label></dd>

<dt><label for="displayprefs-noboxes">{lang_noboxes}</label></dt>
<dd class="controls_text"><label><input type="checkbox" {noboxes_checked} name="noboxes" id="displayprefs-noboxes" class="uk-checkbox"{xhtml}>{lang_noboxes_text}</label></dd>

<dt><label for="displayprefs-maxstories">{lang_maxstories}</label></dt>
<dd><input type="text" maxlength="3" value="{maxstories_value}" name="maxstories" id="displayprefs-maxstories" class="uk-input size1"{xhtml}></dd>

Expand Down
3 changes: 3 additions & 0 deletions public_html/layout/modern_curve/preferences/boxesblock.thtml
Expand Up @@ -11,6 +11,9 @@
<dl>
<dt>{lang_blocks}</dt>
<dd>{boxes_checklist}</dd>

<dt><label for="displayprefs-noboxes">{lang_noboxes}</label></dt>
<dd><input type="checkbox" {noboxes_checked} name="noboxes" id="displayprefs-noboxes" class="text"{xhtml}>{lang_noboxes_text}</dd>
</dl>
</fieldset>

Expand Down
Expand Up @@ -15,9 +15,6 @@
<dt><label for="displayprefs-noicons">{lang_noicons}</label></dt>
<dd><input type="checkbox" {noicons_checked} name="noicons" id="displayprefs-noicons" class="text"{xhtml}>{lang_noicons_text}</dd>

<dt><label for="displayprefs-noboxes">{lang_noboxes}</label></dt>
<dd><input type="checkbox" {noboxes_checked} name="noboxes" id="displayprefs-noboxes" class="text"{xhtml}>{lang_noboxes_text}</dd>

<dt><label for="displayprefs-maxstories">{lang_maxstories}</label></dt>
<dd><input type="text" size="3" maxlength="3" value="{maxstories_value}" name="maxstories" id="displayprefs-maxstories" class="text"{xhtml}></dd>

Expand Down
4 changes: 2 additions & 2 deletions public_html/lib-common.php
Expand Up @@ -4133,7 +4133,7 @@ function COM_formatBlock($A, $noBoxes = false, $noPosition = false)
} else {
// The only time cache_time would not be set if for dynamic blocks (they can handle their own caching if needed)
// Don't Cache default blocks either
if (isset($A['cache_time']) && (($A['cache_time'] > 0) || ($A['cache_time'] == -1))) {
if ((isset($A['cache_time']) && (($A['cache_time'] > 0) || ($A['cache_time'] == -1))) && !$noBoxes) {
$cacheInstance = 'block__' . $A['bid'] . '__' . CACHE_security_hash() . '__' . $_CONF['theme'];
$retval = CACHE_check_instance($cacheInstance);
if ($retval && ($A['cache_time'] == -1)) {
Expand All @@ -4150,7 +4150,7 @@ function COM_formatBlock($A, $noBoxes = false, $noPosition = false)
}
}

if ($A['type'] === 'portal') {
if ($A['type'] === 'portal' && !$noBoxes) {
COM_rdfImport($A['bid'], $A['rdfurl'], $A['rdflimit']);
$A['content'] = DB_getItem($_TABLES['blocks'], 'content', "bid = '{$A['bid']}'");
}
Expand Down
28 changes: 15 additions & 13 deletions public_html/usersettings.php
Expand Up @@ -474,8 +474,6 @@ function editpreferences()
$preferences->set_var('lang_misc_help', $LANG04[140]);
$preferences->set_var('lang_noicons', $LANG04[40]);
$preferences->set_var('lang_noicons_text', $LANG04[49]);
$preferences->set_var('lang_noboxes', $LANG04[44]);
$preferences->set_var('lang_noboxes_text', $LANG04[51]);
$preferences->set_var('lang_maxstories', $LANG04[43]);
if (strpos($LANG04[52], '%d') === false) {
$maxtext = $LANG04[52] . ' ' . $_CONF['limitnews'];
Expand All @@ -493,6 +491,8 @@ function editpreferences()
$preferences->set_var('lang_digest_help_header', $LANG04[132]);
$preferences->set_var('lang_boxes_title', $LANG04[144]);
$preferences->set_var('lang_boxes_help_title', $LANG04[143]);
$preferences->set_var('lang_noboxes', $LANG04[44]);
$preferences->set_var('lang_noboxes_text', $LANG04[51]);
$preferences->set_var('lang_boxes', $LANG04[55]);
$preferences->set_var('lang_blocks', $LANG04[151]);
$preferences->set_var('lang_displaymode', $LANG04[57]);
Expand Down Expand Up @@ -691,12 +691,6 @@ function editpreferences()
$preferences->set_var('noicons_checked', '');
}

if (isset($A['noboxes']) && $A['noboxes'] == '1') {
$preferences->set_var('noboxes_checked', 'checked="checked"');
} else {
$preferences->set_var('noboxes_checked', '');
}

$preferences->set_var('maxstories_value', $A['maxstories']);

$items = COM_optionList($_TABLES['dateformats'], 'dfid,description', $A['dfid']);
Expand Down Expand Up @@ -791,6 +785,13 @@ function editpreferences()
$preferences->set_var('digest_block', '');
}


if (isset($A['noboxes']) && $A['noboxes'] == '1') {
$preferences->set_var('noboxes_checked', 'checked="checked"');
} else {
$preferences->set_var('noboxes_checked', '');
}

// boxes block
$selectedblocks = '';
if (strlen($A['boxes']) > 0) {
Expand Down Expand Up @@ -1311,11 +1312,6 @@ function savepreferences($A)
} else {
$A['willing'] = 0;
}
if (isset($A['noboxes']) && ($A['noboxes'] === 'on')) {
$A['noboxes'] = 1;
} else {
$A['noboxes'] = 0;
}
if (isset($A['emailfromadmin']) && ($A['emailfromadmin'] === 'on')) {
$A['emailfromadmin'] = 1;
} else {
Expand Down Expand Up @@ -1363,6 +1359,12 @@ function savepreferences($A)
$AIDS = array_values($A['selauthors']); // array of integers
}

if (isset($A['noboxes']) && ($A['noboxes'] === 'on')) {
$A['noboxes'] = 1;
} else {
$A['noboxes'] = 0;
}

$BOXES = array();
if (isset($A['blocks']) && is_array($A['blocks'])) {
$BOXES = array_values($A['blocks']); // array of integers
Expand Down

0 comments on commit 0d029fc

Please sign in to comment.