function ImageTestBase::imageAttributesAsString
Helper to format attributes.
Parameters
bool $reverse: Reverse attributes when printing them.
Return value
string A space-separated string of image attributes.
File
-
core/
modules/ ckeditor5/ tests/ src/ FunctionalJavascript/ ImageTestBase.php, line 73
Class
Namespace
Drupal\Tests\ckeditor5\FunctionalJavascriptCode
protected function imageAttributesAsString($reverse = FALSE) {
$string = [];
foreach ($this->imageAttributes() as $key => $value) {
$string[] = $key . '="' . $value . '"';
}
if ($reverse) {
$string = array_reverse($string);
}
return implode(' ', $string);
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.