ERROR: requested index [51] out of bounds [50]
Fatal error: Call to a member function on a non-object in /home/simsadmi/public_html/modules/gallery/classes/Album.php on line 1113
I just made new Album,and the block-NG-RandomPhoto.php start to get this error sometimes...
ANY HELP?
I see many people got this problem,but i cannot find cure & answers about it...
Thanks!!!
Posts: 2322
Your cache is out of date because people have deleted images.
Either:
Delete the random-block.cache file from your albums directory
Wait 24 hours for the cache to rebuild itself
Re-run the config wizard and specify a shorter cache value
Posts: 54
signe, 10x...i change it to 6 hours it's ok?
And do i had to wait 24 before reconfig?
Posts: 2322
If you delete the cache file, you don't have to wait at all.
Otherwise, you have to wait for whatever time period you specified in the timeout.
Posts: 2
I too am experiencing a similar problem with the random block. However it seems to be a little more widespread in that when i make changes to the gallery the block causes out of bounds issues.
I see from the post why that is happening.
However with Xanthia (default install on pn 0.750) and gallery 1.4.4-pl2 after experiencing this issue when i tried to add a new block it gave me a similar error and only displayed the right hand blocks in a clumn, an now i get a blank page any suggestions as to why this is happening?
Help resolving this would be greatly appreciated
Posts: 54
i really dont know anything about Xanthia (default install on pn 0.750) but cannot see how random block reffers to your block system.
Posts: 8
Same problem here. Using 1.4.4 pl2 version of Gallery. I wonder if this has something to do with a PHP patch or something? I mean, as the original poster stated, this happens "sometimes". On the site, I kept pressing F5 to refresh the page over and over and over. About half the time, I got an error and the other half it loaded correctly. ARGGHHHH...so many variables. Is it a memory issue? Is it a PHP issue? Is it too many sites hosted on a single server? Intermittent problems are the hardest to figure out. Not even sure how to troubleshoot this one other than, I for one confirm it is indeed an issue.
JQ
Posts: 54
go to your Albusm dir, and delete the file randomblock.cache . It happnes if you move pictures from one dir to other...or delete images.And if you move albums too.
Posts: 8
Thank you for the suggestion, but I do not have a random block on the site. Strangely enough, the home page of the site just "references" images in the gallery, but does not actually use "Gallery" (if that makes sense). And I still get the out of bounds error message. Here is one:
I looked for the file but one could not be found--again thanks for the suggestion, but the problem persists.
Posts: 54
That should Help!Just set it to lower time.
What do you mean about
You're using some URLs of pictures from the Gallery in Home page?If you're using the url from Gallery,and you have modified in any way your gallery(moving albums,pictures,deleting... etc), it's normally to get an error, cause the URLs go wrong.
Posts: 8
Ok, I'll try the shorter cache idea and let you know.
To your point of referencing the pix on the homepage, you are correct. I agree--this is dangerous, but these are pretty static and won't change. The point is, the gallery program isn't even being used--we're just referencing the photos with simple links.
That is the strangest... This is why I think it might not even be gallery, but maybe a PHP patch or memory issue on the server or something else.
I'll try the cache though and let you know.
Thanks again!
JQ
Posts: 16
I've had this error before and have fixed it by deleting the .cache file in the albums directory as well as specifying a shorter value in the config (30 minutes). In fact, I just deleted the .cache file yesterday because I got the error again. I have it set to a 30 minutes rebuild.
However, I just got the error again today and went in to delete the cache file but it's not there. What do I do now? Why didn't the file come back?
Posts: 16
Nevermind my question above. It seems that I had started out using one version of Random image block but switched to another. The second version I put in didn't put in a .cache file which is why I couldn't find it. So I switched back to the first version I had (I think they're done by the same author) and the .cache file is there now. Weird.