Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #570825

    on a different installation i did this here on child-theme functions.php:

    add_filter('avf_header_setting_filter', function($header) {
    	if ( is_search() ) {
    		$header['header_transparency'] = 'header_transparency';
    		$header['header_class'] .= " av_header_transparency";
    	}
    	return $header;
    }, 10, 1);

    so i can get the same header outlook on the search results page.

    i put in some code to have the same starting content as on my other sites:

    add_action('ava_after_main_title', function() {
    if ( is_search() ) {
    	?>
    "content from debug-mode or webdeveloper tools"
    <?php
    }
    });

    but now i have the problem with a different installation – on that i got some glassy headers

    so the class to add is now :

    $header['header_class'] .= " av_header_transparency av_header_glassy";

    but i don’t know what to do with the line before the class definition

    • This topic was modified 8 years, 10 months ago by Guenni007.
    #571945

    Hey Guenter!

    Thank you for using Enfold.

    I’m sorry but I’m not sure if I understand the issue here. Could you please provide a screenshot or a link to the actual page with the issue?

    Best regards,
    Ismael

    #572237

    well ismael we discussed it here allready for a transparent header: https://kriesi.at/support/topic/styling-single-events-page/

    i want to style the searchresults page similar to the other sites on a specific installation with enfold.
    On that case link above i styled the other pages with transparency header and so i want a transparency header with a banner or something else.

    Now the other pages got glassy headers

    it seems to be solved by :

    add_filter('avf_header_setting_filter', function($header) {
    	if ( is_search() ) {
    		$header['header_transparency'] = 'header_transparency';
    		$header['header_class'] .= " av_header_transparency av_header_glassy";
    	}
    	return $header;
    }, 10, 1);

    but i guess that the line
    $header['header_transparency'] = 'header_transparency';
    has to be a little different becaus html gets a class too.

    #572699

    Hey!

    Oh ok. I’m sorry I forgot about the thread. Anyway, the “html_header_transparency” is intended to be applied in the html tag if you set a specific page to transparent header. The “av_header_transparency av_header_glassy” is going to be applied to the header tag. If you don’t want the glassy header, just remove the “av_header_glassy” selector.

    Cheers!
    Ismael

    #572802

    i want the glassy header here!

    but is the line: $header['header_transparency'] = 'header_transparency'; correct or is there something missing?

    • This reply was modified 8 years, 10 months ago by Guenni007.
    #573484

    Hey!

    the html does not have the class: “html_header_glassy” only the “html_header_glassy” is there
    so i thing the line mentioned above has to be a little bit different

    The pages above including the search page are already set to glassy header. You can check that by looking at the header_bg container. You should see this css style:

    #top .av_header_glassy.av_header_transparency .header_bg {
        background-color: #fff;
        opacity: 0.1;
        filter: alpha(opacity=10);
    }

    If it is only set to transparent header, the style would be:

    #top .av_header_transparency .header_bg {
        background-color: transparent;
        opacity: 0;
        filter: alpha(opacity=0);
    }

    Regards,
    Ismael

    #573670

    yes i know that it looks the way i want it but the other pages (see private content) hava a class on the html:
    <html class=" ...... html_header_transparency html_header_glassy .... >

    this is missing on search results page !

    • This reply was modified 8 years, 10 months ago by Guenni007.
    #574337

    Hey!

    Alright. You can adjust the code to something like this:

    add_filter('avf_header_setting_filter', function($header) {
    	if ( is_search() ) {
    		$header['header_transparency'] = 'header_transparency header_glassy';
    		$header['header_class'] .= " av_header_transparency av_header_glassy";
    	}
    	return $header;
    }, 10, 1);

    Best regards,
    Ismael

    #574355

    can be closed than – Thanks
    it is just a cosmetic request – but now it is right!

Viewing 9 posts - 1 through 9 (of 9 total)
  • The topic ‘glassy Header on search sites’ is closed to new replies.