public class TextformatterManager

class.textformattermanager.php #14

The TextformatterManager class is responsible for managing all Text Formatter objects in Symphony. Text Formatter's are stored on the file system either in the TEXTFORMATTERS folder or provided by an extension in the /text-formatters/ folder. All formatters provide one simple method, run, which applies the formatting to an unformatted string and returns it.

Methods

static string __getClassName(string $handle)

Given a name, returns the full class name of a Text Formatter. Text Formatters use a 'formatter' prefix.

Parameters
  • $handle stringThe formatter handle

static string|boolean __getClassPath(string $handle)

Finds a Text Formatter by name by searching the TEXTFORMATTERS folder and in all installed extension folders and returns the path to it's folder.

Parameters
  • $handle stringThe handle of the Text Formatter free from any Symphony conventions such as formatter.*.php

Returns

If the Text Formatter is found, the function returns the path it's folder, otherwise false.

static string __getDriverPath(string $handle)

Given a name, return the path to the driver of the Text Formatter.

Parameters
  • $handle stringThe handle of the Text Formatter free from any Symphony conventions such as formatter.*.php

See Also
static string __getHandleFromFilename(string $filename)

Given the filename of a Text Formatter return it's handle. This will remove the Symphony convention of formatter.*.php

Parameters
  • $filename stringThe filename of the Text Formatter

static void about(mixed $name)
static TextFormatter create(string $handle)

Creates an instance of a given class and returns it. Adds the instance to the $_pool array with the key being the handle.

Parameters
  • $handle stringThe handle of the Text Formatter to create

static array listAll()

Finds all available Text Formatter's by searching the TEXTFORMATTERS folder and in all installed extension folders. Returns an associative array of formatters.

Returns

Associative array of formatters with the key being the handle of the formatter and the value being the text formatter's description.

See Also

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details