Changeset 1531227
- Timestamp:
- 11/09/2016 08:51:49 PM (9 years ago)
- Location:
- sell-media/trunk
- Files:
-
- 9 edited
-
inc/admin-payments.php (modified) (1 diff)
-
inc/class-layouts.php (modified) (2 diffs)
-
inc/class-search.php (modified) (1 diff)
-
inc/deprecated.php (modified) (1 diff)
-
inc/helpers.php (modified) (2 diffs)
-
inc/shortcodes.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
-
sell-media.php (modified) (3 diffs)
-
themes/archive.php (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
sell-media/trunk/inc/admin-payments.php
r1525073 r1531227 404 404 if ( $products ) foreach ( $products as $product ) { 405 405 $type = ( ! empty( $product['type'] ) ) ? ' (' . $product['type'] . ') ' : ''; 406 echo $product['name'] . $type. '<br />';406 echo apply_filters( 'sell_media_payment_products_column', $product['name'] . $type, $post_id ) . '<br />'; 407 407 } 408 408 break; -
sell-media/trunk/inc/class-layouts.php
r1528637 r1531227 63 63 add_filter( 'the_content', array( $this, 'after_content' ) ); 64 64 65 // Remove prepended attachment from attachment template in core WP 66 add_filter( 'prepend_attachment', array( $this, 'remove_prepend_attachment' ) ); 67 65 68 // Content loop 66 69 add_filter( 'sell_media_content_loop', array( $this, 'content_loop' ), 10, 3 ); … … 288 291 289 292 /** 293 * Remove the prepended attachment from WordPress core attachment template 294 * since we're already appending it via the_content filter 295 * @return 296 */ 297 function remove_prepend_attachment( $p ) { 298 299 global $post; 300 301 if ( sell_media_attachment( $post->ID ) ) { 302 $p = ''; 303 } 304 305 return $p; 306 } 307 308 /** 290 309 * Main content loop used in all themes 291 310 * @return string html -
sell-media/trunk/inc/class-search.php
r1525073 r1531227 113 113 114 114 // only run the query on the actual search results page. 115 if ( is_page( $settings->search_page ) && 1 === did_action( 'the_post') ) {115 if ( is_page( $settings->search_page ) && in_the_loop() ) { 116 116 117 117 // The search terms -
sell-media/trunk/inc/deprecated.php
r1525073 r1531227 35 35 sell_media_get_taxonomy_terms( 'collection' ); 36 36 } 37 38 /** 39 * Sell Media content loop. 40 * 41 * @deprecated 2.2.6 Use sell_media_content_loop filter. 42 */ 43 function sell_media_content_loop( $post_id, $index ) { 44 _deprecated_function( __FUNCTION__, '2.2.6', 'sell_media_content_loop filter' ); 45 return apply_filters( 'sell_media_content_loop', $post_id, $index ); 46 } -
sell-media/trunk/inc/helpers.php
r1527623 r1531227 23 23 $post_type = array( 'sell_media_item', 'attachment' ); 24 24 $sell_media_taxonomies = get_object_taxonomies( $post_type ); 25 $sm_archive_template = SELL_MEDIA_PLUGIN_DIR . '/themes/archive.php'; 25 26 26 27 /** … … 31 32 if ( $overridden_template = locate_template( 'archive-sell-media.php' ) ) { 32 33 $template = $overridden_template; 34 } elseif ( file_exists( $sm_archive_template ) ) { 35 $template = $sm_archive_template; 33 36 } else { 34 $template = SELL_MEDIA_PLUGIN_DIR . '/themes/archive.php';37 $template = $original_template; 35 38 } 36 39 } elseif ( sell_media_attachment( $post->ID ) ) { -
sell-media/trunk/inc/shortcodes.php
r1525073 r1531227 185 185 <div class="item-image"> 186 186 <?php 187 if ( ! empty( $item['item_attachment'] ) ){ 188 echo sell_media_item_icon( $item['item_attachment'] ); 187 if ( ! empty( $item['item_attachment'] ) ) { 188 // if selling video or audio, show the post_id thumbnail 189 if ( SellMediaAudioVideo::is_video_item( $item['item_id'] ) || SellMediaAudioVideo::is_audio_item( $item['item_id'] ) ) { 190 echo sell_media_item_icon( $item['item_id'] ); 191 } else { 192 echo sell_media_item_icon( $item['item_attachment'] ); 193 } 189 194 } 190 195 ?> -
sell-media/trunk/readme.txt
r1528637 r1531227 6 6 Requires at least: 3.4 7 7 Tested up to: 4.5.2 8 Stable tag: 2.2. 98 Stable tag: 2.2.11 9 9 License: GPLv2 or later 10 10 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 215 215 216 216 == Changelog == 217 218 = 2.2.11 = 219 * Fix: Double featured images in some themes 220 * Fix: SEO plugin conflict 221 * Fix: Add sell_media_content_loop function in deprecated list 222 * New: Add products column filter 217 223 218 224 = 2.2.10 = -
sell-media/trunk/sell-media.php
r1528637 r1531227 4 4 * Plugin URI: http://graphpaperpress.com/plugins/sell-media/ 5 5 * Description: A plugin for selling photos, prints and other downloads. 6 * Version: 2.2.1 06 * Version: 2.2.11 7 7 * Author: Graph Paper Press 8 8 * Author URI: http://graphpaperpress.com … … 25 25 * @category Core 26 26 * @author Thad Allender 27 * @version 2.2.1 027 * @version 2.2.11 28 28 */ 29 29 … … 178 178 // Plugin version. 179 179 if ( ! defined( 'SELL_MEDIA_VERSION' ) ) { 180 define( 'SELL_MEDIA_VERSION', '2.2.1 0' );180 define( 'SELL_MEDIA_VERSION', '2.2.11' ); 181 181 } 182 182 -
sell-media/trunk/themes/archive.php
r1525073 r1531227 23 23 <h1 class="sell-media-page-title"> 24 24 <?php 25 if ( is_search() ) {26 printf( __( 'Search results for: %1$s', 'sell_media' ), get_search_query() );27 } elseif ( is_post_type_archive( 'sell_media_item' ) ) {28 $obj = get_post_type_object( 'sell_media_item' );29 echo esc_attr( ucfirst( $obj->rewrite['slug'] ) );30 } else {31 the_archive_title();32 }25 if ( is_search() ) { 26 printf( __( 'Search results for: %1$s', 'sell_media' ), get_search_query() ); 27 } elseif ( is_post_type_archive( 'sell_media_item' ) ) { 28 $obj = get_post_type_object( 'sell_media_item' ); 29 echo esc_attr( ucfirst( $obj->rewrite['slug'] ) ); 30 } else { 31 the_archive_title(); 32 } 33 33 ?> 34 34 </h1> 35 35 <?php 36 $term_description = term_description();37 if ( ! empty( $term_description ) ) {38 echo '<h2 class="collection_description">' . $term_description . '</h2>';39 }36 $term_description = term_description(); 37 if ( ! empty( $term_description ) ) { 38 echo '<h2 class="collection_description">' . $term_description . '</h2>'; 39 } 40 40 ?> 41 41 <?php echo do_shortcode( '[sell_media_searchform]' ); ?> … … 48 48 <?php 49 49 // check if this term has child terms, if so, show terms 50 $term_ ID= $wp_query->get_queried_object_id();51 $children = get_term_children( $term_ ID, 'collection' );50 $term_id = $wp_query->get_queried_object_id(); 51 $children = get_term_children( $term_id, 'collection' ); 52 52 53 53 if ( $children ) : … … 58 58 'orderby' => 'name', 59 59 'hide_empty' => false, 60 'parent' => $term_ ID60 'parent' => $term_id, 61 61 ); 62 62 … … 73 73 'taxonomy' => 'collection', 74 74 'field' => 'slug', 75 'term' => $child->slug 75 'term' => $child->slug, 76 76 ); 77 77 $posts = New WP_Query( $args ); … … 79 79 $post_count = $posts->found_posts; 80 80 81 if ( $post_count != 0 ) : $i++; ?> 81 if ( $post_count != 0 ) : 82 $i++; ?> 82 83 83 84 <div class="<?php echo apply_filters( 'sell_media_grid_item_class', 'sell-media-grid-item', NULL ); ?>"> … … 137 138 </div><!-- .sell-media-grid-item-container --> 138 139 <?php 139 if ( !$children ){140 echo sell_media_pagination_filter( $wp_query->max_num_pages ); 140 if ( ! $children ) { 141 echo sell_media_pagination_filter( $wp_query->max_num_pages ); 141 142 } 142 143 ?>
Note: See TracChangeset
for help on using the changeset viewer.