You are here

function format_string in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/includes/bootstrap.inc \format_string()

Formats a string for HTML display by replacing variable placeholders.

Deprecated

in Drupal 8.0.0, will be removed before Drupal 9.0.0. Use \Drupal\Component\Utility\SafeMarkup::format().

See also

\Drupal\Component\Utility\SafeMarkup::format()

t()

Related topics

288 calls to format_string()
AddFeedTest::testBasicFeedAddNoTitle in core/modules/system/src/Tests/Common/AddFeedTest.php
Tests attaching feeds with paths, URLs, and titles.
AggregatorAdminTest::testSettingsPage in core/modules/aggregator/src/Tests/AggregatorAdminTest.php
Tests the settings form to ensure the correct default values are used.
AggregatorRenderingTest::testBlockLinks in core/modules/aggregator/src/Tests/AggregatorRenderingTest.php
Adds a feed block to the page and checks its links.
AggregatorTestBase::createFeed in core/modules/aggregator/src/Tests/AggregatorTestBase.php
Creates an aggregator feed.
AggregatorTestBase::updateFeedItems in core/modules/aggregator/src/Tests/AggregatorTestBase.php
Updates the feed items.

... See full list

File

core/includes/bootstrap.inc, line 309
Functions that need to be loaded on every Drupal request.

Code

function format_string($string, array $args) {
  return SafeMarkup::format($string, $args);
}