Menu Content

Support

> Forums, FAQs & Paid Support
Welcome, Guest
Username Password: Remember me

Problem with charset in "Manage words"
(1 viewing) (1) Guest
Support forum for users using free edition of JoomSEF 3 (Joomla 1.5 compatible). These forums are mainly for mutual help between users.

Please note that due to our capacity limitations, we do not monitor these forums regularly.
  • Page:
  • 1

TOPIC: Problem with charset in "Manage words"

Problem with charset in "Manage words" 14 years, 6 months ago #12088

  • rama
At Extras Management when we add a words to become internal links to sef urls the plugin doesn`t work with cyrillic symbols. How to resolve the problem or which files are responsible for this plugin?

Re:Problem with charset in "Manage words" 14 years, 2 months ago #14822

I have the same problem also. I'm using some greek keywords for internal linking along with some english keywords. The english keywords can be linked but nothing happens to the greek ones.

Does anyone found a workaround on this?

thanks

Re:Problem with charset in "Manage words" 14 years, 2 months ago #14824

After digging a little bit in the code I found something that maybe helpful to others.
I'm not sure If I did everything properly but it works for me just fine.

Go to
plugin->joomsef.php
and find the regular expression at line 458:

$regEx = '\'(?!((<.*?)|(<a.*?)))(\b'.$word.'\b)(?!(([^<>]*?)>)|([^>]*?</a>))\'si';


replace it with:

$regEx = '\'(?!((<.*?)|(<a.*?)))('.$word.')(?!(([^<>]*?)>)|([^>]*?</a>))\'si';



Please let me know if it works for you also.

Re:Problem with charset in "Manage words" 14 years, 2 months ago #14840

  • dajo
  • OFFLINE
  • Posts: 5069
Hello,

Thank you for your report. However, your fix will also match the substrings of the whole words. To maintain the functionality to match only the whole words, the regular expression should look like:
$regEx = '\'(?!((<.*?)|(<a.*?)))((?<!\pL)'.$word.'(?!\pL))(?!(([^<>]*?)>)|([^>]*?</a>))\'siu';

This will be fixed in next version of JoomSEF.

Best regards,
ARTIO Support Team
ARTIO Support Team

Re:Problem with charset in "Manage words" 14 years, 2 months ago #14841

Thanks for your quick reply.

I'm not so good at regular expressions, I knew that in my code was something missing because I had problems with the substrings as you mention.

I replaced it with your code and the problem fixed.


best regards
  • Page:
  • 1
User Login Empty