function __construct() { $settings = Setting::getAll("groups"); foreach ($settings as $setting) { Setting::set($setting->name, getInput($setting->name)); } forward("admin/groups"); }
function __construct() { $settings = Setting::getAll("stripe"); foreach ($settings as $setting) { Setting::set($setting->name, getInput($setting->name)); } new SystemMessage("Your stripe settings have been saved."); forward(); }
* SocialApparatus CONFIDENTIAL * __________________ * * [2002] - [2017] SocialApparatus (http://SocialApparatus.co) * All Rights Reserved. * * NOTICE: All information contained herein is, and remains the property of SocialApparatus * and its suppliers, if any. The intellectual and technical concepts contained herein * are proprietary to SocialApparatus and its suppliers and may be covered by U.S. and Foreign * Patents, patents in process, and are protected by trade secret or copyright law. * * Dissemination of this information or reproduction of this material is strictly forbidden * unless prior written permission is obtained from SocialApparatus. * * Contact Shane Barron admin@socia.us for more information. */ namespace SocialApparatus; denyDirect(); $access = getIgnoreAccess(); setIgnoreAccess(); $system_settings = Setting::getAll("video_settings"); setIgnoreAccess($access); if ($system_settings) { foreach ($system_settings as $name => $setting) { echo display("input/" . $setting->field_type, array("name" => $setting->name, "value" => $setting->value, "class" => "form-control", "label" => isset($setting->label) ? $setting->label : translate("admin:video_settings:" . $setting->name), "options_values" => $setting->options)); } echo display("input/submit", array("class" => "btn btn-success", "label" => "Save")); } else { echo "<blockquote>These settings are created by plugins.</blockquote>"; }
<?php /* * *********************************************************************** * * SocialApparatus CONFIDENTIAL * __________________ * * [2002] - [2017] SocialApparatus (http://SocialApparatus.co) * All Rights Reserved. * * NOTICE: All information contained herein is, and remains the property of SocialApparatus * and its suppliers, if any. The intellectual and technical concepts contained herein * are proprietary to SocialApparatus and its suppliers and may be covered by U.S. and Foreign * Patents, patents in process, and are protected by trade secret or copyright law. * * Dissemination of this information or reproduction of this material is strictly forbidden * unless prior written permission is obtained from SocialApparatus. * * Contact Shane Barron admin@socia.us for more information. */ namespace SocialApparatus; denyDirect(); $settings = Setting::getAll("stripe"); foreach ($settings as $setting) { echo display("input/{$setting->field_type}", array("name" => $setting->name, "options_values" => $setting->options, "class" => "form-control", "label" => translate("admin_setting_label:" . $setting->name), "value" => $setting->value)); } echo display("input/submit", array("class" => "btn btn-success", "label" => "Save"));
/** * All settings are available in any template * @return void */ protected function assignSettings() { $aSettings = Setting::getAll(); $settings[] = array(); foreach ($aSettings as $oSetting) { $settings[$oSetting->name] = $oSetting->value; } $this->assign('settings', $settings); }
public function getSettings() { return Setting::getAll(array('setting_category_id' => $this->getId())); }
static function getAll($owner) { return Setting::getAll(USERDATA_OPTION, $owner); }
<?php /* * *********************************************************************** * * SocialApparatus CONFIDENTIAL * __________________ * * [2002] - [2017] SocialApparatus (http://SocialApparatus.co) * All Rights Reserved. * * NOTICE: All information contained herein is, and remains the property of SocialApparatus * and its suppliers, if any. The intellectual and technical concepts contained herein * are proprietary to SocialApparatus and its suppliers and may be covered by U.S. and Foreign * Patents, patents in process, and are protected by trade secret or copyright law. * * Dissemination of this information or reproduction of this material is strictly forbidden * unless prior written permission is obtained from SocialApparatus. * * Contact Shane Barron admin@socia.us for more information. */ namespace SocialApparatus; denyDirect(); $settings = Setting::getAll("groups"); foreach ($settings as $setting) { echo display("input/{$setting->field_type}", array("name" => $setting->name, "options_values" => $setting->options, "class" => "form-control", "label" => translate("admin_setting_label:" . $setting->name), "value" => $setting->value)); } echo display("input/submit", array("class" => "btn btn-success", "label" => "Save"));
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * THE SOFTWARE. * * * * @author Shane Barron <*****@*****.**> * @author Aaustin Barron <*****@*****.**> * @copyright 2015 SocialApparatus * @license http://opensource.org/licenses/MIT MIT * @version 1 * @link http://SocialApparatus.co */ namespace SocialApparatus; denyDirect(); $ecommerce_settings = Setting::getAll("ecommerce"); if ($ecommerce_settings) { foreach ($ecommerce_settings as $name => $setting) { if ($setting->value) { $value = $setting->value; } else { $value = $setting->default; } echo display("input/" . $setting->field_type, array("name" => $setting->name, "value" => $value, "class" => "form-control", "label" => translate("admin:ecommerce_settings:" . $setting->name), "options_values" => $setting->options)); } echo display("input/submit", array("class" => "btn btn-success", "label" => "Save")); }
* All Rights Reserved. * * NOTICE: All information contained herein is, and remains the property of SocialApparatus * and its suppliers, if any. The intellectual and technical concepts contained herein * are proprietary to SocialApparatus and its suppliers and may be covered by U.S. and Foreign * Patents, patents in process, and are protected by trade secret or copyright law. * * Dissemination of this information or reproduction of this material is strictly forbidden * unless prior written permission is obtained from SocialApparatus. * * Contact Shane Barron admin@socia.us for more information. */ namespace SocialApparatus; denyDirect(); $system_settings = Setting::getAll("general"); if ($system_settings) { foreach ($system_settings as $name => $setting) { $options_values = array(); if ($setting->value) { $value = $setting->value; } else { $value = $setting->default; } $options = $setting->options; if (is_array($options)) { foreach ($options as $key => $value2) { $options_values[$key] = translate($value2); } } echo display("input/" . $setting->field_type, array("name" => $setting->name, "value" => $value, "class" => "form-control", "label" => translate("admin:general_settings:" . $setting->name), "options_values" => $options_values));
public function indexAction() { $settings = Setting::getAll(); $this->view->settings = $settings; }
/* * *********************************************************************** * * SocialApparatus CONFIDENTIAL * __________________ * * [2002] - [2017] SocialApparatus (http://SocialApparatus.co) * All Rights Reserved. * * NOTICE: All information contained herein is, and remains the property of SocialApparatus * and its suppliers, if any. The intellectual and technical concepts contained herein * are proprietary to SocialApparatus and its suppliers and may be covered by U.S. and Foreign * Patents, patents in process, and are protected by trade secret or copyright law. * * Dissemination of this information or reproduction of this material is strictly forbidden * unless prior written permission is obtained from SocialApparatus. * * Contact Shane Barron admin@socia.us for more information. */ namespace SocialApparatus; denyDirect(); $add_this_settings = Setting::getAll("addthis"); if ($add_this_settings) { foreach ($add_this_settings as $name => $setting) { echo display("input/" . $setting->field_type, array("name" => $setting->name, "value" => $setting->value, "class" => "form-control", "label" => translate("admin:general_settings:" . $setting->name), "options_values" => $setting->options)); } echo display("input/submit", array("class" => "btn btn-success", "label" => "Save")); } else { echo "<blockquote>These settings are created by plugins.</blockquote>"; }
protected function showSettings() { switch ($this->mode) { case 'bewerken': $oSetting = new Setting($this->editId); //$this->assign('backUrl', '/beheer/instellingen/'); $this->editObject($oSetting); break; default: $aSettingCategories = SettingCategory::getAll(null, 'id'); $aSettings = Setting::getAll(array('setting_category_id' => 0)); $this->assign('aSettingCategories', $aSettingCategories); $this->assign('aSettings', $aSettings); $this->template = '/instellingen.tpl'; $this->showOutput(); } }
* * [2002] - [2007] SocialApparatus (http://SocialApparatus.co) * All Rights Reserved. * * NOTICE: All information contained herein is, and remains the property of SocialApparatus * and its suppliers, if any. The intellectual and technical concepts contained herein * are proprietary to SocialApparatus and its suppliers and may be covered by U.S. and Foreign * Patents, patents in process, and are protected by trade secret or copyright law. * * Dissemination of this information or reproduction of this material is strictly forbidden * unless prior written permission is obtained from SocialApparatus. * * Contact Shane Barron admin@socia.us for more information. */ namespace SocialApparatus; denyDirect(); $system_settings = Setting::getAll("adsense"); if ($system_settings) { foreach ($system_settings as $name => $setting) { if ($setting->value) { $value = $setting->value; } else { $value = $setting->default; } echo display("input/" . $setting->field_type, array("name" => $setting->name, "value" => $value, "class" => "form-control", "label" => translate("admin:adsense_settings:" . $setting->name), "options_values" => $setting->options)); } echo display("input/submit", array("class" => "btn btn-success", "label" => "Save")); } else { echo "<blockquote>These settings are created by plugins.</blockquote>"; }
/** * @return 2d array of all settings for owner */ static function getAll($owner) { return Setting::getAll(USER, $owner); }