21use MediaWiki\HookContainer\ProtectedHookAccessorTrait;
31 use ProtectedHookAccessorTrait;
47 wfDebug( __METHOD__ .
' was called with no Config instance passed to it' );
48 $config = MediaWikiServices::getInstance()->getMainConfig();
58 public function set( $name, $value ) {
59 $this->data[$name] = $value;
68 public function extend( $name, $value ) {
70 $this->data[$name] .= $value;
72 $this->data[$name] = $value;
84 public function get( $name, $default = null ) {
85 return $this->data[$name] ?? $default;
98 protected function text( $str ) {
99 echo htmlspecialchars( $this->data[$str] );
107 echo $this->data[$str];
113 public function msg( $msgKey ) {
122 return isset( $this->data[$str] );
131 return $msg->exists() && !$msg->isDisabled();
140 return $this->data[
'skin'];
152 $html = ob_get_contents();
wfDebug( $text, $dest='all', array $context=[])
Sends a line to the debug log if enabled or, optionally, to a comment in output.
wfMessage( $key,... $params)
This is the function for getting translated interface messages.
Generic wrapper for template functions, with interface compatible with what we use of PHPTAL 0....
getSkin()
Get the Skin object related to this object.
__construct(Config $config=null)
getHTML()
Fetch the output of a QuickTemplate and return it.
extend( $name, $value)
extends the value of data with name $name with the value $value
execute()
Main function, used by classes that subclass QuickTemplate to show the actual HTML output.
Interface for configuration instances.