Title: Adding slider to header.php
Last modified: August 24, 2016

---

# Adding slider to header.php

 *  [jonnypryer](https://wordpress.org/support/users/jonnypryer/)
 * (@jonnypryer)
 * [11 years ago](https://wordpress.org/support/topic/adding-slider-to-headerphp/)
 * I cannot seem to replicate the solution mentioned in the thread ‘Create a widget
   area below header navigation menu’.
 * I want to add a slider to my clients site as per this site: [http://www.superiordrainservice.com/](http://www.superiordrainservice.com/)
 * My code looks like this:
 * ‘<?php } ?>
    <?php if ( is_home() || is_front_page() ) { ?> <?php if ( get_header_image()!
   = ” ) { ?> <div class=”header-image”><?php if( function_exists(‘cyclone_slider’))
   cyclone_slider(‘home_slider’); ?></div> <?php } ?> <?php } else { ?> <?php if(
   get_header_image() != ” && $brickyard_options_db[‘brickyard_display_header_image’]!
   = ‘Only on Homepage’ ) { ?> <div class=”header-image”><img src=”<?php header_image();?
   >” alt=”<?php bloginfo( ‘name’ ); ?>” /></div> <?php } ?> <?php } ?>’
 * The web address is: [http://www.sailingfuncroatia.co.uk/](http://www.sailingfuncroatia.co.uk/)(
   although there is nothing to look at yet).
 * Any ideas as to what is wrong?
 * Thanks,
 * Jonathan

Viewing 1 replies (of 1 total)

 *  Theme Author [TT Themes](https://wordpress.org/support/users/tomastoman/)
 * (@tomastoman)
 * [11 years ago](https://wordpress.org/support/topic/adding-slider-to-headerphp/#post-6176215)
 * Dear Jonathan,
 * please delete the condition for displaying the header image in your code to make
   it work:
 *     ```
       <?php } ?>
        <?php if ( is_home() || is_front_page() ) { ?>
        <div class="header-image"><?php if( function_exists('cyclone_slider') ) cyclone_slider('home_slider'); ?></div>
        <?php } else { ?>
        <?php if ( get_header_image() != '' && $brickyard_options_db['brickyard_display_header_image'] != 'Only on Homepage' ) { ?>
        <div class="header-image"><img src="<?php header_image(); ?>" alt="<?php bloginfo( 'name' ); ?>" /></div>
        <?php } ?>
        <?php } ?>
       ```
   
 * Best regards,
    Tomas Toman

Viewing 1 replies (of 1 total)

The topic ‘Adding slider to header.php’ is closed to new replies.

 * ![](https://i0.wp.com/themes.svn.wordpress.org/brickyard/2.0.3/screenshot.png)
 * BrickYard
 * [Support Threads](https://wordpress.org/support/theme/brickyard/)
 * [Active Topics](https://wordpress.org/support/theme/brickyard/active/)
 * [Unresolved Topics](https://wordpress.org/support/theme/brickyard/unresolved/)
 * [Reviews](https://wordpress.org/support/theme/brickyard/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [TT Themes](https://wordpress.org/support/users/tomastoman/)
 * Last activity: [11 years ago](https://wordpress.org/support/topic/adding-slider-to-headerphp/#post-6176215)
 * Status: not resolved