WP_Font_Face::generate_style_element_attributesprivateWP 6.4.0

Gets the defined <style> element's attributes.

Method of the class: WP_Font_Face{}

No Hooks.

Returns

String. A string of attribute=value when defined, else, empty string.

Usage

// private - for code of main (parent) class only
$result = $this->generate_style_element_attributes();

Changelog

Since 6.4.0 Introduced.

WP_Font_Face::generate_style_element_attributes() code WP 6.8.1

private function generate_style_element_attributes() {
	$attributes = '';
	foreach ( $this->style_tag_attrs as $name => $value ) {
		$attributes .= " {$name}='{$value}'";
	}
	return $attributes;
}