Keyword

sort k2 tags

  • shahrouz
  • shahrouz's Avatar Topic Author
  • Offline
  • New Member
More
5 years 1 month ago #171051 by shahrouz
sort k2 tags was created by shahrouz
Hi
I appreciate your hep regarding my question in the following link:
www.joomlaworks.net/forum/k2-en/46487-the-problem-in-view-of-k2-by-alphabetical-persian-ordering?limitstart=0

I have another question in the same field:
The Persian letters in the module tags K2 do not appear in lists in proper alphabetical order. To sort this module, which table of the database is to be changed?

Thank you for your assistance.

Please Log in or Create an account to join the conversation.

More
5 years 1 month ago #171060 by JoomlaWorks
Replied by JoomlaWorks on topic sort k2 tags
Are you referring to the Tag Cloud option in the "K2 Tools" module (mod_k2_tools)?

Fotis / JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • shahrouz
  • shahrouz's Avatar Topic Author
  • Offline
  • New Member
More
5 years 1 month ago #171067 by shahrouz
Replied by shahrouz on topic sort k2 tags
yes that is right

Please Log in or Create an account to join the conversation.

More
5 years 1 month ago #171073 by JoomlaWorks
Replied by JoomlaWorks on topic sort k2 tags
The sorting mechanism is alphabetical already but perhaps it has trouble applying properly to Persian.

Can you send me a link to your site with the module on and let me know what the actual order should be so I can replicate it to my dev environment for testing?

Fotis / JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • shahrouz
  • shahrouz's Avatar Topic Author
  • Offline
  • New Member
More
5 years 1 month ago #171086 by shahrouz
Replied by shahrouz on topic sort k2 tags
Thank you for your quick reply.
You can see the desired order in right section of the following link, the actual order of letters must be as indicated by numbers, 1. 2, etc.:
transcoiran.com/k2/index.php/fa/

The alphabetical order in K2 menu category is now correct.
I need an email from you to send the control panel password, if it is needed. Or you may give me another suggestion so that i can keep it private.

Please Log in or Create an account to join the conversation.

More
5 years 1 month ago #171112 by JoomlaWorks
Replied by JoomlaWorks on topic sort k2 tags
So, I guess the sorting we do is not Persian friendly. The good news is that you can simply re-order the foreach loop in the mod_k2_tools tags.php override here: github.com/getk2/k2/blob/master/modules/mod_k2_tools/tmpl/tags.php#L16

Can you generally use e.g. sort() in PHP on your server to properly order alphabetically an array of Persian words?

Fotis / JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • shahrouz
  • shahrouz's Avatar Topic Author
  • Offline
  • New Member
More
5 years 1 month ago #171152 by shahrouz
Replied by shahrouz on topic sort k2 tags
Thank you very much.
The link you have mentioned is exactly the same we use. Unfortunately, I am not skillful enough to perform what you have suggested. Would you please do me a favor and perform the necessary changes yourself?
Many thanks indeed!

Please Log in or Create an account to join the conversation.

More
5 years 1 month ago #171162 by JoomlaWorks
Replied by JoomlaWorks on topic sort k2 tags
I would recommend you follow the hints outlined here: stackoverflow.com/questions/22796522/php-array-sorting-and-compatibility-with-persian-alphabets

These will help to check if your server has the right locale and then you can use the "Collator" solution mentioned here stackoverflow.com/a/46765380/1157949 to do the proper sorting.

Fotis / JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.

  • shahrouz
  • shahrouz's Avatar Topic Author
  • Offline
  • New Member
More
5 years 1 month ago #171181 by shahrouz
Replied by shahrouz on topic sort k2 tags
Thank you.
I changed all collations to utf8_persian_ci in phpadmin.
I also visited and used stackoverflow.com/questions/22796522/php-array-sorting-and-compatibility-with-persian-alphabets.
Unfortunately, the problem has not been solved yet.

Please Log in or Create an account to join the conversation.

More
5 years 1 month ago #171194 by JoomlaWorks
Replied by JoomlaWorks on topic sort k2 tags
Do you have the required PHP modules to use the Collator class?

Fotis / JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)

Please Log in or Create an account to join the conversation.


Powered by Kunena Forum