Tagged: , ,

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #44058
    Josh
    Participant

    Hello, I am hoping to allow my Home Page to show static text above the blog excerpts as an introduction to the blog. In the “Settings -> Reading” area I have set my “front page” to be “static,” and I designated a particular page. In the “Edit Page” area of that particular page I have set it to “Blog” rather than “Default Template.” Ideally, I would like the same text/code that appears in that particular page’s “Edit Page” section to appear above the blog post excerpts, but at this point I will settle for any method to add static text/code above the excerpts. I found the following code for a different theme, and attempted to add it to my child theme’s functions.php file, but it didn’t work:

    // Add content of page called "blog" to the page that contains the list of blog posts
    add_action  ( '__before_loop', 'add_blog_page_content_before_post_list');
    function add_blog_page_content_before_post_list() {
        if ( is_home() ) {
            $post = get_page_by_path( '/blog' );
            echo wpautop($post->post_content);
        }
    }

    Any help is greatly appreciated. Thanks for a great theme and for always having great support!

    [btw my site is not live. I can email admin credentials if necessary]

    #44068
    Sakin
    Keymaster

    @jmott310: Did you try in Homepage Headline Text options at “Appearance => Theme Options => Homepage Settings => Homepage Headlines”. Then add in the text in Homepage Headline and Homepage Subheadline as per your need. This text will be above your excerpt blog.

    #44072
    Josh
    Participant

    Yes, but that solution will not work for me because: 1) I am already using the homepage headline and sub-headlines for other slogan/text, 2) I am hoping for the “feel” and appearance of the static page (below “featured content”) for a more uniform user experience, and 3) the static text I would like add above the blog excerpts includes a video link and is about a paragraph long. Thanks for responding when you are able.

    #44077
    Sakin
    Keymaster

    @jmott310: Sorry this is beyond free support customization and for this you need to hire customizer http://catchthemes.com/hire-customizer/ to work on it

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Static Text Above Blog Posts on Home Page’ is closed to new replies.