X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=defaultfeatures%2Fdefaultfeatures.php;h=dfe4a067b45d1cdabe70d884e55e421859b3875e;hb=151a149bbf6938f48faf890b33d23c0ffa222128;hp=ad6a1816112ce4f11478fdee63a1a8e3fcc19fee;hpb=950154d6554695c89a0477f25ec8f9654bf87c38;p=friendica-addons.git diff --git a/defaultfeatures/defaultfeatures.php b/defaultfeatures/defaultfeatures.php index ad6a1816..dfe4a067 100755 --- a/defaultfeatures/defaultfeatures.php +++ b/defaultfeatures/defaultfeatures.php @@ -27,7 +27,7 @@ function defaultfeatures_register($a, $newuid) { } function defaultfeatures_plugin_admin_post (&$a) { - check_form_security_token_redirectOnErr('/admin/plugins/defaultfeatures', 'admin_themes'); + check_form_security_token_redirectOnErr('/admin/plugins/defaultfeatures', 'defaultfeaturessave'); foreach($_POST as $k => $v) { if(strpos($k,'feature_') === 0) { set_config('defaultfeatures',substr($k,8),((intval($v)) ? 1 : 0)); @@ -38,6 +38,7 @@ function defaultfeatures_plugin_admin_post (&$a) { function defaultfeatures_plugin_admin (&$a, &$o) { $t = get_markup_template( "admin.tpl", "addon/defaultfeatures/" ); + $token = get_form_security_token("defaultfeaturessave"); $arr = array(); $features = get_features(); foreach($features as $fname => $fdata) { @@ -51,7 +52,8 @@ function defaultfeatures_plugin_admin (&$a, &$o) { //logger("Features: " . print_r($arr,true)); $o = replace_macros($t, array( - '$submit' => t('Submit'), - '$features' => $arr + '$submit' => t('Save Settings'), + '$features' => $arr, + '$form_security_token' => $token )); }