Navigation
This is archived content. Visit our new forum.

Tagged: 

  • Author
    Posts
  • #1175500
    Rad
    Moderator

    Hi there

    1. Yes, you have to hide the original search button. It holds the main functionality, and the purpose of a proxy button is to trigger that functional from another existing button, which is the search in navigation.

    2. Yes, please change the existing code instead of adding new one.

    Thanks!

    #1175665
    necxelos
    Participant

    2.a) How this query:

    jQuery('.search-button-proxy').on('click', function() {
    jQuery('#menu-item-id-here-where-search-is').click();
    } );

    …need to look like if I wanted to put it in functions.php instead of customizer?
    2.b) and 2.c) Paul said I can’t hide original button, and You (Rad) are saying I have to do it… I’m lost here, which one is it? And how?

    4. Yes I’m using existing one (‘entry’) in setup.php (precisely Your [Rad’s] version that outsources setup.php code to functions.php). This part works. What doesn’t seem to work for me is code from Paul, that should make blog/archive/search pages use ‘entry’ images instead of ‘full’ images.

    Thanks again
    Have a good night πŸ™‚

    #1176190
    Rad
    Moderator

    Hi there,

    2.a. Should be like this πŸ™‚

    add_action('wp_footer', 'custom_js_footer');
    function custom_js_footer () { ?><script type="text/javascript">
    
    jQuery('.search-button-proxy').on('click', function() {
    jQuery('.x-btn-navbar-search').click();
    } );
    
    </script>
    
    <style>
    .x-menu-item-search { display: none; }
    </style>
    
    <?php }

    That also include the CSS that will hide your navbar’s menu search.

    4. What do you mean? Is there any issue with ‘entry’ size? It isn’t there?

    Thanks!

    #1177614
    necxelos
    Participant

    2.a) That totally worked thank You πŸ™‚

    Out of pure curiosity: why did it work? When I used previous code (from customizer) AND THEN added display: none it didn’t work… Magic? πŸ˜€

    4. Ok, let’s take a step back a bit, because by talking to several people here this I made this question look a little messy (and it was supposed to be just a simple change). So long story short:
    – Clean installation, nothing custom in place.
    – Post Featured Image.
    – X Theme automatically creates 4 image sizes of it’s own as defined in setup.php. One of them is ‘entry’.
    – Ethos Stack doesn’t use any of those in blog/archive/search pages, it uses original uploaded image instead. But in single post page Ethos Stack uses ‘entry’ image (at least I think so, judging by image filename which has dimensions in it, which original image don’t).
    – Paul gave me code in post #1172541, which was supposed to allow me to force Ethos to use ‘entry’ (or any other) size on blog/archive/search pages instead of original size.
    – And it didn’t work.

    #1177782
    Rad
    Moderator

    Hi there,

    2.a There might be malformed styling within your customizer. Like not properly added an open and close bracket or broken comment lines.

    4. Hmm, it might need direct checking this time. It can’t be check but just looking on the front.

    Thanks!

    #1178565
    necxelos
    Participant

    I’ll get back to this once beta version of my site goes live then – Thanks πŸ™‚

    #1178770
    Jade
    Moderator

    You’re most welcome.

  • <script> jQuery(function($){ $("#no-reply-1165348 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>