X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=randplace%2Frandplace.php;h=b70c02d94ea731eddbab415b22536229a8c1b7ab;hb=9ac891c4949ea5a429fc59ada2816a992633ac1f;hp=35503850f7058134c9bb75e051c16e5ee224af92;hpb=58cce64c663c8105cae4879d4ba58170cee05c3e;p=friendica-addons.git diff --git a/randplace/randplace.php b/randplace/randplace.php index 35503850..b70c02d9 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 .= '
'; }