Okay
  Public Ticket #304276
Custom page template based on nectar_page_header
Closed

Comments

  • Philipp started the conversation

    Hi,

    I want to create a custom page template which is very similar to the normal page template incl. its header. Only difference is that I need to insert some HTML instead of the normal page title.

    I already set up a template like this:

    <?php 
    /*template name: Home - Custom */
    get_header(); ?>
    
    
    <?php nectar_page_header($post->ID); ?>
    
    
    <div class="home-wrap">
    
    
    	<div class="container main-content">
    		
    		<div class="row">
    	
    			<?php if(have_posts()) : while(have_posts()) : the_post(); ?>
    				
    				<?php the_content(); ?>
    	
    			<?php endwhile; endif; ?>
    				
    		</div><!--/row-->
    
    
    	</div><!--/container-->
    
    
    </div><!--/home-wrap-->
    	
    <?php get_footer(); ?>
    

    But my problem is that the part I want to edit is in nectar_page_header.

    What's the most clever way for doing so?

    Thanks,
    Philipp

  •  8,839
    Tahir replied

    Hey Philipp!

    You will have to copy the nectar_page_header function and rename it and make the edits to it. Then call that function in the Page template. 

    Thanks 


    ThemeNectar Support Team 

  • Philipp replied

    Hey Tahir,

    so that would be in functions.php?

  •  8,839
    Tahir replied

    Yes though it should work in the page template as well. 

    Thanks


    ThemeNectar Support Team