コード例 #1
0
ファイル: Request.php プロジェクト: veloxpro/VeloxPHP
 public function getScheme()
 {
     $configFile = 'config/app.config.php';
     if (is_readable($configFile)) {
         $config = (include $configFile);
         if (isset($config['enforce_ssl']) && $config['enforce_ssl']) {
             return 'https';
         }
     }
     return $this->server->getString('REQUEST_SCHEME', 'http');
 }
コード例 #2
0
ファイル: BaseForm.php プロジェクト: veloxpro/VeloxPHP
 public function handle(ParameterBag $pb)
 {
     foreach ($this->fields as $f) {
         $fieldName = $f->getFieldName();
         $v = $pb->get($fieldName, null);
         if (!is_null($v)) {
             $this->set($fieldName, $v);
         }
     }
 }