Skip to content

Instantly share code, notes, and snippets.

@amdrew
Last active January 19, 2016 14:22
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 amdrew/7443009 to your computer and use it in GitHub Desktop.
Save amdrew/7443009 to your computer and use it in GitHub Desktop.
Add 'page-attributes' to the download post type in Easy Digital Downloads. This adds a "Sort By Order" to the download admin screen, where you can use drag and drop ordering with the Simple Page Ordering WordPress plugin.
<?php
function my_child_theme_edd_download_supports( $supports ) {
// add page-attributes
$add_support = array( 'page-attributes' );
// merge it back with the original array
return array_merge( $add_support, $supports );
}
add_filter( 'edd_download_supports', 'my_child_theme_edd_download_supports' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment