This topic has 20 replies, 3 voices, and was last updated 6 years by Radu.

  • Author
  • #178202
     gm713
    Participant

    Hi

    Is there a way to display a full-width header in a 2 column page. See attached image.

    Attachments:
    You must be logged in to view attached files.
    #178205
     Kieran_SQ
    Moderator

    Hi,

    If you mean single posts then you can follow this article https://archived.seventhqueen.com/kleo/article/show-featured-image-full-width-content-area.

    If it is for singular page please provide me with more information such as page name, page ID, please let me know whether this will be shortcode or HTML based and I should be able to provide you with code that works for you.

    Kieran.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    If you like the theme or the support you've received please consider leaving us a review on Themeforest!

    Custom development requests can be sent to dev@seventhqueen.com, one of the development team will be happy to discuss your needs.

    #179031
     gm713
    Participant

    Thanks. I want to add it to page (and not post). Not sure if it makes a difference or not?

    Essentially there are several pages, that utilize a right-sidebar format. I want to be able to display the header above the page content, in a manner pretty much displayed in your example post.

    The only difference would be that my header would be set to transparent. I think the solution you provided would still work, correct?

    Currently it’s not working for me, so not sure what’s going wrong? I’ve set a featured image (See attached)

    Attachments:
    You must be logged in to view attached files.
    #179034
     gm713
    Participant
    This reply has been set as private.
    #179081
     Kieran_SQ
    Moderator

    Hi,

    For pages please try this snippet instead of the one above as that is for posts

    COPY CODE
    add_action('kleo_before_main', 'sq7rdu_show_featured_before_content');
    function sq7rdu_show_featured_before_content() {
        if (is_page()) {
            if (has_post_thumbnail()) {
                echo '<div class="fullwidth-image-before-content">';
                echo the_post_thumbnail('full');
                echo '</div>';
            }
        }
    }

    Kieran

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    If you like the theme or the support you've received please consider leaving us a review on Themeforest!

    Custom development requests can be sent to dev@seventhqueen.com, one of the development team will be happy to discuss your needs.

    #179121
     gm713
    Participant

    Hi. This didn’t work unfortunately.

    #179167
     Kieran_SQ
    Moderator

    Hi,

    I will ask one of our developers to look into this for you, they’ll be in touch as soon as they can (Mon-Fri East Europe Time).

    Thank you for your patience,

    Kieran.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    If you like the theme or the support you've received please consider leaving us a review on Themeforest!

    Custom development requests can be sent to dev@seventhqueen.com, one of the development team will be happy to discuss your needs.

    #179259
     Radu
    Moderator

    Hi,

    If the discussion it’s a page that can be edited in admin just add in header content

    COPY CODE
    
    <img class="my-custom-image" src="http://domain.com/image.jpg">
    

    Cheers
    R.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #179305
     gm713
    Participant

    Hi Radu,

    Thanks for the solution. That worked.

    #179362
     Radu
    Moderator

    Great

    Cheers
    R.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #179568
     gm713
    Participant
    This reply has been set as private.
    #179751
     Radu
    Moderator

    Hi,

    The function needs to be pasted in wp-content/themes/buddyapp-child/functions.php

    COPY CODE
    
    function render_before_content_in_bbpress() {
        if (class_exists('bbpress')) {
            if (is_bbpress()) {
                echo '<img src="http://www.ricoh-imaging.co.jp/english/products/q-s1/ex/img/bod_mainImg_01.jpg">';
            }
        }
    }
    
    add_action('kleo_before_content','render_before_content_in_bbpress');
    
    

    NOTE : Child theme needs to be installed and activated.

    Replace image source with your desired one.

    Cheers
    R.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #181797
     gm713
    Participant
    This reply has been set as private.
    #181920
     Radu
    Moderator

    I see in this case please ask the plugin developer about a hook before the plugin starts to render to can render your desired banner in that view.

    Then instead of kleo_before_content from this context

    add_action(‘kleo_before_content’,’render_before_content_in_bbpress’);

    Will be the name of the hook that belongs to the plugin.

    Cheers
    R.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #182627
     gm713
    Participant

    Hi Radu,

    The developer said that the plugin inherits the page template, so I should change the “default template” to a custom template in page attributes.

    I think if I create a custom template which shows this header (image), and then simply include the plugin short code on it to render the questions, it would work fine.

    Can you point me to how do I create a custom template (lets call it “discussions_template” and the code that I need to include in the functions.php file to always have that header render, before the content, whenever I use this template.

    #182704
     Radu
    Moderator

    Hi,

    If you want to create e custom page template you will have to create a file named : custom-page-template.php
    in this path : /wp-content/themes/kleo-child/page-templates/custom-page-template.php

    in that you will have to paste : https://pastebin.com/raw/3T8wtcyU

    NOTE : Child theme needs to be installed and activated.

    If the folders aren’t created in child theme create them.

    Then from page template set your desired template,

    If you need to modify the template you can do it safe in child theme.

    Cheers
    R.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #182746
     gm713
    Participant

    Thanks. I created the template. 2 follow up questions:

    1. How do I include a header image so it appears on all pages that are created using this template? It should start to render from top of the page, even before the top menu.

    2. In the php file, is there anything I need to do for this comment?

    /*
    * Include the post format-specific template for the content. If you want to
    * use this in a child theme, then include a file called called content-___.php
    * (where ___ is the post format) and that will be used instead.
    */

    #182748
     gm713
    Participant

    A couple more needs actually:

    1. Need a right sidebar similar to right sidebar page template
    2. Need header to be set transparent

    #182796
     Radu
    Moderator

    Hi,
    Just replace that file content with this one: https://pastebin.com/raw/ZYAJNkkw

    Then select from wp-admin -> pages -> your desired header style for that page that has set that template

    Image can be added first by adding img src before first line

    Cheers
    R.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #182825
     gm713
    Participant

    Hi,

    I have the presferred header selected. I need to set it to transparent but the checkbox at page settings doesn’t work.

    Can the code itself make the header and top bar transparent so it’s applied globally to all pages using this template, without having to set it at an individual page basis.

    Thanks much!

    #182898
     Radu
    Moderator

    Hi,

    TO can have main menu transparent how the option do that add the next line in place where it’s show in screenshot immediately after https://pastebin.com/raw/4CCGYm3i

    Cheers
    R.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Ticket solution
Viewing 21 posts - 1 through 21 (of 21 total)

The forum ‘General questions’ is closed to new topics and replies.

Log in with your credentials

Forgot your details?