Plugin Directory

Changeset 1397012


Ignore:
Timestamp:
04/16/2016 03:34:05 AM (10 years ago)
Author:
dbmartin
Message:
  • updated to 1.0
  • incorporated Adv Term Fields framework
  • added uninstall.php
Location:
advanced-term-fields-featured-images
Files:
43 added
2 deleted
4 edited

Legend:

Unmodified
Added
Removed
  • advanced-term-fields-featured-images/trunk/README.md

    r1350178 r1397012  
    1 # Advanced Term Fields: Featured Images
     1# Advanced Term Images
    22
    3 Easily assign featured images for categories, tags, and custom taxonomy terms. Term meta, with images!
     3Easily add featured images to your categories, tags, and custom taxonomy terms. Supports all taxonomies!
    44
    5 **Advanced Term Fields: Featured Images** extends the Advanced Term Fields framework to give users the ability to easily add and manage featured images for any category, tag, or custom taxonomy.
     5**Advanced Term Images** gives users the ability to easily add and manage featured images for categories, tags, and custom taxonomies.
     6
     7**Update:** As of version 1.0 this plugin no longer relies on the Advanced Term Fields framework. All functionality from that framework has been incorporated within this plugin.
    68
    79![term admin](assets/screenshot-1.png?raw=true "Featured Images!")
     
    2527## Usage
    2628
    27 This is an extension of the **Advanced Term Fields** framework.  To use, the Advanced Term Fields plugin must be installed on your project. You can find that plugin here:
     29Once you've installed and activated the plugin, you should see a new form field in your edit tags screen.  (See the Screenshots tab.)
    2830
    29 * On WP: [Advanced Term Fields](https://wordpress.org/plugins/advanced-term-fields/)
    30 * On GitHub: [Advanced Term Fields](https://github.com/dboutote/Advanced-Term-Fields)
    31 
    32 Once you've installed and activated the ATF and ATF: Images plugins, you should see a new form field in your edit tags screen:
     31Use the native WordPress media picker to select a featured image for your term.
    3332
    3433![Form field on Add Tag form](assets/screenshot-2.jpg?raw=true "New form field")
     
    3837#### Where can I find additional documentation?
    3938
    40 The plugin's official page: http://darrinb.com/advanced-term-fields-images
     39The plugin's official page: http://darrinb.com/plugins/advanced-term-images
    4140
    4241#### Does this plugin depend on any others?
    4342
    44 Yes, this plugin is an extension of the **Advanced Term Fields** framework.  You'll need to install that plugin to handle all base functionality. You can find that plugin here:
    45 
    46 * On WP: [Advanced Term Fields](https://wordpress.org/plugins/advanced-term-fields/)
    47 * On GitHub: [Advanced Term Fields](https://github.com/dboutote/Advanced-Term-Fields)
     43Nope!  It _used_ to depend on the Advanced Term Fields plugin, but as of version 1.0, all functionality has been incorporated into this plugin.
    4844
    4945#### Does this create/modify/destroy database tables?
     
    5349#### Are there other extensions?
    5450
    55 Yep!  This is a list of all current extensions:
     51Yep!  This is a list of all current term meta plugins:
    5652
    57 * [Advanced Term Fields: Colors](https://github.com/dboutote/Advanced-Term-Fields-Colors)
    58 * [Advanced Term Fields: Icons](https://github.com/dboutote/Advanced-Term-Fields-Icons)
    59 * [Advanced Term Fields: Featured Images](https://github.com/dboutote/Advanced-Term-Fields-Images)
     53* [Advanced Term Colors](https://wordpress.org/plugins/advanced-term-fields-colors/)
     54* [Advanced Term Icons](https://wordpress.org/plugins/advanced-term-fields-icons/)
     55* [Advanced Term Images](https://wordpress.org/plugins/advanced-term-fields-featured-images/)
     56* [Advanced Term Locks](https://wordpress.org/plugins/advanced-term-fields-locks/)
  • advanced-term-fields-featured-images/trunk/advanced-term-fields-images.php

    r1350178 r1397012  
    11<?php
    22/**
    3  * Advanced Term Fields: Featured Images
     3 * Advanced Term Images
    44 *
    5  * @package Advanced_Term_Fields_Images
     5 * @package Advanced_Term_Images
    66 *
    77 * @license     http://www.gnu.org/licenses/gpl-2.0.txt GPL-2.0+
    8  * @version     0.1.1
     8 * @version     1.0
    99 *
    10  * Plugin Name: Advanced Term Fields: Featured Images
     10 * Plugin Name: Advanced Term Images
    1111 * Plugin URI:  http://darrinb.com/plugins/advanced-term-fields-images
    1212 * Description: Easily assign featured images for categories, tags, and custom taxonomy terms.
    13  * Version:     0.1.1
     13 * Version:     1.0
    1414 * Author:      Darrin Boutote
    1515 * Author URI:  http://darrinb.com
     
    3535 * @since 0.1.1
    3636 */
    37 define( 'ATF_IMAGES_VERSION', '0.1.1' );
     37define( 'ATF_IMAGES_VERSION', '1.0' );
    3838
    3939
     
    4444
    4545/**
    46  * Load Utilities
     46 * Loads Utilities
    4747 *
    4848 * @since 0.1.1
    4949 */
    50 include dirname( __FILE__ ) . '/inc/functions.php';
     50include dirname( __FILE__ ) . '/inc/class-advanced-term-images-utils.php';
    5151
    5252
     
    5656 * @since 0.1.0
    5757 */
    58 add_action( 'plugins_loaded', '_atf_images_compatibility_check', 99 );
     58add_action( 'plugins_loaded', array( 'Advanced_Term_Images_Utils', 'compatibility_check' ), 99 );
    5959
    6060
    6161/**
    62  * Instantiates main Advanced Term Fields: Featured Images class
     62 * Instantiates main Advanced Term Images class
    6363 *
    6464 * @since 0.1.0
     
    6666function _atf_images_init() {
    6767
    68     if ( ! _atf_images_compatibility_check() ){ return; }
     68    if( ! defined( 'ATF_IMAGES_IS_COMPATIBLE' ) || ! ATF_IMAGES_IS_COMPATIBLE ) { return; }
    6969
    70     include dirname( __FILE__ ) . '/inc/class-adv-term-fields-images.php';
     70    /**
     71     * Load core framework
     72     *
     73     * Note: this replaces the Advanced Term Fields framework plugin
     74     * @see https://make.wordpress.org/plugins/2016/03/01/please-do-not-submit-frameworks/
     75     *
     76     * @since 1.0
     77     */
     78    include dirname( __FILE__ ) . '/lib/adv-term-fields/class-advanced-term-fields.php';
    7179
    72     $Adv_Term_Fields_Images = new Adv_Term_Fields_Images( __FILE__ );
    73     $Adv_Term_Fields_Images->init();
     80    include dirname( __FILE__ ) . '/inc/class-advanced-term-images.php';
     81
     82    $Advanced_Term_Images = new Advanced_Term_Images( __FILE__ );
     83    $Advanced_Term_Images->init();
    7484
    7585}
     
    7888
    7989/**
    80  * Run actions on plugin upgrade
     90 * Runs actions on plugin upgrade
    8191 *
    8292 * @since 0.1.1
    8393 */
    84 add_action( "atf__thumbnail_id_version_upgraded", '_atf_images_version_upgraded_notice', 10, 5 );
    85 add_action( "atf__thumbnail_id_version_upgraded", '_atf_images_maybe_update_meta_key', 10, 5 );
     94add_action( "atf__thumbnail_id_version_upgraded", array( 'Advanced_Term_Images_Utils', 'version_upgraded_notice' ), 10, 5 );
     95add_action( "atf__thumbnail_id_version_upgraded", array( 'Advanced_Term_Images_Utils', 'maybe_update_meta_key' ), 10, 5 );
  • advanced-term-fields-featured-images/trunk/js/admin.js

    r1350178 r1397012  
    33( function ($) {
    44    'use strict';
    5    
     5
    66    /**
    77     * Globals
     
    1313    var del_link;
    1414    var atf_tag_form = $('#addtag');
    15    
     15
    1616
    1717    /**
     
    7474        return link_html;
    7575    };
    76    
     76
    7777    /**
    7878     * Resets the Image form field
     
    8484        atfResetSetLink( form );
    8585        atfClearDeleteLink( form );
    86     }; 
     86    };
    8787
    8888
     
    212212        $(':input[name="' + l10n_ATF_Images.meta_key + '"]', '.inline-edit-row').val(img_id).trigger('atf_change');;
    213213    });
    214    
     214
    215215
    216216    /**
     
    223223        if( form.hasClass('atf-submitted') &&  $('#ajax-response').html() == '' ) {
    224224            atfResetTagFormFeatImage( form );
    225         }       
     225        }
    226226    });
    227    
    228    
     227
     228
    229229    /**
    230230     * Reset the featured image field after the form has been submitted
     
    235235    $( '#submit', atf_tag_form).click( function(){
    236236        var form = $(this).parents('form');
    237        
     237
    238238        if ( ! validateForm( form ) ) {
    239239            form.removeClass('atf-submitted');
     
    242242            form.addClass('atf-submitted');
    243243        }
    244     }); 
     244    });
    245245
    246246
  • advanced-term-fields-featured-images/trunk/readme.txt

    r1350178 r1397012  
    1 === Advanced Term Fields: Featured Images ===
     1=== Advanced Term Images ===
    22Contributors: dbmartin
    3 Tags: termmeta, term_meta, term, meta, metadata, taxonomy, colors
     3Tags: term-meta, term, meta, metadata, taxonomy, image, images, featured-images, category-images
    44Requires at least: 4.4
    5 Tested up to: 4.4.1
    6 Stable tag: 0.1.1
     5Tested up to: 4.5
     6Stable tag: 1.0
    77License: GPLv2 or later
    88License URI: http://www.gnu.org/licenses/gpl-2.0.html
    99
    10 Easily assign featured images for categories, tags, and custom taxonomy terms. Term meta, with images!
     10Easily add featured images to your categories, tags, and custom taxonomy terms. Supports all taxonomies!
    1111
    1212== Description ==
    1313
    14 **Advanced Term Fields: Featured Images** extends the Advanced Term Fields framework to give users the ability to easily add and manage featured images for any category, tag, or custom taxonomy.
     14**Advanced Term Images** gives users the ability to easily add and manage featured images for categories, tags, and custom taxonomies.
     15
     16**Update:** As of version 1.0 this plugin no longer relies on the Advanced Term Fields framework. All functionality from that framework has been incorporated within this plugin.
    1517
    1618= Usage =
    1719
    18 This is an extension of the **Advanced Term Fields** framework.  To use, the Advanced Term Fields plugin must be installed on your project. You can find that plugin here:
     20Once you've installed and activated the plugin, you should see a new form field in your edit tags screen.  (See the Screenshots tab.)
    1921
    20 * On WP: [Advanced Term Fields](https://wordpress.org/plugins/advanced-term-fields/)
    21 * On GitHub: [Advanced Term Fields](https://github.com/dboutote/Advanced-Term-Fields)
     22Use the native WordPress media picker to select a featured image for your term.
    2223
    23 Once you've installed and activated the ATF and ATF: Images plugins, you should see a new form field in your edit tags screen.  (See the Screenshots tab.)
     24= Also Check Out: =
    2425
    25 = Check Out Other Extensions =
    26 
    27 * [Advanced Term Fields: Colors](https://wordpress.org/plugins/advanced-term-fields-featured-images/)
    28 * [Advanced Term Fields: Icons](https://wordpress.org/plugins/advanced-term-fields-icons/)
    29 * [Advanced Term Fields: Featured Images](https://wordpress.org/plugins/advanced-term-fields-featured-images/)
     26* [Advanced Term Colors](https://wordpress.org/plugins/advanced-term-fields-colors/)
     27* [Advanced Term Icons](https://wordpress.org/plugins/advanced-term-fields-icons/)
     28* [Advanced Term Images](https://wordpress.org/plugins/advanced-term-fields-featured-images/)
     29* [Advanced Term Locks](https://wordpress.org/plugins/advanced-term-fields-locks/)
    3030
    3131== Installation ==
     
    3737* No further setup or configuration is necessary.
    3838
    39 = From GitHub: =
    40 
    41 * Download the [latest stable version](https://github.com/dboutote/Advanced-Term-Fields-Images/archive/master.zip).
    42 * Extract the zip folder to your plugins directory.
    43 * Activate in the "Plugins" area of your admin by clicking the "Activate" link.
    44 * No further setup or configuration is necessary.
    45 
    4639
    4740== Frequently Asked Questions ==
     
    4942= Where can I find additional documentation? =
    5043
    51 The plugin's official page: http://darrinb.com/advanced-term-fields-images
     44The plugin's official page: http://darrinb.com/plugins/advanced-term-images
    5245
    5346= Does this plugin depend on any others? =
    5447
    55 Yes, this plugin is an extension of the **Advanced Term Fields** framework.  You'll need to install that plugin to handle all base functionality. You can find that plugin here:
    56 
    57 * On WP: [Advanced Term Fields](https://wordpress.org/plugins/advanced-term-fields/)
    58 * On GitHub: [Advanced Term Fields](https://github.com/dboutote/Advanced-Term-Fields)
     48Nope!  It _used_ to depend on the Advanced Term Fields plugin, but as of version 1.0, all functionality has been incorporated into this plugin.
    5949
    6050= Does this create/modify/destroy database tables? =
     
    6252This leverages the term meta capabilities added in WordPress 4.4.  No database modifications needed!
    6353
    64 = Are there other extensions? =
     54= Are there other plugins in this family? =
    6555
    66 Yep!  This is a list of all current extensions:
     56Yep!  This is a list of all current term meta plugins:
    6757
    68 * [Advanced Term Fields: Colors](https://wordpress.org/plugins/advanced-term-fields-featured-images/)
    69 * [Advanced Term Fields: Icons](https://wordpress.org/plugins/advanced-term-fields-icons/)
    70 * [Advanced Term Fields: Featured Images](https://wordpress.org/plugins/advanced-term-fields-featured-images/)
     58* [Advanced Term Colors](https://wordpress.org/plugins/advanced-term-fields-colors/)
     59* [Advanced Term Icons](https://wordpress.org/plugins/advanced-term-fields-icons/)
     60* [Advanced Term Images](https://wordpress.org/plugins/advanced-term-fields-featured-images/)
     61* [Advanced Term Locks](https://wordpress.org/plugins/advanced-term-fields-locks/)
    7162
    7263== Screenshots ==
    7364
    74 1. Custom column to the Tag List Table.
     651. Custom column on the Tag List Table.
    75662. Select your image using the native WordPress media picker.
    76673. Accessible from the Quick Edit form
     
    7970
    8071== Changelog ==
     72
     73= 1.0 =
     74* Incorporated Advanced Term Fields framework into plugin.
     75* Namespaced all option keys.
     76* WP 4.5 Compatibility updates: added 'load-term.php' action hook.
     77* Bug fix: on quick edit form when $taxonomy is not defined.
    8178
    8279= 0.1.1 =
     
    8885= 0.1.0 =
    8986* Initial release
     87
     88== Upgrade Notice ==
     89
     90= 1.0 =
     91This version fixes compatibility issues with WP 4.5.
     92
     93
     94
Note: See TracChangeset for help on using the changeset viewer.