custom post types shortode stays on top of other page contents. Is there a bug?

You have this code in your shortcode function: if( count($posts) ): echo ‘<ul id=”portfolio-grid” class=”portfolio-grid unstyled ‘.$post_columns.’-cols”>’; foreach( $posts as $post ) : setup_postdata( $post ); ?> <li> <a href=”https://wordpress.stackexchange.com/questions/104016/<?php the_permalink(); ?>” data-largesrc=”<?php if ( has_post_thumbnail() ) { echo ub_featured_img_url(‘portfolio-fullsize’); } else { ?>http://placehold.it/600&text=<?php _e(‘No Thumbnails’, ‘une_boutique’); } ?>” data-title=”<?php the_title() ?>” data-button=”<?php _e(‘View Project’, … Read more

Page templates for custom post types

You can certainly set up a page template for custom post types. Give this a whirl: <?php /* Template Name: Your template name */ // Get header get_header(); ?> <div id=”primary”> <?php // Query post type $the_query = new WP_Query( array( ‘post_type’ => ‘cpt_name’, ‘posts_per_page’ => -1 ) ); if ( $the_query->have_posts() ) : ?> … Read more

Custom Plugin w/ Custom Post Types – Custom Posts Are Showing at all Privilege Levels – Is this possible to adjust?

Yes this is possible. Add the following to either your plugin code or the theme’s functions.php file: function mypo_parse_query_useronly( $wp_query ) { if ( strpos( $_SERVER[ ‘REQUEST_URI’ ], ‘/wp-admin/edit.php’ ) !== false ) { if ( !current_user_can( ‘update_core’ ) ) { global $current_user; $wp_query->set( ‘author’, $current_user->id ); } } } add_filter(‘parse_query’, ‘mypo_parse_query_useronly’ ); Reference original … Read more