function FormAjaxSubscriber::formatSize
Same name in other branches
- 9 core/lib/Drupal/Core/Form/EventSubscriber/FormAjaxSubscriber.php \Drupal\Core\Form\EventSubscriber\FormAjaxSubscriber::formatSize()
- 8.9.x core/lib/Drupal/Core/Form/EventSubscriber/FormAjaxSubscriber.php \Drupal\Core\Form\EventSubscriber\FormAjaxSubscriber::formatSize()
Wraps format_size()
Return value
string The formatted size.
Deprecated
in drupal:10.2.0 and is removed from drupal:11.0.0. Use \Drupal\Core\StringTranslation\ByteSizeMarkup::create() instead.
See also
https://www.drupal.org/node/2999981
File
-
core/
lib/ Drupal/ Core/ Form/ EventSubscriber/ FormAjaxSubscriber.php, line 160
Class
- FormAjaxSubscriber
- Wraps AJAX form submissions that are triggered via an exception.
Namespace
Drupal\Core\Form\EventSubscriberCode
protected function formatSize($size) {
@trigger_error(__METHOD__ . '() is deprecated in drupal:10.2.0 and is removed from drupal:11.0.0. Use \\Drupal\\Core\\StringTranslation\\ByteSizeMarkup::create() instead. See https://www.drupal.org/node/2999981', E_USER_DEPRECATED);
return format_size($size);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.