Skip to content

Instantly share code, notes, and snippets.

@maurisrx
Created February 6, 2015 01:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maurisrx/8935f0fe689843b38d79 to your computer and use it in GitHub Desktop.
Save maurisrx/8935f0fe689843b38d79 to your computer and use it in GitHub Desktop.
1st snipper in post "Create Custom Easy Digital Downloads Archive Page"
<?php
/** Force the full width layout on the EDD archive page */
add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' );
/** Remove the standard genesis loop */
remove_action( 'genesis_loop', 'genesis_do_loop' );
/** Add the products area */
add_action( 'genesis_loop', 'prfx_edd_downloads' );
function prfx_edd_downloads() {
$prfx_edd = '<h1 class="entry-title">Premium WordPress Plugins</h1>';
$prfx_edd .= do_shortcode( '[downloads category="premium" number="15" columns="3" price="no" buy_button="no" excerpt="yes" thumbnails="true"]' );
$prfx_edd .= '<h1 class="entry-title">Free WordPress Plugins</h1>';
$prfx_edd .= do_shortcode( '[downloads category="free" number="15" columns="3" price="no" buy_button="no" excerpt="yes" thumbnails="true"]' );
echo $prfx_edd;
}
genesis();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment