Plugin Directory

Changeset 1804034


Ignore:
Timestamp:
01/16/2018 08:51:10 PM (7 years ago)
Author:
JorgeAmVF
Message:

better-formed readme.txt file provided

Location:
catag/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • catag/trunk/catag.php

    r1732160 r1804034  
    22/*
    33* Plugin Name: autometa's CATAG
    4 * Description: It reproduces categories and tags and it generates a cloud mixing categories and tags of posts simply via: [cats] and [tags] and [catag].
    5 * Version: 1.2
     4* Description: It reproduces post categories and tags in posts and it generates a cloud mixing categories and tags of posts simply via: [cats] and [tags] and [catag].
     5* Version: 2.0
    66* Author: JorgeAmVF
    77* Author URI: https://profiles.wordpress.org/jorgeamvf/
     
    2626*/
    2727
    28 // [cats] = categories (post)
    29 function autometa_post_categories($atts, $content = null){
    30 global $post;
    31 $autometascategories = get_the_category_list($separator = ' ', $post->ID);
    32  return '<div id = "cats" class = "autometa">' . $autometascategories . '</div>';
     28// [cats] = (post) categories
     29function autometa_post_categories( $atts, $content = null ) {
     30    global $post;
     31    $am_cats = '<span id="cats" class="autometa">' .get_the_category_list( $separator = ' ', $post->ID ) . '</span>';
     32        return $am_cats;
    3333}
    34 add_shortcode("cats","autometa_post_categories");
     34add_shortcode( "cats", "autometa_post_categories" );
    3535
    36 // [tags] = tags (post)
    37 function autometa_post_tags($atts, $content = null){
    38 global $post;
    39 $autometastags = get_the_term_list($post->ID, 'post_tag', $separator = ' ');
    40  return '<div id = "tags" class = "autometa">' . $autometastags . '</div>';
     36// [tags] = (post) tags
     37function autometa_post_tags( $atts, $content = null ) {
     38    global $post;
     39    $am_tags = '<span id="tags" class="autometa">' . get_the_term_list( $post->ID, 'post_tag', $separator = ' ' ) . '</span>';
     40        return $am_tags;
    4141}
    42 add_shortcode("tags","autometa_post_tags");
     42add_shortcode( "tags", "autometa_post_tags" );
    4343
    44 // [catag] = categories & tags (post)
    45 function autometa_post_taxonomy($echo = false){
    46  if (function_exists('wp_tag_cloud'))
    47   return wp_tag_cloud(array('number' => 0, 'orderby' => 'count', 'order' => 'RAND', 'taxonomy' => array('post_tag', 'category'),));
     44// [catag] = (post) categories & tags
     45function autometa_post_taxonomies( $echo = false ) {
     46    if ( function_exists( 'wp_tag_cloud') )
     47        $am_catag  = '<span id="catag" class="autometa">' . wp_tag_cloud( array(
     48            'number' => 0,
     49            'orderby' => 'count',
     50            'order' => 'RAND',
     51            'taxonomy' => array(
     52                'post_tag',
     53                'category'
     54            ),
     55        ) ) . '</span>';
     56            return $am_catag;
    4857}
    49 add_shortcode("catag","autometa_post_taxonomy");
     58add_shortcode( "catag", "autometa_post_taxonomies" );
    5059?>
  • catag/trunk/readme.txt

    r1732160 r1804034  
    44Tags: shortcode, automation, metadata, taxonomy, cloud, category, tag
    55Requires at least: 2.5.0
    6 Tested up to: 4.8.1
     6Tested up to: 4.9.1
    77Stable Tag: trunk
    88License: GPLv2 or later
    99License URI: http://www.gnu.org/licenses/gpl-2.0.html
    1010
    11 It reproduces categories and tags and it generates a cloud mixing categories and tags of posts simply via: [cats] and [tags] and [catag].
     11It reproduces categories and tags in posts and it generates a cloud mixing categories and tags of posts simply via: `[cats]` and `[tags]` and `[catag]`.
    1212== Description ==
    1313 
    1414**autometa's CATAG** is a simple plugin that uses the following shortcodes:
    1515
    16 * *[cats]*  = to reproduce the categories of a post;
    17 * *[tags]*  = to reproduce the tags of a post;
    18 * *[catag]* = to generate a taxonomy cloud mixing categories and tags of posts.
     16* `[cats]`  = to reproduce post categories;
     17* `[tags]`  = to reproduce post tags;
     18* `[catag]` = to generate a taxonomy cloud mixing categories and tags of posts.
    1919
    20 **autometa's CATAG** is an element of **[autometa](https://wordpress.org/plugins/autometa/)** plugin set.
    21 
    22 == Installation ==
    23 
    24 1. Download it or install it to your plugin folder;
    25 2. Activate it from the plugin tab inside your dashboard;
    26 3. Write the following shortcodes in text fields of posts: *[cats]*, *[tags]*, *[catag]*.
     20**autometa's CATAG** is a standalone component of **[autometa](https://wordpress.org/plugins/autometa/)** shortcodes pack.
    2721
    2822== Frequently Asked Questions ==
    2923
    30 = How does autometa's CATAG work? =
     24= Installation Instructions =
    3125
    32 **[autometa](https://wordpress.org/plugins/autometa/)** reproduces metadata information automatically via shorcodes in general, **autometa's CATAG** reproduces categories and tags of posts in special.
     261. Install it from *Dashboard*/*Plugins*/*Add Plugins* or download it to your plugin folder;
     272. Activate it from *Dashboard*/*Plugins*/*Installed Plugins*;
     283. Write the following shortcodes in text fields:  `[cats]`, `[tags]`, `[catag]`.
    3329
    34 = What is needed to use autometa's CATAG? =
     30= Plugin Features =
    3531
    36 Just write one or more of the following shortcodes inside a text field of a post and between brackets as usual: *[cats]* and/or *[tags]* and/or *[catag]*.
     32**[autometa](https://wordpress.org/plugins/autometa/)** reproduces metadata information automatically via shorcodes in general, **autometa's CATAG** reproduces post taxonomy-related data in special.
    3733
    38 = Where should autometa's CATAG be placed? =
     34= How To =
    3935
    40 *[cats]* and *[tags]* must be written only inside a text field of a post since it might crash the page if the referred shortcodes are written inside pages, portfolios or products whether the plugin is active once there is no correspondent taxonomy to be reproduced in those environments; otherwise, as *[catag]* reproduces categories and tags from all posts, it can be easily placed inside pages, posts, portfolios or products at ease.
     36Just write one or more of the following shortcodes inside a text field and between brackets as usual: `[urlug]` and/or `[urlink]` and/or `[urlinked]`.
    4137
    42 = Which functions are used by autometa's CATAG? =
     38= CSS Style Selectors =
    4339
    44 These: [`add_shortcode()`](https://developer.wordpress.org/reference/functions/add_shortcode/) and [`get_the_category_list()`](https://developer.wordpress.org/reference/functions/get_the_category_list/) and [`get_the_term_list()`](https://developer.wordpress.org/reference/functions/get_the_term_list/) and [`wp_tag_cloud()`](https://developer.wordpress.org/reference/functions/wp_tag_cloud/).
     40* `#cats`     = `[cats]` ID;
     41* `#tags`     = `[tags]` ID;
     42* `#catag`    = `[catag]` ID;
     43* `.autometa` = **autometa** class.
     44
     45= PHP Functions Reference =
     46
     47* [`add_shortcode()`](https://developer.wordpress.org/reference/functions/add_shortcode/)
     48* [`get_the_category_list()`](https://developer.wordpress.org/reference/functions/get_the_category_list/)
     49* [`get_the_term_list()`](https://developer.wordpress.org/reference/functions/get_the_term_list/)
     50* [`wp_tag_cloud()`](https://developer.wordpress.org/reference/functions/wp_tag_cloud/)
Note: See TracChangeset for help on using the changeset viewer.