Esempio n. 1
0
 protected static function classArray()
 {
     if (is_null(self::$classes) || !is_array(self::$classes)) {
         self::$classes = (require COMMON_PATH . '/autoload.conf.php');
         $appClassList = appConfig::getAutoloadClass();
         if (!empty($appClassList)) {
             self::$classes = array_merge(self::$classes, $appClassList);
         }
     }
 }
Esempio n. 2
0
 protected function displayManual(sfWebRequest $request, $file_name)
 {
     $path = appConfig::getManualsPath() . DIRECTORY_SEPARATOR . $file_name;
     $response = $this->getResponse();
     $response->setHttpHeader('Pragma', '');
     $response->setHttpHeader('Cache-Control', '');
     $data = file_get_contents($path);
     $response->setHttpHeader("Content-Type", "application/pdf");
     $response->setHttpHeader('Content-Disposition', "attachment; filename=\"{$file_name}\"");
     $response->setContent($data);
     return sfView::NONE;
 }
 private function getParam($key, $default = null)
 {
     return $this->appConfig->getValue($key);
 }