Title: editing gallery space with function.php
Last modified: August 22, 2016

---

# editing gallery space with function.php

 *  Resolved [trailboundco](https://wordpress.org/support/users/trailboundco/)
 * (@trailboundco)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/editing-gallery-space-with-functionphp/)
 * Was reading on the aesop site about how to [add space between gallery images](http://aesopstoryengine.com/tutorials/using-aesop-filters/)
   and this is exactly what i’ve been looking to do however it’s not working for
   me.
 * I have the function.php setup in a child theme with this code
 *     ```
       <?php 
   
       add_filter("aesop_grid_gallery_space", "myGallerySpace");
       function myGallerySpace(){
           return 60;
       }
   
       ?>
       ```
   
 * Is this correct, should the function.php be setup in the plugin folder?
    Is there
   any other way around this like adding a margin via css?
 * thank you,
    -chris
 * [https://wordpress.org/plugins/aesop-story-engine/](https://wordpress.org/plugins/aesop-story-engine/)

Viewing 6 replies - 1 through 6 (of 6 total)

 *  Plugin Author [Michael Beil](https://wordpress.org/support/users/michaelbeil/)
 * (@michaelbeil)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/editing-gallery-space-with-functionphp/#post-5432355)
 * [@trailboundco](https://wordpress.org/support/users/trailboundco/),
 * It looks like there was a slight discrepancy in our docs. It should look like
   this:
 *     ```
       add_filter ( "aesop_grid_gallery_spacing", "myGallerySpace" );
       function myGallerySpace(){
           return 60;
       }
       ```
   
 * We recommend adding this snippet to the Code Snippets plugin: [https://wordpress.org/plugins/code-snippets/](https://wordpress.org/plugins/code-snippets/)
 * Let us know if that helps.
 *  Thread Starter [trailboundco](https://wordpress.org/support/users/trailboundco/)
 * (@trailboundco)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/editing-gallery-space-with-functionphp/#post-5432483)
 * Perfect, thank you.
 * If I was trying to stop the hiding of the arrows and the x within the lightbox
   would I write this in function.php as well?
 *  Plugin Author [Michael Beil](https://wordpress.org/support/users/michaelbeil/)
 * (@michaelbeil)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/editing-gallery-space-with-functionphp/#post-5432510)
 * Hey [@trailboundco](https://wordpress.org/support/users/trailboundco/),
 * ASE doesn’t have a functions.php file.
 * Can I ask why you would want to hide the arrows and the x within the lightbox?
   Doing so might make for a difficult user experience.
 *  Thread Starter [trailboundco](https://wordpress.org/support/users/trailboundco/)
 * (@trailboundco)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/editing-gallery-space-with-functionphp/#post-5432534)
 * Sorry I meant hide the file name at the top and stop the hiding of the arrows
   and x. Right now they go away after a few seconds and only return if you click
   on the image i believe. This UX is annoying, could see it being improved if you
   hovered over the bottom area and getting the arrows back but this isn’t the case.
   Making them present at all times seems easiest.
 *  Plugin Author [Michael Beil](https://wordpress.org/support/users/michaelbeil/)
 * (@michaelbeil)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/editing-gallery-space-with-functionphp/#post-5432537)
 * Would you resubmit the lightbox issue as a separate thread here since we are 
   dealing with a different issue than what we started with? Thanks!
 *  Thread Starter [trailboundco](https://wordpress.org/support/users/trailboundco/)
 * (@trailboundco)
 * [11 years, 7 months ago](https://wordpress.org/support/topic/editing-gallery-space-with-functionphp/#post-5432541)
 * Yeah no problem
    thanks

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘editing gallery space with function.php’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/aesop-story-engine_252422.svg)
 * [Aesop Story Engine](https://wordpress.org/plugins/aesop-story-engine/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/aesop-story-engine/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/aesop-story-engine/)
 * [Active Topics](https://wordpress.org/support/plugin/aesop-story-engine/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/aesop-story-engine/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/aesop-story-engine/reviews/)

## Tags

 * [function](https://wordpress.org/support/topic-tag/function/)
 * [gallery](https://wordpress.org/support/topic-tag/gallery/)
 * [space](https://wordpress.org/support/topic-tag/space/)

 * 6 replies
 * 2 participants
 * Last reply from: [trailboundco](https://wordpress.org/support/users/trailboundco/)
 * Last activity: [11 years, 7 months ago](https://wordpress.org/support/topic/editing-gallery-space-with-functionphp/#post-5432541)
 * Status: resolved