Пример #1
0
 static function start($package, $mode = 'dev')
 {
     register_shutdown_function(array(get_class(), 'finalize'));
     ob_start();
     so_error::monitor();
     foreach (parse_ini_file(so_file::make('php.ini')) as $key => $value) {
         ini_set($key, $value);
     }
     so_page::$mode = $mode;
     so_package::$defaultName = $package;
     so_query::$resourcePrefix = $package;
     $front = so_front::make();
     $query = $front->uri->query;
     $resource = $query->resource;
     $uriStandard = $resource->uri;
     if ($query->uri != $uriStandard) {
         return static::$response = so_output::moved((string) $uriStandard);
     }
     static::$response = $resource->execute($front->method, $front->data);
 }
Пример #2
0
 function get_resource($data = null)
 {
     $url = (string) $this->image['@hyoo_image_search_unescapedUrl'];
     return so_output::moved($url)->cache(true);
 }