[ Index ]

PHP Cross Reference of phpBB-3.3.2-deutsch

title

Body

[close]

/phpbb/controller/ -> helper.php (summary)

This file is part of the phpBB Forum Software package.

Copyright: (c) phpBB Limited
License: GNU General Public License, version 2 (GPL-2.0)
File Size: 375 lines (11 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

helper:: (10 methods):
  __construct()
  render()
  route()
  error()
  message()
  assign_meta_refresh_var()
  get_current_url()
  display_footer()
  display_sql_report()
  set_cron_task()


Class: helper  - X-Ref

Controller helper class, contains methods that do things for controllers

__construct(auth $auth, cache_interface $cache, config $config, manager $cron_manager,driver_interface $db, dispatcher $dispatcher, language $language,request_interface $request, routing_helper $routing_helper,symfony_request $symfony_request, template $template, user $user, $root_path,$admin_path, $php_ext, $sql_explain = false)   X-Ref
Constructor

param: auth $auth Auth object
param: cache_interface $cache
param: config $config Config object
param: manager $cron_manager
param: driver_interface $db DBAL object
param: dispatcher $dispatcher
param: language $language
param: request_interface $request phpBB request object
param: routing_helper $routing_helper Helper to generate the routes
param: symfony_request $symfony_request Symfony Request object
param: template $template Template object
param: user $user User object
param: string $root_path phpBB root path
param: string $admin_path Admin path
param: string $php_ext PHP extension
param: bool $sql_explain Flag whether to display sql explain

render($template_file, $page_title = '', $status_code = 200, $display_online_list = false, $item_id = 0, $item = 'forum', $send_headers = false)   X-Ref
Automate setting up the page and creating the response object.

param: string $template_file The template handle to render
param: string $page_title The title of the page to output
param: int $status_code The status code to be sent to the page header
param: bool $display_online_list Do we display online users list
param: int $item_id Restrict online users to item id
param: string $item Restrict online users to a certain session item, e.g. forum for session_forum_id
param: bool $send_headers Whether headers should be sent by page_header(). Defaults to false for controllers.
return: Response object containing rendered page

route($route, array $params = array()   X-Ref
Generate a URL to a route

param: string    $route        Name of the route to travel
param: array    $params        String or array of additional url parameters
param: bool    $is_amp        Is url using & (true) or & (false)
param: string|bool        $session_id    Possibility to use a custom session id instead of the global one
param: int    $reference_type    The type of reference to be generated (one of the constants)
return: string The URL already passed through append_sid()

error($message, $code = 500)   X-Ref
Output an error, effectively the same thing as trigger_error

param: string $message The error message
param: int $code The error code (e.g. 404, 500, 503, etc.)
return: Response A Response instance

message($message, array $parameters = array()   X-Ref
Output a message

In case of an error, please throw an exception instead

param: string $message The message to display (must be a language variable)
param: array $parameters The parameters to use with the language var
param: string $title Title for the message (must be a language variable)
param: int $code The HTTP status code (e.g. 404, 500, 503, etc.)
return: Response A Response instance

assign_meta_refresh_var($time, $url)   X-Ref
Assigns automatic refresh time meta tag in template

param: int        $time    time in seconds, when redirection should occur
param: string    $url    the URL where the user should be redirected
return: void

get_current_url()   X-Ref
Return the current url

return: string

display_footer($run_cron = true)   X-Ref
Handle display actions for footer, e.g. SQL report and credit line

param: bool $run_cron Flag whether cron should be run
return: void

display_sql_report()   X-Ref
Display SQL report

return: void

set_cron_task()   X-Ref
Set cron task for footer

return: void



Generated: Wed Nov 11 20:28:18 2020 Cross-referenced by PHPXref 0.7.1