If you have some issue while using Phoca extension, try to check this list of general advices for running Phoca extensions successfully. Error-free run of the Phoca application depends on many factors, e.g. : Joomla! settings, PHP settings, SQL settings, used template, loaded external extensions on the same site, etc. Mostly, error which prevents from successfully running of Phoca extension, is not produced by Phoca extension itself or not directly by Phoca extension. This is why the recognition of a problem is very difficult.
1. Error while saving Phoca Gallery (or other Phoca extension)
This error is mostly caused by missing Phoca Gallery tables in your database. Check if your database includes all Phoca Gallery (or other Phoca extension) tables. See Installation Problem Solving article. This article describes Phoca Gallery but it is similar to other Phoca extensions.
2. Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource
There is an error while running SQL query. To get more detailed information about such error, enable debug mode in your Joomla! (Joomla! Administration - Site - Global Configuration - System - Debug System - Yes). See:
- CSS problem - you can use e.g. Firefox browser and its addon Web Developer to disable/enable each loaded CSS on the site. Such way you can get information in which CSS file the problem part is loacated. Then you can customize or fix this part in the CSS file.
for basic tags. Removing this rule mostly helps to fix the problem.
4. Blank (white) page (or Error 500)
Blank page is mostly displayed in case, some PHP error (Fatal error) stopped the loading of the script (loading of the site). There is no other option how to detect what caused the problem than enabling PHP error reporting on your server or looking at errorlog file on your server. See:
- How to enable displaying PHP errors on site (mostly you need to ask your webhosting provider to enable this feature :-( and disable it again after finding the problem because of security reasons).
This error is caused by not enough memory to run the PHP script on your server. Mostly there are two reasons to get such error in Phoca Gallery:
- Creating thumbnails from images. Thumbnails are created by your server, by GD library. Server is not like your PC and mostly it does not have so much memory for running a script like you have on your PC (because there are many other tasks a server must run). If you get this error you need to:
- increase memory on your server (mostly you need to ask your webhosting provider to enable this feature :-( )
- or resize images before upload to your server. Common servers have problems e.g. with images larger than 2MB. Such size of image is normally not used in internet so resizing original images before uploading is recommended. You can resize the images on your PC or they can be resized while uploading (using Java upload method - the size can be set in Phoca Gallery parameters)
- or create thumbnails on your PC (where you can get more memory as only one instace is running) and then copy these images/thumbnails to your server - to phoca gallery image folder: images/phocagallery.
- Phoca Gallery automatically creates thumbnails from images which do not have any thumbnails yet. This is why Phoca Gallery must check every image step by step. It can be challenging in server performance if there are many images in your gallery. If so, you need to enable Pagination Thumbnail Creation parameter in Phoca Gallery parameters, see: Global Configuration (Parameters - component in menu item).
6. SEF, 404, Menu link
Phoca extensions are supporting SEF because their links are created by standard Joomla! JRoute class. See the following article to solve possible problems with SEF:
If you are using external SEF component, you need to ask the developer of this component if it supports Phoca extension.
If you are using Phoca Gallery version 2.7.5 or later and on your server Suhosin PHP extension is installed, you can run into problems when saving menu link to Phoca Gallery in Menu Manager.
One of the Suhosin security parameter is called suhosin.post.max_vars. Its value is mostly set to 200. But while saving menu link to Phoca Gallery in Menu Manager, more than 200 POST variables are transferred (more than 200 parameters). Unfortunately Suhosin does not retun any error message (this is maybe because of security reasons), the site is redirecting back to main site of Menu Manager and the menu link will be not saved.
It means, if you are not able to save menu link to Phoca Gallery in Menu Manager (Menus - e.g. Main Menu - New - Phoca Gallery - e.g. Phoca Gallery Category List Layout - Save) because the site is redirecting to main site of Menu Manager, try to check your PHP settings:
Joomla! administration - Help - System Info - PHP Information. Try to find 'suhosin' string, try to find the value of suhosin.post.max_vars. If there is such parameter and its value is approximately set to 200, you need to change it in php settings (increase this value e.g. to 250). There are other Suhosin security settings, so if the changing of suhosin.post.max_vars will not help, try to check other Suhosin parameters too (e.g. suhosin.request.max_vars, etc.).
8. Image or Iframe Method
Phoca Gallery uses two different methods to display images in detail window.
- Modal Box (image only)
- Highslide JS (image only)
- JAK lightbox
- Standard Popop (not iframe but has the same behaviour like iframe)
- Modal Box
- Highslide JS
- No Popup (not iframe but has the same behaviour like iframe)