Tips
1. Image representing a gallery (category)
- Image - when editing category, image can be selected and this will represent the category
- Folder icon - can be set in parameters
- Avatar - can be set in parameters
- Image from the category - it can be random image but even an image with specific ordering (e.g. first image from the category will be set). If you want to display an image as category icon and you don't want to display such image in list of category, then you set the first image as unauthorized. Such image will be displayed as category icon but will be not displayed in list of images. (Don't forget to set right ordering of images which should be selected as folder icon, if you have unauthorized first image, then the ordering must be ordered by ordering, so the first unauthorized image will be selected)
See Options (Parameters) to set the image.
The parameter Display image instead of folder icon displays the folder icon as default, here the image from the category can be set. If the image will be set, then you can set the specific image from the category (subcategory) with help of ordering: Categories Image Ordering. So you can set, e.g. first image from the category will be displayed as category image.
2. How to disable "save image as" after right clicking
If you want to disable context menu "save image as" after right clicking, just customize the template of view where you want to apply this.
E.g. Detail View in Phoca Gallery. Edit:
components/com_phocagallery/views/detail/tmpl/default.php
and add the following code to the top of the code:
$document = &JFactory::getDocument();
$document->addScript(JURI::base(true).'/components/com_phocagallery/assets/jquery/jquery-1.6.4.min.js');
<script type="text/javascript">
jQuery.noConflict();
jQuery(document).ready(function($){
jQuery('img').bind('contextmenu', function(e){
return false;
});
});
</script>
3. Changing word "category" to other word in URL (SEF link) of Phoca Gallery (or other Phoca extension)
- PhocaGalleryBuildRoute - one which will build the modified URL
- PhocaGalleryParseRoute - second which will parse the modified URL and will translate it to standard URL
- components/com_phocagallery/router.php file.
Open the file and find the following string:
return $segments;
at the bottom of the method PhocaGalleryBuildRoute
Add the following code:
if (!empty($segments)) {
foreach ($segments as $k => $v) {
if ($v == 'category') {
$segments[$k] = 'Kategorie';
}
}
}
before (above) this string. Change the word "Kategorie" to your own word you want to get in your URL. Now links will be build with "Kategorie" instead of "category" in Phoca Gallery. Such links need to be translated back so Phoca Gallery and Joomla! understand them. See the PhocaGalleryParseRoute method.
Find this string:
case 'category' :
and change it to:
case 'Kategorie' :