X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=randplace%2Frandplace.php;h=27589b1ceceb756ac52e144254e892b17b802bf0;hb=af2c630808c77fe689743a39d25c936111500e45;hp=35503850f7058134c9bb75e051c16e5ee224af92;hpb=858758e92c5d8c1c41e188284fea53ae50fb0855;p=friendica-addons.git diff --git a/randplace/randplace.php b/randplace/randplace.php index 35503850..27589b1c 100755 --- a/randplace/randplace.php +++ b/randplace/randplace.php @@ -8,10 +8,8 @@ * * * - * Addons are registered with the system in the - * .htconfig.php file. - * - * $a->config['system']['addon'] = 'plugin1,plugin2,etc.'; + * Addons are registered with the system through the admin + * panel. * * When registration is detected, the system calls the plugin * name_install() function, located in 'addon/name/name.php', @@ -136,7 +134,8 @@ function randplace_post_hook($a, &$item) { function randplace_settings_post($a,$post) { if(! local_user()) return; - set_pconfig(local_user(),'randplace','enable',intval($_POST['randplace'])); + if($_POST['randplace-submit']) + set_pconfig(local_user(),'randplace','enable',intval($_POST['randplace'])); } @@ -175,6 +174,6 @@ function randplace_settings(&$a,&$s) { /* provide a submit button */ - $s .= '
'; + $s .= '
'; }