Linux 软件免费装
Banner图

JM Dashicons Shortcode

开发者 jmlapam
更新时间 2014年6月10日 22:11
PHP版本: 3.9.1 及以上
WordPress版本: 3.9.1
版权: GPLv2 or later
版权网址: 版权信息

标签

icon font icons ui dashicons font icon

下载

详情介绍:

WordPress 3.8 known as Oscar offers an amazing font, Dashicons, this plugins allows you to use it for your posts. Once activated the plugin adds a shortcode in edit post. You can now enjoy Dashicons font added to the core in WordPress 3.8 to do what you want e.g page sections with icons. The plugin adds a popup buton on visual editor so you can set it in WYSIWYG. Hit the help tab to get full list on widget and menu pages. Shortcode is available on posts, widgets and nav menus (see example on my blog) Follow me on Twitter

安装:

  1. Upload plugin files to the /wp-content/plugins/ directory
  2. Activate the plugin through the Plugins menu in WordPress
  3. Then go to your post edit and just use the shortcode e.g [dashicon name="smartphone" size="3" color="#f83123" class="myclass"]
  4. The plugin adds a FULL LIST of available icons with their name on tinymce button
  5. You can easily know how to write the shortcode with quicktag buttons ( go the HTML tab in your edit post)

屏幕截图:

  • help button
  • lists of icons
  • quicktags
  • menu with icons

常见问题:

Where can I find the name for icons?

On post edits use the admin UI (tinymce to set your icon) On widget and menu pages you have a help button (on the top right of the screen), when clicking on this button it slides a pannel with multiple tabs. You'll find all the icons available.

If you care about accessibility

Just use the text parameter like this : [dashicon name="twitter" text="share on Twitter"] It won't change anything for you but it can improve experience for people using assistive technologies such as VoiceOver

The text for accessibility is showing

That's too bad. Maybe your theme missed it. To avoid this just put the following code in your CSS : .screen-reader-text { position: absolute; left: -7000px; overflow: hidden; }

The font does not appear on IE8

You might add some stylesheet for IE8 and put in here : .ds-fallback-text .dashicons:before { content: ''; } Then you might add a little bit of JavaScript.

Some icons do not show up

Please check you WP version, Dashicons have been updated with WP 3.9

I want to write a shortcode in a widget text but not to execute it

The plugin activates shortcodes in widget text. In this very very particular case, you can use this great trick : put the shortcode in double [] like that : [[myshortcode]] Source

更新日志:

1.7.2 1.7.1 1.6 1.5 1.4.3 1.4.2 1.4.1 1.4 1.3 1.2 1.1 1.0