Title: Carousel Shadow
Last modified: August 22, 2016

---

# Carousel Shadow

 *  [russinternational](https://wordpress.org/support/users/russinternational/)
 * (@russinternational)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/carousel-shadow/)
 * Hello,
 * Apologies, I’ve ended up with another issue..
 * I have used some code to enable my slider carousel to link to the page by clicking
   the picture – but in doing so, the shadow around the slider is now too big – 
   despite being fine before. Obviously I could make the image longer, but I am 
   trying to avoid that..
 * Currently using this code;
 *     ```
       .carousel-inner {
       top:20px;
       box-shadow: 0px 0px 5px 2px #000000;
   
       }
       ```
   
 * and (in functions.php)
 *     ```
       add_action('wp_head' , 'link_whole_slide');
       function link_whole_slide() {
          //sets the slider image link
          add_filter('tc_slide_background' , 'my_slide_link', 10, 3);
           function my_slide_link( $slide_image , $slide_link, $attachment_id) {
               //sets the slider image link
               return sprintf('<a href="%1$s" title="%2$s">%3$s</a>',
                   $slide_link,
                   get_the_title($attachment_id), //will use the title of the picture on mouse hovering
                   $slide_image
               );
           }
           //wraps the slider caption in the same link as the call to action button
           ?>
           <script type="text/javascript">
               jQuery(document).ready(function () {
                   ! function ($) {
                       //prevents js conflicts
                       "use strict";
   
                       $( '.carousel-caption' ).each(function( index ) {
                         var link = $( this ).parent().find('a').attr('href');
                         $(this).wrap('<a href="'+link+'"></a>');
                       });
                   }(window.jQuery)
               });
           </script>
           <?php
       }
       ```
   
 * Thanks again, and Merry Christmas.
 * P.S. website is russinternational.org

Viewing 1 replies (of 1 total)

 *  [Rocco Aliberti](https://wordpress.org/support/users/d4z_c0nf/)
 * (@d4z_c0nf)
 * [11 years, 4 months ago](https://wordpress.org/support/topic/carousel-shadow/#post-5609432)
 * This is because using that code the centering slides feature doesn’t work anymore(
   I will propose a pull request to nikeo to avoid this issue), and your height’s
   images is 500px while you set a custom slider height of 525px.
    For now, if you
   wanna use a custom slider height I also suggest to change the image size: [http://themesandco.com/snippet/changing-default-image-sizes-customizr/](http://themesandco.com/snippet/changing-default-image-sizes-customizr/)
   But this would not be enough, you might experience the problem for smaller viewports.

Viewing 1 replies (of 1 total)

The topic ‘Carousel Shadow’ is closed to new replies.

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

 * 1 reply
 * 2 participants
 * Last reply from: [Rocco Aliberti](https://wordpress.org/support/users/d4z_c0nf/)
 * Last activity: [11 years, 4 months ago](https://wordpress.org/support/topic/carousel-shadow/#post-5609432)
 * Status: not resolved