Hello. How can i use accented and special characters (like à or ã, ' [single quote], etc) in category names and have those correctly displayed in isotope filter on gallery view?
AS Templates
POSTED: 2016-05-09
Hello JORGETREIS,
Please do not use any special characters, category names do not support them.
Regards, AS Team.
jorgetreis
POSTED: 2016-05-26
Solution:
in templates/as002058/html/com_content/category/gallery.php at line 49
Get an access to all 94 items designed and developed by AS Designing team plus all the future items
which will be released over the course of your club subscription.
Price starting from $59.00
Please do not use any special characters, category names do not support them.
Regards, AS Team.
in templates/as002058/html/com_content/category/gallery.php at line 49
replace
foreach ($this->intro_items as $key => &$item){
$categoryTitle = strtolower(str_replace(" ","_",$item->category_title));
$galleryCategories[] = $categoryTitle;
};
with
foreach ($this->intro_items as $key => &$item){
$categoryTitle = array("title"=>strtolower(str_replace(" ","_",$item->category_title)),"titleDoDisplay"=>$item->category_title);
array_push ( $galleryCategories , $categoryTitle );
at line 63
replace:
$galleryCategories = array_unique($galleryCategories);
with:
$galleryCategories = array_map("unserialize", array_unique(array_map("serialize", $galleryCategories)));
at line 64
replace:
<?php foreach ($galleryCategories as $key => $value) : ?>
<li><a class="" href="#"data-filter=".<?php echo $value; ?>"><?php echo ucwords(str_replace("_"," ",$value)); ?></a></li>
<?php endforeach; ?>
with:
<?php foreach ($galleryCategories as $key => $value) : ?>
<li><a class="" href="#" data-filter=".<?php echo $value['title']; ?>"><?php echo $value['titleDoDisplay'];?></a></li>
<?php endforeach; ?>
that's it
Thanks for sharing information with our community.
Regards, AS Team.
replace:
<li class="item span<?php echo round((12 / $this->columns)) ;?> <?php echo strtolower(str_replace(" ","_",$item->category_title)); ?>">
with:
<li class="item span<?php echo round((12 / $this->columns)) ;?> <?php echo $item->category_alias;?>">