Schema

MySQL implementation of \Drupal\Core\Database\Schema. Hierarchy class \Drupal\Core\Database\Schema implements PlaceholderInterfaceclass \Drupal\Core\Database\Driver\mysql\Schema Related topics Schema API API to handle database schemas. File core/lib/Drupal/Core/Database/Driver/mysql/Schema.php, line 20 Namespace Drupal\Core\Database\Driver\mysql Members Name Modifiers Type Description Schema::$connection protected property The database connection. Schema::$defaultSc

Schema

Provides a base implementation for Database Schema. Hierarchy class \Drupal\Core\Database\Schema implements PlaceholderInterface File core/lib/Drupal/Core/Database/Schema.php, line 11 Namespace Drupal\Core\Database Members Name Modifiers Type Description Schema::$connection protected property The database connection. Schema::$defaultSchema protected property Definition of prefixInfo array structure. Schema::$placeholder protected property The placeholder

SAVED_UPDATED

Return status for saving which involved an update to an existing item. File core/includes/common.inc, line 64 Common functions that many Drupal modules will need to reference. Code const SAVED_UPDATED = 2;

SAVED_NEW

Return status for saving which involved creating a new item. File core/includes/common.inc, line 59 Common functions that many Drupal modules will need to reference. Code const SAVED_NEW = 1;

SAVED_DELETED

Return status for saving which deleted an existing item. File core/includes/common.inc, line 69 Common functions that many Drupal modules will need to reference. Code const SAVED_DELETED = 3;

Sanitization functions

Functions to sanitize values. See https://www.drupal.org/writing-secure-code for information on writing secure code. File core/includes/common.inc, line 188 Common functions that many Drupal modules will need to reference. Functions Name Location Description check_markup core/modules/filter/filter.module Runs all the enabled filters on a piece of text. check_url Deprecated core/includes/common.inc Strips dangerous protocols from a URI and encodes it for output to HTML. Form

SafeMarkup::isSafe

public static SafeMarkup::isSafe($string, $strategy = 'html') Checks if a string is safe to output. Parameters string|\Drupal\Component\Render\MarkupInterface $string: The content to be checked. string $strategy: (optional) This value is ignored. Return value bool TRUE if the string has been marked secure, FALSE otherwise. Deprecated in Drupal 8.0.x-dev, will be removed before Drupal 9.0.0. Instead, you should just check if a variable is an instance of \Drupal\Component\Render\MarkupInterfa

SafeMarkup::format

public static SafeMarkup::format($string, array $args) Formats a string for HTML display by replacing variable placeholders. Parameters string $string: A string containing placeholders. The string itself will not be escaped, any unsafe content must be in $args and inserted via placeholders. array $args: An array with placeholder replacements, keyed by placeholder. See \Drupal\Component\Render\FormattableMarkup::placeholderFormat() for additional information about placeholders. Return value st

SafeMarkup::checkPlain

public static SafeMarkup::checkPlain($text) Encodes special characters in a plain-text string for display as HTML. Also validates strings as UTF-8. All processed strings are also automatically flagged as safe markup strings for rendering. Parameters string $text: The text to be checked or processed. Return value \Drupal\Component\Render\HtmlEscapedText An HtmlEscapedText object that escapes when rendered to string. Deprecated Will be removed before Drupal 9.0.0. Rely on Twig's auto-escaping

SafeMarkup

Contains deprecated functionality related to sanitization of markup. Hierarchy class \Drupal\Component\Utility\SafeMarkup Deprecated Will be removed before Drupal 9.0.0. Use the appropriate sanitization functions or the theme and render systems so that the output can can be themed, escaped, and altered properly. See also TwigExtension::escapeFilter() twig_render_template() Sanitization functions Render API overview File core/lib/Drupal/Component/Utility/SafeMarkup.php, line 21 Namespa