Title: Enhanced Simple PHP gallery-errors
Last modified: August 18, 2016

---

# Enhanced Simple PHP gallery-errors

 *  [TH](https://wordpress.org/support/users/th/)
 * (@th)
 * [20 years, 9 months ago](https://wordpress.org/support/topic/enhanced-simple-php-gallery-errors/)
 * I’m trying to put up eSPG here:
    [http://www.pohildre.com/gallery/folder/Galapagos](http://www.pohildre.com/gallery/folder/Galapagos)
 * But there are errors and the photos won’t display at all when clicking on the
   thumbnails. I don’t think it’s theme related because I get the same errors with
   the default theme. Most likely it’s something simple I have done wrong. But I
   don’t understand what it could be.
 * I don’t understand much PHP, but I followed the instructions to the letter, except
   that I had to changemod the cache directories to 777 and not 755 like the instructions
   said. Otherwise the thumbnails wouldn’t display at all.
 * The errors are:
    Warning: readdir(): supplied argument is not a valid Directory
   resource in /root/gallery/sp_helper_functions.php on line 10
 * Warning: Invalid argument supplied for foreach() in /root/gallery/sp_helper_functions.
   php on line 452
 * Has anyone had anything similar? Or perhaps it is obvious to someone smarter 
   than me what this is? Any help would be met with intense happiness!

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

 *  [jwurster](https://wordpress.org/support/users/jwurster/)
 * (@jwurster)
 * [20 years, 9 months ago](https://wordpress.org/support/topic/enhanced-simple-php-gallery-errors/#post-252823)
 * When I installed simplephpgallery, I only modified one file, the sp-config.php.
   What files did you modify, if any?
 *  Thread Starter [TH](https://wordpress.org/support/users/th/)
 * (@th)
 * [20 years, 9 months ago](https://wordpress.org/support/topic/enhanced-simple-php-gallery-errors/#post-252871)
 * Let’s see… Following this tutorial, [http://www.quirm.net/show.php?contentid=11](http://www.quirm.net/show.php?contentid=11)
   
   I modified:
 * * header.php
    * footer.php * sp_styles.css
 * Based on my theme’s header and footer. I don’t think this is where the problem
   lies. I tried using the header, footer and css that came with the gallery (v.
   1.7). That gets rid of these two error messages, but I get parse-errors instead
   and the photos still won’t display. And of course… the unmodified files don’t
   load the theme at all.
 * Also I tried the readymade WP-ready files found here:
    [http://www.quirm.net/show.php?contentid=12](http://www.quirm.net/show.php?contentid=12)
   but with them I get the same original error messages. And of course, they don’t
   load my theme either since they weren’t made for it.
 * I’m more inclined to think that I have done something wrong with permissions 
   or the gallery’s ability to access photos along my path. For some reason or other.
   But I get the same error without using modrewrite. Oh I don’t know what it could
   be. This is so frustrating.
 *  [jwurster](https://wordpress.org/support/users/jwurster/)
 * (@jwurster)
 * [20 years, 9 months ago](https://wordpress.org/support/topic/enhanced-simple-php-gallery-errors/#post-252883)
 * I didn’t even see those tutorials. I downloaded the WP files and put them in 
   a folder in the plugins directory and everything worked out of the box.
 *  Thread Starter [TH](https://wordpress.org/support/users/th/)
 * (@th)
 * [20 years, 9 months ago](https://wordpress.org/support/topic/enhanced-simple-php-gallery-errors/#post-252886)
 * Well, good for you. I, however, have a problem. 🙂
 *  [jwurster](https://wordpress.org/support/users/jwurster/)
 * (@jwurster)
 * [20 years, 9 months ago](https://wordpress.org/support/topic/enhanced-simple-php-gallery-errors/#post-252913)
 * I didn’t mean to be condescending. I apologize. I was just trying to help. I 
   guess I should also have added that if you can back out all the stuff you did
   and go back to the start, you may have success.
 *  [mielec](https://wordpress.org/support/users/mielec/)
 * (@mielec)
 * [20 years, 1 month ago](https://wordpress.org/support/topic/enhanced-simple-php-gallery-errors/#post-253522)
 * Hi
    I´ve used this tutorial @ [http://www.dreden.com/2005/05/22/espg-wp/](http://www.dreden.com/2005/05/22/espg-wp/)
   it worked for me –
 * br Kenneth

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

The topic ‘Enhanced Simple PHP gallery-errors’ is closed to new replies.

 * 6 replies
 * 3 participants
 * Last reply from: [mielec](https://wordpress.org/support/users/mielec/)
 * Last activity: [20 years, 1 month ago](https://wordpress.org/support/topic/enhanced-simple-php-gallery-errors/#post-253522)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
