Support » Theme: Enough » Feature Image TOP of Blog CONTENT EDITING

Viewing 1 replies (of 1 total)
  • Theme Author nobita

    (@nobita)

    Hi brieferbob

    If you can use PHP

    Please add functions.php

    <?php
    /**
     * Add Advertisement featured image before
     */
    add_filter('enough_post_thumbnail', 'extend_enough_post_thumbnail');
    
    function extend_enough_post_thumbnail( $post_thumbnail_image ){
    	/*
    	 * HTML of Advertisement
    	 */
    			$ad = '<div><h1 class="ad">Hello World</h1></div>';
    	/*
    	 * Return featured image + ad
    	 */
    			return $ad. $post_thumbnail_image;
    
    }
    ?>
    <?php
    /**
     * Remove featured image
     */
    add_filter('enough_post_thumbnail', '__return_empty_string');
    ?>

    If success Please make Child Theme

    add child themes functions.php above code.

    https://codex.wordpress.org/Child_Themes

    Thank you

    Note: Featured image code exists content.php template line 11

    <?php
        if ( !post_password_required() && is_singular() ) {
            echo apply_filters( 'enough_post_thumbnail', get_the_post_thumbnail() );
        }
Viewing 1 replies (of 1 total)
  • The topic ‘Feature Image TOP of Blog CONTENT EDITING’ is closed to new replies.