Tagged: x
-
AuthorPosts
-
May 30, 2016 at 4:43 am #1016233
belayachimarouaneParticipantHello,
I have searched the forum but there is no solution to what I am trying to do.
I want to add a search bar next to the logo in the stacked option. What I intend to do is to align the logo to the left and search bar to the right, like in the image I have attached to this thread.
any directions on how to achieve this ? Thanks a lot.
May 30, 2016 at 4:43 am #1016235
belayachimarouaneParticipantThis reply has been marked as private.May 30, 2016 at 5:09 am #1016257
ThaiModeratorThis reply has been marked as private.May 30, 2016 at 5:19 am #1016268
belayachimarouaneParticipantThis reply has been marked as private.May 30, 2016 at 5:48 am #1016309
Paul RModeratorHi,
Thank you for providing your login credentials.
To achieve that, create file _brand.php in wp-content/themes/x-child/framework/views/global and copy the code below into that file.
<?php // ============================================================================= // VIEWS/GLOBAL/_BRAND.PHP // ----------------------------------------------------------------------------- // Outputs the brand. // ============================================================================= $site_name = get_bloginfo( 'name' ); $site_description = get_bloginfo( 'description' ); $logo = x_make_protocol_relative( x_get_option( 'x_logo' ) ); $site_logo = '<img src="' . $logo . '" alt="' . $site_description . '">'; ?> <?php echo ( is_front_page() ) ? '<h1 class="visually-hidden">' . $site_name . '</h1>' : ''; ?> <a href="<?php echo home_url( '/' ); ?>" class="<?php x_brand_class(); ?>" title="<?php echo $site_description; ?>"> <?php echo ( $logo == '' ) ? $site_name : $site_logo; ?> </a> <div class="search-bar"> <?php get_search_form(); ?> </div>After that, add this in Appearance > Customize > Custom > Edit Global CSS
.search-bar { max-width: 300px; float: right; } .x-logobar { text-align:left; margin-top:28px; }Hope that helps.
May 30, 2016 at 10:23 am #1016638
belayachimarouaneParticipantHello,
I have tried all these; but no success. I can’t see the search bar.
Thanks a lot
May 30, 2016 at 11:08 am #1016679
JadeModeratorHi there,
Thanks for writing back. I have tested the code provided previously and it seems to be working fine.
Kindly make sure that you login through FTP and add the _brand.php with the code above to wp-content/themes/x-child/framework/views/global.
If you have done it but the search bar is still not visible, kindly provide us with your FTP details so that we could check why it is not working on your setup.
Thank you.
May 30, 2016 at 11:15 am #1016695
belayachimarouaneParticipantThis reply has been marked as private.May 30, 2016 at 12:39 pm #1016809
JadeModeratorHi there,
There seems to be a problem when you created the file. I have added the correct one and when you check you site, the search bar should be visible by now. Kindly double check.
Thank you.
May 30, 2016 at 1:33 pm #1016872
belayachimarouaneParticipantThats great thanks a lot!
May 30, 2016 at 2:27 pm #1016934
JadeModeratorYou’re most welcome.
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1016233 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
