Tagged: x
-
AuthorPosts
-
May 25, 2016 at 7:21 am #1008931
How do I add a Revolution slider short code into the header of the XTheme? I have tried to achieve this through the customize, header section using a widget but nothing appears? Could you please solve this for me?
Thanks.
May 25, 2016 at 8:06 am #1008992Hi There,
You can have your Revolution Slider set up above the Masthead (Above the header) by clicking Edit Page and activating the slider above the masthead.
If that is not your goal,
please kindly explain what you are trying to achieve.
Thanks,
Joao
May 25, 2016 at 8:15 am #1009011Hi Joao,
Thank you for the speedy response. Is there anyway that I could incorporate this idea to all pages at once? As I have over 45 pages?
Thanks
May 25, 2016 at 9:08 am #1009091Hi there,
Because this requires a template change, I’d advise that you setup a child theme. This allows you to make code changes that won’t be overwritten when an X update is released. After your child theme is setup, please review how we recommend making template changes in Customization Best Practices.
Copy wp-header.php from framework/views/STACK and put it in the same path inside child theme, place this code :
<?php if ( is_page( ) ) :?> <?php echo do_shortcode('[rev_slider agency-home]'); // change the shortcode here ?> <?php else : ?> <?php x_get_view( 'global', '_slider-above' ); ?> <?php endif; ?>
instead of this line :
<?php x_get_view( 'global', '_slider-above' ); ?>
For example if you’re using integrity the final code would be :
<?php // ============================================================================= // VIEWS/INTEGRITY/WP-HEADER.PHP // ----------------------------------------------------------------------------- // Header output for Integrity. // ============================================================================= ?> <?php x_get_view( 'global', '_header' ); ?> <?php if ( is_page( ) ) :?> <?php echo do_shortcode('[rev_slider agency-home]'); // change slider alias here ?> <?php else : ?> <?php x_get_view( 'global', '_slider-above' ); ?> <?php endif; ?> <header class="<?php x_masthead_class(); ?>" role="banner"> <?php x_get_view( 'global', '_topbar' ); ?> <?php x_get_view( 'global', '_navbar' ); ?> <?php x_get_view( 'integrity', '_breadcrumbs' ); ?> </header> <?php x_get_view( 'global', '_slider-below' ); ?> <?php x_get_view( 'integrity', '_landmark-header' ); ?>
Hope it helps.
May 25, 2016 at 9:40 am #1009136That is great thank you very much!
Just one more question before I take all your time, you will see on my website home page there are three boxes at the bottom, one states ‘Welcome to ESQ Recruiting’, the other ‘Why Choose ESQ Recruiting’ and ‘In-House Insider Blog’. These boxes appear to be leveled out on google chrome but on explorer and Mozilla Fox the boxes appear uneven, why is this and how do I resolve this issue? Thanks
Charlie.
May 25, 2016 at 9:40 am #1009137This the site http://esquirerecruiting.com
May 25, 2016 at 9:58 am #1009181Hey there,
They look just fine on my Firefox browser.
Would you mind clearing your browser cache or a hard reset and try again?
Thanks
May 25, 2016 at 10:29 am #1009235Sorry I meant the bottom of the boxes.
Regards
CharlieMay 25, 2016 at 11:23 am #1009342Hey there,
Please add the following code into custom Javascript area :
jQuery(document).ready(function($) { var max = 0; $(".x-section .x-column").each(function(index, el) { if( $(this).height() > max ){ max = $(this).height(); } }); $(".x-section .x-column").css('height', max); });
Hope that helps.
Thanks
May 26, 2016 at 2:49 am #1010614What does this mean and how do I resovle the issue?
Parse error: syntax error, unexpected ‘else’ (T_ELSE) in /home/esquirerecruitin/public_html/wp-content/themes/child-theme-esq/functions.php on line 18
Thanks
May 26, 2016 at 2:58 am #1010621Hi there,
Thanks for updating. Did you add any other code to your Child Theme’s functions.php? Could you share the whole code from the file here so that we can have a look? You can grab the code by login with FTP.
Cheers!
May 26, 2016 at 3:03 am #1010628Hi Rupok,
Yes I added the
<?php if ( is_page( ) ) :?>
<?php echo do_shortcode(‘[rev_slider agency-home]’); // change the shortcode here ?>
<?php else : ?><?php x_get_view( ‘global’, ‘_slider-above’ ); ?>
<?php endif; ?>
with the correct shoortcode into the Child Theme: Theme Functions (functions.php)
but it came as an error?
May 26, 2016 at 3:36 am #1010659Hi There,
That code is meant to be place in wp-header.php on wp-content/themes/x-child/framework/views/STACK.
Please double check the instructions here:https://community.theme.co/forums/topic/how-do-i-add-a-revolution-slider-short-code-into-the-header-of-the-xtheme/#post-1009091Hope this helps.
-
AuthorPosts