Created
July 23, 2014 11:05
-
-
Save tjhole/4f5cd39b4747363d72a9 to your computer and use it in GitHub Desktop.
WORDPRESS: Custom Post Type Front Page - 2014
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function wpa18013_add_pages_to_dropdown( $pages, $r ){ | |
if('page_on_front' == $r['name']){ | |
$args = array( | |
'post_type' => 'stack' | |
); | |
$stacks = get_posts($args); | |
$pages = array_merge($pages, $stacks); | |
} | |
return $pages; | |
} | |
add_filter( 'get_pages', 'wpa18013_add_pages_to_dropdown', 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment