• Resolved brand-dedication

    (@brand-dedication)


    Hi,

    I don’t know why but I couldn’t get anything to display on the frontend from the enhanced edit page.

    Can you give me an example of what I should do with the code below?

    I’m not a code guru, but I know more than a little bit.

    I’m working from a framework and child theme, maybe there is something else I need to look into to get this to work?

    <?php global $wp_query;
    /**
     * The template for displaying Category pages.
     */
    
    get_header(); ?>
    
    	<section id="primary" class="site-content">
    		<div id="content" role="main">
    
    			<header class="archive-header">
    				<h1 class="archive-title"><?php echo single_cat_title( '', false ); ?></h1>
    			</header><!-- .archive-header -->
    
    			<?php 
    
    			if ( have_posts() ) :
    
    				// The default query for this page
    				$args = $wp_query->query;
    
    				// Get the blog template
    				get_theme_blog_template( $args );
    
    			endif; 
    
    			?>
    		</div><!-- #content -->
    	</section><!-- #primary -->
    
    <?php get_sidebar(); ?>
    <?php get_footer(); ?>

    Thanks!

    https://www.ads-software.com/plugins/enhanced-category-pages/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author cip

    (@cip)

    Hi!

    Have you noticed and managed to read the installation section of the plugin page? Enhanced Category Pages – Installation

    The basic idea is to use $enhanced_category global variable that our plugin sets, more specifically: $enhanced_category->setup_ec_data() – this call gets enhanced category post and set it up as global current post. From this point forward global $post is the enhanced page.

    Using your code to show the content and the enhanced of the enhanced page of the category:

    <?php global $wp_query;
    /**
     * The template for displaying Category pages.
     */
    
    get_header(); ?>
    
    	<section id="primary" class="site-content">
    		<div id="content" role="main">
    
    			<header class="archive-header">
    				<h1 class="archive-title"><?php echo single_cat_title( '', false ); ?></h1>
    			</header><!-- .archive-header -->
    
    		    <?php
    		        global $enhanced_category;
    		        //get enhanced category post and set it up as global current post
    		        $enhanced_category->setup_ec_data();
    		    ?>
    
    		    <!-- enhanced category content -->
    
    		    <!-- featured image -->
    		    <?php the_post_thumbnail("medium"); ?>
    
    			<!-- content -->
    			<?php the_content(); ?>
    
    			<?php 
    
    			if ( have_posts() ) :
    
    				// The default query for this page
    				$args = $wp_query->query;
    
    				// Get the blog template
    				get_theme_blog_template( $args );
    
    			endif; 
    
    			?>
    		</div><!-- #content -->
    	</section><!-- #primary -->
    
    <?php get_sidebar(); ?>
    <?php get_footer(); ?>

    I hope I managed to explain it to you so you can create great projects using Enhanced Category Pages.

    PS: We would appreciate a 5 Star if have found the plugin useful.

    Thread Starter brand-dedication

    (@brand-dedication)

    Thank cip!

    This code worked and this is awesome. It really gives more power over a theme, the category look, feel and branding!

    Yes, I read the install and other description of the plugin. I must of been missing a piece of code.

    So now I got it to work easily.

    Question… Is there any custom post type reference I can use to extend third party metaboxes to the Enhanced Category Page admin?

    For example, a portfolio custom post type would have the custom post type name of “portfolio”. Then I can add in the array something like…

    array('page','post','portfolio'));

    That would extend my metaboxes to the portfolio pages.

    Basically what I’m trying to do with the category pages is extend 2 things there.

    1. Support for Visual Composer because I want to create the category feed, look and layout there with the Visual Composer elements.

    2. Add my theme’s metabox options there because it allows for more layout options.

    I went through the code but I couldn’t find anything there for it like typical custom post types and the ‘_builtin’ I’m not familiar with and what I tried didn’t work.

    Or could there be some snippet I could add as a function to enable this functionality?

    Plugin Author cip

    (@cip)

    Hi Noahj!

    Is this still pending?

    The plugin adds custom post type called enhancedcategory in order to manage the category custom pages.

    You can add any features to it as you would with any other custom post type.

    Let me know if this solved your issue.

    Please note that we also offer premium paid support and custom WP/PHP development, so feel free to contact me to discuss further.

    Thread Starter brand-dedication

    (@brand-dedication)

    Hey cip!

    Thanks for following back. I hadn’t got back to this, so I did right now.

    The enhancedcategory post type works perfectly, though my framework layout options don’t to the category layout yet. But, that’s for me to figure out.

    When I finish everything I will write a post about it.

    This is a really great extension to categories.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Hi, looks great and clever but I need a little help.’ is closed to new replies.