当前位置: 首页>>代码示例>>PHP>>正文


PHP Setting::getSiteSettings方法代码示例

本文整理汇总了PHP中Setting::getSiteSettings方法的典型用法代码示例。如果您正苦于以下问题:PHP Setting::getSiteSettings方法的具体用法?PHP Setting::getSiteSettings怎么用?PHP Setting::getSiteSettings使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Setting的用法示例。


在下文中一共展示了Setting::getSiteSettings方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: __construct

 public function __construct()
 {
     $this->user = Sentry::getUser();
     $this->isAdmin = User::isAdmin($this->user);
     $this->logged_in_for = $this->user->last_login->diffForHumans();
     $this->configs = Setting::getSiteSettings();
 }
开发者ID:shinichi81,项目名称:Nifty-Newsletter,代码行数:7,代码来源:SentEmailCustomController.php

示例2: index

 public function index()
 {
     $user = Sentry::getUser();
     $isAdmin = User::isAdmin($user);
     $configs = Setting::getSiteSettings();
     $logged_in_for = $user->last_login->diffForHumans();
     return View::make('backend.dashboards.index', ['user' => $user, 'isAdmin' => $isAdmin, 'configs' => $configs, 'logged_in_for' => $logged_in_for, 'activeParent' => 'index', 'active' => 'index']);
 }
开发者ID:shinichi81,项目名称:Nifty-Newsletter,代码行数:8,代码来源:DashboardController.php

示例3: __construct

 public function __construct()
 {
     $this->user = Sentry::getUser();
     $this->isAdmin = User::isAdmin($this->user);
     $this->logged_in_for = $this->user->last_login->diffForHumans();
     $this->configs = Setting::getSiteSettings();
     $this->paginate = Addressbook::getRecordsPerPage();
     $this->orderBy = Addressbook::getOrderBy();
     $this->cacheMinutes = 30;
     $this->rules = Addressbook::$rules;
     $this->activeParent = 'lists';
 }
开发者ID:shinichi81,项目名称:Nifty-Newsletter,代码行数:12,代码来源:AddressbookController.php

示例4: unsubscribe

 public function unsubscribe($id)
 {
     $subscriber = Subscriber::find((int) $id);
     if ($subscriber) {
         $subscriber->active = 0;
         $subscriber->save();
         $configs = Setting::getSiteSettings();
         return View::make('frontend.unsubscribe', ['subscriber' => $subscriber, 'configs' => $configs]);
     } else {
         echo 'User not found.';
     }
 }
开发者ID:shinichi81,项目名称:Nifty-Newsletter,代码行数:12,代码来源:FrontendController.php

示例5: __construct

 public function __construct()
 {
     $this->user = Sentry::getUser();
     $this->isAdmin = User::isAdmin($this->user);
     $this->logged_in_for = $this->user->last_login->diffForHumans();
     $this->configs = Setting::getSiteSettings();
     $this->paginate = User::getRecordsPerPage($this->user->id);
     $this->orderBy = User::getOrderBy($this->user->id);
     $this->rules = User::$rules;
     $this->editRules = User::$editRules;
     $this->newUserRules = User::$newUserRules;
     $this->activeParent = 'users';
 }
开发者ID:shinichi81,项目名称:Nifty-Newsletter,代码行数:13,代码来源:UserController.php

示例6: __construct

 public function __construct()
 {
     $this->user = Sentry::getUser();
     $this->isAdmin = User::isAdmin($this->user);
     $this->logged_in_for = $this->user->last_login->diffForHumans();
     $this->configs = Setting::getSiteSettings();
     $this->paginate = Maillist::getRecordsPerPage();
     $this->orderBy = Maillist::getOrderBy();
     $this->cacheMinutes = 30;
     $this->rules = Maillist::$rules;
     $this->activeParent = 'lists';
     $this->subscriberRules = Subscriber::$rules;
     $this->fileSizeRules = Subscriber::$fileRules;
 }
开发者ID:shinichi81,项目名称:Nifty-Newsletter,代码行数:14,代码来源:MaillistController.php

示例7: __construct

 public function __construct()
 {
     $this->user = Sentry::getUser();
     $this->isAdmin = User::isAdmin($this->user);
     $this->logged_in_for = $this->user->last_login->diffForHumans();
     $this->configs = Setting::getSiteSettings();
     // $this->paginate = Subscriber::getRecordsPerPage();
     // $this->orderBy = Subscriber::getOrderBy();
     // $this->cacheMinutes = 30;
     $this->rules = Email::$rules;
     $this->draftRules = Draft::$rules;
     // $this->editRules = Subscriber::$editRules;
     $this->activeParent = 'emails';
 }
开发者ID:shinichi81,项目名称:Nifty-Newsletter,代码行数:14,代码来源:EmailController.php

示例8: do_set

 public function do_set()
 {
     $rules = ['sitename' => 'required|max:255', 'sender_name' => 'required|max:510', 'sender_email' => 'required|email', 'reply_to_email' => 'required|email'];
     $validation = Jamesy\MyValidations::validate(Input::all(), $rules);
     if ($validation != NULL) {
         return Response::json(['validation' => $validation]);
     } else {
         $setting = Setting::getSiteSettings();
         $setting->sitename = Input::get('sitename');
         $setting->save();
         $user = Sentry::getUser();
         Setting::setFromName($user, Input::get('sender_name'));
         Setting::setFromEmail($user, Input::get('sender_email'));
         Setting::setReplyToEmail($user, Input::get('reply_to_email'));
         return Response::json(['success' => 'Settings successfully saved.']);
     }
 }
开发者ID:shinichi81,项目名称:Nifty-Newsletter,代码行数:17,代码来源:SettingController.php


注:本文中的Setting::getSiteSettings方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。