Plugin Directory

Changeset 1130752


Ignore:
Timestamp:
04/09/2015 12:16:09 AM (11 years ago)
Author:
mahodder
Message:

1.0.6

  • Add backwards compatibility for old Font Awesome icons
Location:
themedy-toolbox/trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • themedy-toolbox/trunk/includes/shortcodes.php

    r1130688 r1130752  
    11<?php
     2
     3function check_old_fa($icon) {
     4    if ($icon == "ban-circle"){$icon = "ban";}
     5    if ($icon == "bar-chart"){$icon = "bar-chart-o";}
     6    if ($icon == "beaker"){$icon = "flask";}
     7    if ($icon == "bell"){$icon = "bell-o";}
     8    if ($icon == "bell-alt"){$icon = "bell";}
     9    if ($icon == "bitbucket-sign"){$icon = "bitbucket-square";}
     10    if ($icon == "bookmark-empty"){$icon = "bookmark-o";}
     11    if ($icon == "building"){$icon = "building-o";}
     12    if ($icon == "calendar-empty"){$icon = "calendar-o";}
     13    if ($icon == "check-empty"){$icon = "square-o";}
     14    if ($icon == "check-minus"){$icon = "minus-square-o";}
     15    if ($icon == "check-sign"){$icon = "check-square";}
     16    if ($icon == "check"){$icon = "check-square-o";}
     17    if ($icon == "chevron-sign-down"){$icon = "chevron-down";}
     18    if ($icon == "chevron-sign-left"){$icon = "chevron-left";}
     19    if ($icon == "chevron-sign-right"){$icon = "chevron-right";}
     20    if ($icon == "chevron-sign-up"){$icon = "chevron-up";}
     21    if ($icon == "circle-arrow-down"){$icon = "arrow-circle-down";}
     22    if ($icon == "circle-arrow-left"){$icon = "arrow-circle-left";}
     23    if ($icon == "circle-arrow-right"){$icon = "arrow-circle-right";}
     24    if ($icon == "circle-arrow-up"){$icon = "arrow-circle-up";}
     25    if ($icon == "circle-blank"){$icon = "circle-o";}
     26    if ($icon == "cny"){$icon = "rmb";}
     27    if ($icon == "collapse-alt"){$icon = "minus-square-o";}
     28    if ($icon == "collapse-top"){$icon = "caret-square-o-up";}
     29    if ($icon == "collapse"){$icon = "caret-square-o-down";}
     30    if ($icon == "comment-alt"){$icon = "comment-o";}
     31    if ($icon == "comments-alt"){$icon = "comments-o";}
     32    if ($icon == "copy"){$icon = "files-o";}
     33    if ($icon == "cut"){$icon = "scissors";}
     34    if ($icon == "dashboard"){$icon = "tachometer";}
     35    if ($icon == "double-angle-down"){$icon = "angle-double-down";}
     36    if ($icon == "double-angle-left"){$icon = "angle-double-left";}
     37    if ($icon == "double-angle-right"){$icon = "angle-double-right";}
     38    if ($icon == "double-angle-up"){$icon = "angle-double-up";}
     39    if ($icon == "download"){$icon = "arrow-circle-o-down";}
     40    if ($icon == "download-alt"){$icon = "download";}
     41    if ($icon == "edit-sign"){$icon = "pencil-square";}
     42    if ($icon == "edit"){$icon = "pencil-square-o";}
     43    if ($icon == "ellipsis-horizontal"){$icon = "ellipsis-h";}
     44    if ($icon == "ellipsis-vertical"){$icon = "ellipsis-v";}
     45    if ($icon == "envelope-alt"){$icon = "envelope-o";}
     46    if ($icon == "exclamation-sign"){$icon = "exclamation-circle";}
     47    if ($icon == "expand-alt"){$icon = "plus-square-o";}
     48    if ($icon == "expand"){$icon = "caret-square-o-right";}
     49    if ($icon == "external-link-sign"){$icon = "external-link-square";}
     50    if ($icon == "eye-close"){$icon = "eye-slash";}
     51    if ($icon == "eye-open"){$icon = "eye";}
     52    if ($icon == "facebook-sign"){$icon = "facebook-square";}
     53    if ($icon == "facetime-video"){$icon = "video-camera";}
     54    if ($icon == "file-alt"){$icon = "file-o";}
     55    if ($icon == "file-text-alt"){$icon = "file-text-o";}
     56    if ($icon == "flag-alt"){$icon = "flag-o";}
     57    if ($icon == "folder-close-alt"){$icon = "folder-o";}
     58    if ($icon == "folder-close"){$icon = "folder";}
     59    if ($icon == "folder-open-alt"){$icon = "folder-open-o";}
     60    if ($icon == "food"){$icon = "cutlery";}
     61    if ($icon == "frown"){$icon = "frown-o";}
     62    if ($icon == "fullscreen"){$icon = "arrows-alt";}
     63    if ($icon == "github-sign"){$icon = "github-square";}
     64    if ($icon == "google-plus-sign"){$icon = "google-plus-square";}
     65    if ($icon == "group"){$icon = "users";}
     66    if ($icon == "h-sign"){$icon = "h-square";}
     67    if ($icon == "hand-down"){$icon = "hand-o-down";}
     68    if ($icon == "hand-left"){$icon = "hand-o-left";}
     69    if ($icon == "hand-right"){$icon = "hand-o-right";}
     70    if ($icon == "hand-up"){$icon = "hand-o-up";}
     71    if ($icon == "hdd"){$icon = "hdd-o (4.0.1)";}
     72    if ($icon == "heart-empty"){$icon = "heart-o";}
     73    if ($icon == "hospital"){$icon = "hospital-o";}
     74    if ($icon == "indent-left"){$icon = "outdent";}
     75    if ($icon == "indent-right"){$icon = "indent";}
     76    if ($icon == "info-sign"){$icon = "info-circle";}
     77    if ($icon == "keyboard"){$icon = "keyboard-o";}
     78    if ($icon == "legal"){$icon = "gavel";}
     79    if ($icon == "lemon"){$icon = "lemon-o";}
     80    if ($icon == "lightbulb"){$icon = "lightbulb-o";}
     81    if ($icon == "linkedin-sign"){$icon = "linkedin-square";}
     82    if ($icon == "meh"){$icon = "meh-o";}
     83    if ($icon == "microphone-off"){$icon = "microphone-slash";}
     84    if ($icon == "minus-sign-alt"){$icon = "minus-square";}
     85    if ($icon == "minus-sign"){$icon = "minus-circle";}
     86    if ($icon == "mobile-phone"){$icon = "mobile";}
     87    if ($icon == "moon"){$icon = "moon-o";}
     88    if ($icon == "move"){$icon = "arrows";}
     89    if ($icon == "off"){$icon = "power-off";}
     90    if ($icon == "ok-circle"){$icon = "check-circle-o";}
     91    if ($icon == "ok-sign"){$icon = "check-circle";}
     92    if ($icon == "ok"){$icon = "check";}
     93    if ($icon == "paper-clip"){$icon = "paperclip";}
     94    if ($icon == "paste"){$icon = "clipboard";}
     95    if ($icon == "phone-sign"){$icon = "phone-square";}
     96    if ($icon == "picture"){$icon = "picture-o";}
     97    if ($icon == "pinterest-sign"){$icon = "pinterest-square";}
     98    if ($icon == "play-circle"){$icon = "play-circle-o";}
     99    if ($icon == "play-sign"){$icon = "play-circle";}
     100    if ($icon == "plus-sign-alt"){$icon = "plus-square";}
     101    if ($icon == "plus-sign"){$icon = "plus-circle";}
     102    if ($icon == "pushpin"){$icon = "thumb-tack";}
     103    if ($icon == "question-sign"){$icon = "question-circle";}
     104    if ($icon == "remove-circle"){$icon = "times-circle-o";}
     105    if ($icon == "remove-sign"){$icon = "times-circle";}
     106    if ($icon == "remove"){$icon = "times";}
     107    if ($icon == "reorder"){$icon = "bars";}
     108    if ($icon == "resize-full"){$icon = "expand";}
     109    if ($icon == "resize-horizontal"){$icon = "arrows-h";}
     110    if ($icon == "resize-small"){$icon = "compress";}
     111    if ($icon == "resize-vertical"){$icon = "arrows-v";}
     112    if ($icon == "rss-sign"){$icon = "rss-square";}
     113    if ($icon == "save"){$icon = "floppy-o";}
     114    if ($icon == "screenshot"){$icon = "crosshairs";}
     115    if ($icon == "share-alt"){$icon = "share";}
     116    if ($icon == "share-sign"){$icon = "share-square";}
     117    if ($icon == "share"){$icon = "share-square-o";}
     118    if ($icon == "sign-blank"){$icon = "square";}
     119    if ($icon == "signin"){$icon = "sign-in";}
     120    if ($icon == "signout"){$icon = "sign-out";}
     121    if ($icon == "smile"){$icon = "smile-o";}
     122    if ($icon == "sort-by-alphabet-alt"){$icon = "sort-alpha-desc";}
     123    if ($icon == "sort-by-alphabet"){$icon = "sort-alpha-asc";}
     124    if ($icon == "sort-by-attributes-alt"){$icon = "sort-amount-desc";}
     125    if ($icon == "sort-by-attributes"){$icon = "sort-amount-asc";}
     126    if ($icon == "sort-by-order-alt"){$icon = "sort-numeric-desc";}
     127    if ($icon == "sort-by-order"){$icon = "sort-numeric-asc";}
     128    if ($icon == "sort-down"){$icon = "sort-desc";}
     129    if ($icon == "sort-up"){$icon = "sort-asc";}
     130    if ($icon == "stackexchange"){$icon = "stack-overflow";}
     131    if ($icon == "star-empty"){$icon = "star-o";}
     132    if ($icon == "star-half-empty"){$icon = "star-half-o";}
     133    if ($icon == "sun"){$icon = "sun-o";}
     134    if ($icon == "thumbs-down-alt"){$icon = "thumbs-o-down";}
     135    if ($icon == "thumbs-up-alt"){$icon = "thumbs-o-up";}
     136    if ($icon == "time"){$icon = "clock-o";}
     137    if ($icon == "trash"){$icon = "trash-o";}
     138    if ($icon == "tumblr-sign"){$icon = "tumblr-square";}
     139    if ($icon == "twitter-sign"){$icon = "twitter-square";}
     140    if ($icon == "unlink"){$icon = "chain-broken";}
     141    if ($icon == "upload"){$icon = "arrow-circle-o-up";}
     142    if ($icon == "upload-alt"){$icon = "upload";}
     143    if ($icon == "warning-sign"){$icon = "exclamation-triangle";}
     144    if ($icon == "xing-sign"){$icon = "xing-square";}
     145    if ($icon == "youtube-sign"){$icon = "youtube-square";}
     146    if ($icon == "zoom-in"){$icon = "search-plus";}
     147    if ($icon == "zoom-out"){$icon = "search-minus";}
     148   
     149    return $icon;
     150}
    2151
    3152/* Button */
     
    18167    ), $atts));
    19168
    20     echo $label;
     169    $icon = check_old_fa($icon);
    21170   
    22171    /* Return Button */
     
    162311
    163312
    164 
    165313/* Toggles */
    166314
     
    175323        'onload' => 'closed'
    176324    ), $atts));
     325
     326    $icon = check_old_fa($icon);
     327
    177328    if($onload == "open") { $active_class = "themedy-shortcode-toggle-active"; } else { $active_class = ""; }
    178329    if($icon) { $icon_code = '<i class="fa '.$font_awesome_att.' fa-'.$icon.'"></i>'; } else { $icon_code = ''; }
     
    227378
    228379/* Map */
     380
    229381global $google_map_script_code;
    230382function themedy_shortcodes_map($atts, $content = null) {
     
    301453
    302454/* Add Google Map Code to Footer */
     455
    303456function themedy_add_google_map_code() {
    304457    global $google_map_script_code;
     
    312465add_action('wp_footer', 'themedy_add_google_map_code');
    313466
     467
     468
    314469/* Alert Box */
    315470
     
    324479    ), $atts));
    325480   
    326    
     481    $icon = check_old_fa($icon);
     482
    327483    $alertbox_style = "";
    328484    if($custom_colour) {
     
    337493
    338494
     495
    339496/* Pull Quote Left */
    340497
     
    360517
    361518
     519
    362520/* Pull Quote Right */
    363521
  • themedy-toolbox/trunk/readme.txt

    r1130688 r1130752  
    44Requires at least: 3.9
    55Tested up to: 4.1.1
    6 Stable tag: 1.0.5
     6Stable tag: 1.0.6
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    3232
    3333== Changelog ==
     34
     35= 1.0.6 =
     36* Add backwards compatibility for old Font Awesome icons
    3437
    3538= 1.0.5 =
  • themedy-toolbox/trunk/themedy-toolbox.php

    r1130688 r1130752  
    44Plugin URI: http://themedy.com
    55Description: Shortcodes and tools to extend your Themedy site even further.
    6 Version: 1.0.5
     6Version: 1.0.6
    77Author: Themedy
    88Author URI: http://themedy.com
Note: See TracChangeset for help on using the changeset viewer.