Changeset 1774316
- Timestamp:
- 11/23/2017 07:57:15 PM (8 years ago)
- Location:
- wp-moo-tree/trunk
- Files:
-
- 3 edited
-
README.txt (modified) (2 diffs)
-
tree-shortcode.php (modified) (5 diffs)
-
wp-moo-tree.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
wp-moo-tree/trunk/README.txt
r620906 r1774316 7 7 Tags: genealogy, file tree, family tree, tree, hierarchy, hierarchy tree, files, family, families, folders, folder list, file list, list, family list, 8 8 Requires at least: 3.0.1 9 Tested up to: 3.410 Stable tag: 1. 0.59 Tested up to: 4.9 10 Stable tag: 1.1.0 11 11 License: GPLv2 or later 12 12 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 69 69 70 70 == Changelog == 71 = 1.1.0 = 72 * Bug fix; Multiple categories were displayed when only one expected. 71 73 = 1.0.5 = 72 74 * minor bug fix; when creating new category, fields would not save, had to be edited after creation. -
wp-moo-tree/trunk/tree-shortcode.php
r600840 r1774316 92 92 'title_li' => '', 93 93 'echo' => 0, 94 //'child_of' => $taxonomy_term->term_id, 94 95 'sort_column' => 'post_date', 95 96 'post_type' => 'mootree', 96 97 'post_status' => 'publish', 97 98 'walker' => $mootree_walker, 99 'link_before' => $taxonomy_term->term_id, 98 100 'link_after' => 'mootree' 99 101 ); … … 102 104 $piecesof .= '</ul>'; 103 105 $piecesof .= '<div style="clear:both;padding-top:20px"></div>'; 104 return $piecesof ;106 return $piecesof . "<br/><br/><br/><pre>" . $thelist . "</pre>"; 105 107 }//funct 106 108 … … 141 143 142 144 if($link_after == 'mootree'){ 143 145 $termID = (int)$link_before; 146 $term_list = wp_get_post_terms($page->ID, 'tree-categories', array("fields" => "ids")); 144 147 if(has_post_thumbnail($page->ID)) { 145 148 $printlink = wp_get_attachment_url( get_post_thumbnail_id($page->ID) ); … … 175 178 if ($thdescript && $thdescript != ""){$commentatts .= 'description: ' . $thdescript . ';';} 176 179 177 $output .= $indent . '<li class="' . $page->post_name . '" ><a href="' . $printlink . '" name="' . $page->post_name . '" title="" ><!-- ' . $commentatts . ' -->' . apply_filters( 'the_title', $page->post_title, $page->ID ) . '</a>'; 180 if(in_array($termID, $term_list)){ 181 $output .= $indent . '<li class="' . $page->post_name . '" ><a href="' . $printlink . '" name="' . $page->post_name . '" title="" ><!-- ' . $commentatts . ' -->' . apply_filters( 'the_title', $page->post_title, $page->ID ) . '</a>'; 182 } 178 183 179 184 … … 195 200 } 196 201 202 function end_el(&$output, $page, $depth = 0, $args = array()){ 203 $partOfCateg = false; 204 if($link_after == 'mootree'){ 205 $termID = (int)$link_before; 206 $term_list = wp_get_post_terms($page->ID, 'tree-categories', array("fields" => "ids")); 207 if(in_array($termID, $term_list)){ 208 if(isset( $args['item_spacing']) && 'preserve' === $args['item_spacing']){ 209 $t = "\t"; 210 $n = "\n"; 211 }else{ 212 $t = ''; 213 $n = ''; 214 } 215 $output .= "</li>{$n}"; 216 } 217 }else{ 218 if(isset( $args['item_spacing']) && 'preserve' === $args['item_spacing']){ 219 $t = "\t"; 220 $n = "\n"; 221 }else{ 222 $t = ''; 223 $n = ''; 224 } 225 $output .= "</li>{$n}"; 226 } 227 } 228 197 229 } 198 230 ?> -
wp-moo-tree/trunk/wp-moo-tree.php
r620906 r1774316 4 4 *Plugin URI: http://aryanduntley.com/wordpressplugins/mootree 5 5 *Description: Generates file, geneology, etc., trees via custom post types. 6 *Version: 1. 0.56 *Version: 1.1.0 7 7 *Author: Aryan Duntley 8 8 *Author URI: http://aryanduntley.com/
Note: See TracChangeset
for help on using the changeset viewer.