Leave a suggestion

If this tutorial is not what you were looking for, you still have any questions, suggestions or concerns - feel free to let us know. Please help us to serve you better!

Your Name

Your Email

Your Message (required)

captcha

Joomla 2.5.x. How to sort K2 tags

This tutorial is going to show you how to sort the default gallery tags on your Joomla 2.5 template.

  1. On your FTP server go to the templates\theme_###\html\com_k2\templates\portfolio\ folder.
  2. Open a category.php in any PHP editor.
  3. Look for the following line using Ctrl + F:
    $tags = array_unique($allTags);
  4. Add a new function right under that line:
  5. rsort($tags);

    in order to sort the tags in the reverse  alphabetical order or

    sort($tags);

    in order to sort the tags alphabetically

  6. Save the changes and check the gallery page on your site.

Feel free to check the detailed video tutorial below:

Joomla 2.5.x. How to sort K2 tags

Joomla 2.5.x. How to sort K2 tags, 3.0 out of 5 based on 2 ratings