Title: Share your code snippets
Last modified: August 21, 2016

---

# Share your code snippets

 *  Plugin Author [MatthewRuddy](https://wordpress.org/support/users/matthewruddy/)
 * (@matthewruddy)
 * [12 years, 11 months ago](https://wordpress.org/support/topic/code-snippets-1/)
 * As Easing Slider contains many JS and PHP functions that users can hook into 
   when creating their own additional functionality, I’ve decided to make a topic
   where users can share their code snippets.
 * Here are two I find users asking for quite often. Add these to your theme’s `
   header.php` file before the `</head>`. You can also add these to your own Javascript
   files, or even into your `footer.php` file before the `</body>`.
 * **Pause slideshow on hover**
 *     ```
       <script type="text/javascript">
       jQuery(document).ready(function($) {
           $('.easingsliderlite').on('mouseenter', function() {
               $('.easingsliderlite').data('easingsliderlite').startPlayback();
           });
           $('.easingsliderlite').on('click', function() {
               $('.easingsliderlite').data('easingsliderlite').endPlayback();
           });
       });
       </script>
       ```
   
 * **End automatic playback after all slides have been shown**
 *     ```
       <script type="text/javascript">
           jQuery(document).ready(function($) {
               var inc = 0;
               $('.easingsliderlite').data('easingsliderlite').$el.on('nextslide', function() {
                   inc++;
                   if (inc == $('.easingsliderlite').data('easingsliderlite').count) {
                        $('.easingsliderlite').data('easingsliderlite').endPlayback();
                   }
               });
           });
       </script>
       ```
   
 * Feel free to share your own 🙂
 * [http://wordpress.org/extend/plugins/easing-slider/](http://wordpress.org/extend/plugins/easing-slider/)

Viewing 1 replies (of 1 total)

 *  [mward1008](https://wordpress.org/support/users/mward1008/)
 * (@mward1008)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/code-snippets-1/#post-3858266)
 * Hi All
 * I had difficulty with a white-space surrounding the slides on my girlfriends 
   website:
 * [http://www.chilidesign.co.uk/](http://www.chilidesign.co.uk/)
 * I was able to address this using:
 *     ```
       <div align="center" class="" style="background-color: #77c6c5; background-position-x: 46%;">
       <?php if ( function_exists( "easingsliderlite" ) ) { easingsliderlite(); } ?>
       </div>
       ```
   
 * In _template-front.php_.
 * Hope useful.
 * Mike

Viewing 1 replies (of 1 total)

The topic ‘Share your code snippets’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/easing-slider_262626.svg)
 * [Easing Slider](https://wordpress.org/plugins/easing-slider/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/easing-slider/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/easing-slider/)
 * [Active Topics](https://wordpress.org/support/plugin/easing-slider/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/easing-slider/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/easing-slider/reviews/)

## Tags

 * [code](https://wordpress.org/support/topic-tag/code/)
 * [snippet](https://wordpress.org/support/topic-tag/snippet/)

 * 1 reply
 * 2 participants
 * Last reply from: [mward1008](https://wordpress.org/support/users/mward1008/)
 * Last activity: [12 years, 7 months ago](https://wordpress.org/support/topic/code-snippets-1/#post-3858266)
 * Status: not a support question