MediaWiki  REL1_22
WebInstallerOutput Class Reference

Output class modelled on OutputPage. More...

Collaboration diagram for WebInstallerOutput:

List of all members.

Public Member Functions

 __construct (WebInstaller $parent)
 Constructor.
 addHTML ($html)
 addHTMLNoFlush ($html)
 addWikiText ($text)
 allowFrames ($allow=true)
 flush ()
 getCSS ($dir)
 Get the raw vector CSS, flipping if needed.
 getDir ()
 getHeadAttribs ()
 getJQuery ()
 getLanguageCode ()
 headerDone ()
 Get whether the header has been output.
 output ()
 outputFooter ()
 outputHeader ()
 outputShortHeader ()
 outputTitle ()
 redirect ($url)
 useShortHeader ($use=true)

Public Attributes

bool $allowFrames = false
 Does the current page need to allow being used as a frame? If not, X-Frame-Options will be output to forbid it.
WebInstaller $parent
 The WebInstaller object this WebInstallerOutput is used by.
 $redirectTarget

Private Member Functions

 getCssUrl ()
 "<link>" to index.php?css=foobar for the "<head>"

Private Attributes

String $contents = ''
 Buffered contents that haven't been output yet.
bool $headerDone = false
 Has the header (or short header) been output?
bool $useShortHeader = false
 Whether to use the limited header (used during CC license callbacks)

Detailed Description

Output class modelled on OutputPage.

I've opted to use a distinct class rather than derive from OutputPage here in the interests of separation of concerns: if we used a subclass, there would be quite a lot of things you could do in OutputPage that would break the installer, that wouldn't be immediately obvious.

Since:
1.17

Definition at line 35 of file WebInstallerOutput.php.


Constructor & Destructor Documentation

Constructor.

Parameters:
$parentWebInstaller

Definition at line 71 of file WebInstallerOutput.php.


Member Function Documentation

Definition at line 75 of file WebInstallerOutput.php.

Referenced by addHTMLNoFlush().

Definition at line 84 of file WebInstallerOutput.php.

References addHTML().

Definition at line 80 of file WebInstallerOutput.php.

References $html, contents, and flush().

Definition at line 199 of file WebInstallerOutput.php.

References useShortHeader().

Referenced by flush().

Definition at line 203 of file WebInstallerOutput.php.

References allowFrames().

Referenced by addWikiText().

Get the raw vector CSS, flipping if needed.

Todo:
Possibly get rid of this function and use ResourceLoader in the manner it was designed to be used in, rather than just grabbing a list of filenames from it, and not properly handling such details as media types in module definitions.
Parameters:
string$dir'ltr' or 'rtl'
Returns:
String

Definition at line 110 of file WebInstallerOutput.php.

"<link>" to index.php?css=foobar for the "<head>"

Returns:
String

Definition at line 191 of file WebInstallerOutput.php.

References getDir(), and Html\linkedStyle().

Returns:
string

Definition at line 217 of file WebInstallerOutput.php.

Referenced by getCssUrl().

Returns:
array

Definition at line 235 of file WebInstallerOutput.php.

Definition at line 341 of file WebInstallerOutput.php.

References global, and wfMessage().

Returns:
string

Definition at line 226 of file WebInstallerOutput.php.

Get whether the header has been output.

Returns:
bool

Definition at line 246 of file WebInstallerOutput.php.

Definition at line 95 of file WebInstallerOutput.php.

Definition at line 88 of file WebInstallerOutput.php.

References $html, and contents.

Definition at line 195 of file WebInstallerOutput.php.

Referenced by allowFrames().


Member Data Documentation

bool WebInstallerOutput::$allowFrames = false

Does the current page need to allow being used as a frame? If not, X-Frame-Options will be output to forbid it.

Definition at line 59 of file WebInstallerOutput.php.

String WebInstallerOutput::$contents = '' [private]

Buffered contents that haven't been output yet.

Definition at line 45 of file WebInstallerOutput.php.

bool WebInstallerOutput::$headerDone = false [private]

Has the header (or short header) been output?

Definition at line 50 of file WebInstallerOutput.php.

WebInstaller WebInstallerOutput::$parent

The WebInstaller object this WebInstallerOutput is used by.

Definition at line 40 of file WebInstallerOutput.php.

WebInstallerOutput::$redirectTarget

Definition at line 52 of file WebInstallerOutput.php.

bool WebInstallerOutput::$useShortHeader = false [private]

Whether to use the limited header (used during CC license callbacks)

Definition at line 64 of file WebInstallerOutput.php.


The documentation for this class was generated from the following file: