Price Option Not Checked

function sumobi_edd_price_option_checked( $checked, $download_id, $key ) { return ”; } add_filter( ‘edd_price_option_checked’, ‘sumobi_edd_price_option_checked’, 10, 3 );Continue reading

Variable Pricing Dropdown

function edd_library_variable_price_dropdown() { function shoestrap_edd_purchase_variable_pricing( $download_id ) { $variable_pricing = edd_has_variable_prices( $download_id ); if ( ! $variable_pricing ) return; $prices = apply_filters( ‘edd_purchase_variable_prices’, edd_get_variable_prices( $download_id ), $download_id ); $type = edd_single_price_option_mode( $download_id ) ? ‘checkbox’ : ‘radio’; do_action( ‘edd_before_price_options’, $download_id…Continue reading

Taxonomy Count

// adjust downloads taxonomy loop function custom_download_tag_count( $query ) { if ( ( $query->is_tax( ‘download_category’ ) || $query->is_tax( ‘download_tag’ ) ) && ! is_admin() && $query->is_main_query() ) { // replace 15 with desired amount $query->set( ‘posts_per_page’, 15 ); } }…Continue reading

Replace Add to Cart with Download

function ck_edd_user_download_button( $purchase_form, $args ) { global $edd_options; if ( !is_user_logged_in() ) { return $purchase_form; } $download_id = (string)$args[‘download_id’]; $current_user_id = get_current_user_id(); // If the user has purchased this item, itterate through their purchases to get the specific // purchase…Continue reading

Show Featured Image With Purchase Link

function sumobi_edd_purchase_link_show_featured_image( $download_id ) { echo get_the_post_thumbnail( $download_id, ‘thumbnail’ ); } add_action( ‘edd_purchase_link_top’, ‘sumobi_edd_purchase_link_show_featured_image’ );Continue reading

Reverse variable pricing

function sumobi_edd_purchase_variable_prices( $variable_prices, $download_id ) { krsort( $variable_prices ); return $variable_prices; } add_filter( ‘edd_purchase_variable_prices’, ‘sumobi_edd_purchase_variable_prices’, 10, 2 ); /** * make sure the last option in array is checked (highest priced item) */ function sumobi_edd_price_option_checked( $checked, $download_id, $key ) {…Continue reading

Download Archive Purchase Buttons

// remove original filter that adds purchase button below download content remove_filter( ‘the_content’, ‘edd_after_download_content’ ); // add adjusted filter that includes “is_archive()” function custom_edd_after_download_content( $content ) { global $post; if ( $post && $post->post_type == ‘download’ && ( is_singular( ‘download’…Continue reading