Page 1 of 2
Phoca Gallery Map Bug
Posted: 30 Sep 2009, 00:51
by Pippozzo
Hi, I've an error on Map from a very old version of this component (blank page), but now with Phoca Gallery 2.5.8 (Joomla 1.5.14) I receive this message:
Code: Select all
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, postmaster@MYSITE.it and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
The error is on 170° item of categories on line 86 of components\com_phocagallery\views\categories\view.html.php file
Code: Select all
if (!empty($hideCatArray) && is_array($hideCatArray)) {
The values of variabiles are:
$display_empty_categories: 0
$items[$key]->numlinks: 8
isset($hideCatArray): 1
count($hideCatArray): 1
empty($hideCatArray):
!empty($hideCatArray): 1
is_array($hideCatArray): 1
category id: 166
With this information, can you help me, please?
Thanks in advance
PS: At the moment I haven't categories with geolocalization, but the query select all categories and it's so slow
Re: Phoca Gallery Map Bug
Posted: 30 Sep 2009, 17:05
by Jan
Hi, sorry I don't understand this:
The error is on 170° item of categories on line 86 of components\com_phocagallery\views\categories\view.html.php file

Re: Phoca Gallery Map Bug
Posted: 30 Sep 2009, 17:44
by Pippozzo
I inserted a break in the code to find the breaking point in
/components/com_phocagallery/views/categories/tmpl/default_map.php
The script is Ok until one hundred seventieth item
Code: Select all
$numitem= 0;
foreach ($items as $key => $item) {
$numitem++;
// Unset empty categories if it is set
if ($display_empty_categories == 0) {
if($items[$key]->numlinks < 1) {
unset($items[$key]);
$unSet = 1;
continue;
}
}
if ($numitem== 170)
{
echo '<br />isset: ' . isset($hideCatArray);
echo '<br />id ' . $item->slug;
exit;
}
// Unset hidden category
if (isset($hideCatArray) && is_array($hideCatArray)) {
// Here I receive error
$unSetHCA = 0;
..........
The record with id 166 is:
Code: Select all
166 26 Trekking: La Foresta del San Gerbone la-foresta-del-san-gerbone left <p><br /><strong>Trekking: La Foresta del San Gerb... 0000-00-00 00:00:00 1 0 0000-00-00 00:00:00 NULL 4 0 0 25 0 -2 -2 NULL 2
Re: Phoca Gallery Map Bug
Posted: 05 Oct 2009, 22:15
by Pippozzo
It isn't clear now?
The bug is circumscribed!
Thanks in advance
Re: Phoca Gallery Map Bug
Posted: 06 Oct 2009, 13:36
by Jan
Still not understand what is the error there?

Re: Phoca Gallery Map Bug
Posted: 06 Oct 2009, 16:05
by Pippozzo
Nobody has ever reported a similar error?
Can I send you an FTP account for testing?
I really need!!!
Thanks so much
Re: Phoca Gallery Map Bug
Posted: 06 Oct 2009, 20:37
by Jan
More information about this error may be available in the server error log.
is there some more information in error log?
Re: Phoca Gallery Map Bug
Posted: 07 Oct 2009, 09:30
by Pippozzo
My Configuration:
Error Reporting: Maximum
But in the page appear only:
Code: Select all
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, postmaster@MYSITE.it and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
and so I've debugged the code (previous post)
Now I've asked error log to the hosting services...
Thanks again
Re: Phoca Gallery Map Bug
Posted: 07 Oct 2009, 18:29
by Jan
But in the page appear only:
Yes, but it says:
More information about this error may be available in the server error log.
So did you see the error log on your server?
Re: Phoca Gallery Map Bug
Posted: 26 Oct 2009, 10:33
by Pippozzo
This is the replay of my hosting:
With regard to your note, we made extensive tests by identifying the cause of the error in the "getRandomImageRecursive ()" declared in the file "/ components / com_phocagallery / models / categories.php.
This function, as its name indicates it, shall randomly draw an image of all those present. As there are hundreds of photos will find all the photos using this method takes longer than the 120-second timeout configured on the server, so if there is an error "500 Internal Server Error".
Usually in Joomla you can disable recursion allowing you to decrease the time of the file, and making the application is running but the function in question does not provide that option, so please refer to the Mother of the application site explaining the problem and see if there are changes / patch code to bypass this problem.
Jan, can you help me, please?