aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Settings
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-12-28 15:12:20 -0800
committerzotlabs <mike@macgirvin.com>2017-12-28 15:12:20 -0800
commit5cfb63da50f21f0f9591599cde476b575cb1266e (patch)
treeb2b78ed83649c57dfbe3d76b8ec61814a887f329 /Zotlabs/Module/Settings
parent38646fe0e1302b3be932a4d59e9431c7afe5c847 (diff)
downloadvolse-hubzilla-5cfb63da50f21f0f9591599cde476b575cb1266e.tar.gz
volse-hubzilla-5cfb63da50f21f0f9591599cde476b575cb1266e.tar.bz2
volse-hubzilla-5cfb63da50f21f0f9591599cde476b575cb1266e.zip
a different (hopefully better) implementation of affinity presets, but not for 3.0 because strings have changed.
Diffstat (limited to 'Zotlabs/Module/Settings')
-rw-r--r--Zotlabs/Module/Settings/Featured.php12
1 files changed, 4 insertions, 8 deletions
diff --git a/Zotlabs/Module/Settings/Featured.php b/Zotlabs/Module/Settings/Featured.php
index 6a8d10b2d..9c5a7b16c 100644
--- a/Zotlabs/Module/Settings/Featured.php
+++ b/Zotlabs/Module/Settings/Featured.php
@@ -17,12 +17,8 @@ class Featured {
$cmin = intval($_POST['affinity_cmin']);
if($cmin < 0 || $cmin > 99)
$cmin = 0;
- if($cmin !== 0 || $cmax !== 99) {
- set_pconfig(local_channel(),'system','network_page_default','cmin=' . $cmin . '&cmax=' . $cmax);
- }
- else {
- set_pconfig(local_channel(),'system','network_page_default','');
- }
+ set_pconfig(local_channel(),'affinity','cmin',$cmin);
+ set_pconfig(local_channel(),'affinity','cmax',$cmax);
info( t('Affinity Slider settings updated.') . EOL);
@@ -46,12 +42,12 @@ class Featured {
$cmax = intval(get_pconfig(local_channel(),'affinity','cmax'));
$cmax = (($cmax) ? $cmax : 99);
$setting_fields .= replace_macros(get_markup_template('field_input.tpl'), array(
- '$field' => array('affinity_cmax', t('Default maximum affinity level'), $cmax, '')
+ '$field' => array('affinity_cmax', t('Default maximum affinity level'), $cmax, t('0-99 default 99'))
));
$cmin = intval(get_pconfig(local_channel(),'affinity','cmin'));
$cmin = (($cmin) ? $cmin : 0);
$setting_fields .= replace_macros(get_markup_template('field_input.tpl'), array(
- '$field' => array('affinity_cmin', t('Default minimum affinity level'), $cmin, '')
+ '$field' => array('affinity_cmin', t('Default minimum affinity level'), $cmin, t('0-99 - default 0'))
));
$settings_addons .= replace_macros(get_markup_template('generic_addon_settings.tpl'), array(