Putting revolution slider on top of activity feed, clarification

Yes, thank you
i think its working now, but the revolution slider will not show,
i put the code in wp-header.php
The right place for that file is it in: x-child/framework/views/wp-header.php

Or have i place it in the wrong place?

Hi there,

The error is still there, and it because the Revslider plugin is triggering an internal error.

Fatal error: Uncaught Error: [] operator not supported for strings in

I checked and your Revslider version is still 4.6, a bit old compared to the current version which is 5.4. Old versions has problem running in PHP 7, so please delete this plugin through FTP /wp-content/plugins/revslider, then login in your admin and go to X overview page and install the compatible Rev Slider.

Thanks!

Wonderful its works better, but the startpage code not working with a slider above the posts. I will check the forum its have been working before when i try on my workingtestsite.

Best regards

I Love you all on the support, great work all the time!

You’re most welcome!
We’re glad we were able to help you out.

Hello again, my first problem with putting revolutionslider, or a picture above the post activity feed, where can i put in the script and do you have the right script to me?

I have this one:

<?php

// =============================================================================
// FUNCTIONS.PHP
// -----------------------------------------------------------------------------
// Overwrite or add your own custom functions to X in this file.
// =============================================================================

// =============================================================================
// TABLE OF CONTENTS
// -----------------------------------------------------------------------------
//   01. Enqueue Parent Stylesheet
//   02. Additional Functions
// =============================================================================

// Enqueue Parent Stylesheet
// =============================================================================

add_filter( 'x_enqueue_parent_stylesheet', '__return_true' );

function add_custom_div() {   
if(is_home()):
?>

/*Html text inlägg*/
<img src="http://www.modernamobelklassiker.com/wp-content/uploads/samling-180401.jpg" alt="" width="2223" height="1103" class="alignnone size-full wp-image-35" />

<?php
endif;
}

// Additional Functions
// =============================================================================

And i got one another with shortcode to usa a slider revolution at the startpage:

<?php

// =============================================================================
// VIEWS/INTEGRITY/WP-HEADER.PHP
// -----------------------------------------------------------------------------
// Header output for Integrity.
// =============================================================================

?>

<?php x_get_view( 'global', '_header' ); ?>

  <!--
  BEGIN #top.site
  -->

  <div id="top" class="site">

    <?php x_get_view( 'integrity', 'global-alert' ); ?>
    <?php x_get_view( 'global', '_slider-revolution-above' ); ?>

      <header class="masthead" 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-revolution-below' ); ?>
      
      [rev_slider startsida]
      

      <?php x_get_view( 'integrity', '_landmark-header' ); ?>

I have try both and its not working, what can i do?

Hi olahollsten,

I can’t connect to your website via FTP details you shared earlier to investigate why the child theme wp-header.php isn’t working. Could you please double check that the FTP login details are working fine?

Thanks.

I can send it again, its working for me

Its the right login info i sent before.

Hi there,

Both of the code will not work, the first one is a function, but it’s never called or executed. Where do you wish to render that image? So we could think of proper where you can attach that function.

The second code will not work since it’s just a shortcode. You should change it to this

<?php

// =============================================================================
// VIEWS/INTEGRITY/WP-HEADER.PHP
// -----------------------------------------------------------------------------
// Header output for Integrity.
// =============================================================================

?>

<?php x_get_view( 'global', '_header' ); ?>

  <!--
  BEGIN #top.site
  -->

  <div id="top" class="site">

    <?php x_get_view( 'integrity', 'global-alert' ); ?>
    <?php x_get_view( 'global', '_slider-revolution-above' ); ?>

      <header class="masthead" 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-revolution-below' ); ?>
      
      <?php echo do_shortcode('[rev_slider startsida]'); ?>

      <?php x_get_view( 'integrity', '_landmark-header' ); ?>

Then you should place it in \x-child\framework\legacy\cranium\headers\views\integrity\ folder.

Hope this helps.

Thank you,
but is this the right place i use a Child?
I try but nothing happends.

Now it working, but tha same problem as before, the logo and menu is placed not center: http://www.modernamobelklassiker.com/
Can you fix that?

Hi there,

Please add this CSS to your global custom CSS

.x-brand {
float: none;
}
.x-navbar .desktop .x-nav>li {
    float: none;
    display: inline-block;
}

Cheers!

Yes the logo get centered but not the menu…

Hey @olahollsten,

Use this CSS to center the menu.

.x-navbar {
    text-align: center;
}

Hope that helps.

1 Like

Peace, Love And Understanding

How can i get no slider on single post?

Hey There,

How can i get no slider on single post?

Please update this line:
<?php echo do_shortcode('[rev_slider startsida]'); ?>

And replace it with this lines:

<?php if ( !is_single()  ) : ?>
   <?php echo do_shortcode('[rev_slider startsida]'); ?>
<?php endif; ?>

We would loved to know if this has work for you. Thank you.

Now everything works absolut perfekt!
Thank you all

You’re welcome.