badget

Biggest Sale! Special Offer!

Get 30% discount on all of our single themes with this coupon code: #30%SALE

Hurry up! *Limited time offer*

Create simple page template without slider

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #24646
    pavlo.golub
    Participant

    First of all, please accept my sincere condolences about the disaster happened in your country. I’m absolutely speechless. We are all praying for Nepal.

    I wrote a plug-in which allows user download some content. I wish to have ability to show some error message if something is going wrong:

    			if ($failed_payment) {
    				get_header();
    				echo '<div class="error"><p>';
    				_e( 'Some error occurred during payment!', 'pgmysite' );
    				echo '</p></div>';
    				get_footer();
    			}

    However get_header() function outputs slider which is set for home page. How can I get rid of this slider and have clean page without any sidebars\elemets\etc.?

    Thanks in advance!

    #24665

    Hi pavlo.golub,

    Thanks for your condolences and praying for our country.

    Yes get_header() will outputs the slider which is set for home page. You need to create a child theme and first unhook the functions and then you need to customize the code. There will be a a bit more code of customization so you need to hire a developer to fix it.
    example to unhook :-
    unhook functions

    
    // Unhook default Thematic functions
    function unhook_thematic_functions() {
        // Don't forget the position number if the original function has one
    
    remove_action( 'interface_404_content', 'interface_display_404_page_content', 10 );
    
    }
    add_action('init','unhook_thematic_functions'); // removes the header content by using hook interface_header
    
    add_action( 'interface_404_content', 'interface_child_display_404_page_content', 10 );
     
    function interface_child_display_404_page_content() {      ?>   
    <div id="content">
    		<header class="entry-header">
    			<h1 class="entry-title"><?php _e( 'Error 404-Page NOT Found', 'interface' ); ?></h1>
    		</header>
    		<div class="entry-content clearfix" >
    			<p>Thank you</p> 
    		</div><!-- .entry-content -->
    	</div><!-- #content -->
      <?php 
    }

    Thank you!

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.