block_core_social_link_get_icon()
Returns the SVG for social link.
No Hooks.
Returns
String. SVG Element for service icon.
Usage
block_core_social_link_get_icon( $service );
- $service(string) (required)
- The service icon.
Changelog
| Since 5.4.0 | Introduced. |
block_core_social_link_get_icon() block core social link get icon code WP 6.9.1
function block_core_social_link_get_icon( $service ) {
$services = block_core_social_link_services();
if ( isset( $services[ $service ] ) && isset( $services[ $service ]['icon'] ) ) {
return $services[ $service ]['icon'];
}
return $services['share']['icon'];
}