Custom SVG icon
-
Hi, I read how to add my own custom button. It also states to put the custom svg under assets/svg inside the theme folder.
But I want to create a child plugin and want to read the SVG from the plugin folder.
Here is your code. but how do I link to custom SVG?function prefix_scriptless_add_tumblr_button( $buttons ) { $buttons['tumblr'] = array( 'label' => __( 'Tumblr', 'scriptless-social-sharing' ), 'url_base' => 'https://www.tumblr.com/share/link', 'args' => array( 'query_args' => array( 'name' => '%%title%%', 'url' => '%%permalink%%', ), 'color' => '#35465c', 'svg' => 'tumblr-square', // Use this with the SVG icons and add the SVG file to your theme's <code>assets/svg</code> folder 'icon' => 'f173', // Use this when using the FontAwesome font for icons ), ); return $buttons; }
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Custom SVG icon’ is closed to new replies.