Title: php load function not working
Last modified: August 19, 2016

---

# php load function not working

 *  [matheyrichs](https://wordpress.org/support/users/matheyrichs/)
 * (@matheyrichs)
 * [16 years, 3 months ago](https://wordpress.org/support/topic/php-load-function-not-working/)
 * Hi,
 * I’m using a code snipet that creates a spinning album of photos from a picasa
   web album RSS feed. Up until recently I was just using 1 album, which is really
   simple and straightforward. However, I thought it would be really cool to write
   a php script that would randomly display one album from all of a specific Picasa
   user’s albums.
 * Shouldn’t be too tricky, right?
 * I got this to work on my local deployment of wordpress using the following code(
   separate php file, randomImageGallery.php):
 * _[Code moderated as per the [Forum Rules](http://wordpress.org/support/topic/68664).
   Please use the [pastebin](http://wordpress.pastebin.ca/)]_
 * I then just used an include for this file on my index.php and had no problems
   whatsoever.
 * Here’s the kicker: I tried uploading this as a brand new theme, tried editing
   the old theme through the wordpress editor, tried FTPing index.php and randomImageGenerator.
   php to my site online. Nothing worked. I thought maybe this was because my server
   was set up with php 4.4.9 by default, but I just upgraded to 5.2.12 and there’s
   no difference. No matter what I do, nothing in my index.php file after the include
   line for randomImageGenerator.php shows up. Oh I also tried putting everything
   inline in index.php and that didn’t work either.
 * I tried removing the main block of php (first php tag in the code above) and 
   the rest of my code below showed up. So I went line-by-line adding a single line
   of php back in at a time, and everything was fine until I hit:
 * `$xmlDoc->load($xml);`
 * Deleting this line alone does not solve the problem, and I’m really not sure 
   at this point what could be going wrong. Can anyone help me out? Thanks in advance!

The topic ‘php load function not working’ is closed to new replies.

## Tags

 * [load](https://wordpress.org/support/topic-tag/load/)
 * [photo album](https://wordpress.org/support/topic-tag/photo-album/)
 * [php](https://wordpress.org/support/topic-tag/php/)
 * [xml](https://wordpress.org/support/topic-tag/xml/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 0 replies
 * 1 participant
 * Last reply from: [matheyrichs](https://wordpress.org/support/users/matheyrichs/)
 * Last activity: [16 years, 3 months ago](https://wordpress.org/support/topic/php-load-function-not-working/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
