yellow1912:
Gomlers, yes you can.
First, assuming the language code for Norwegian is "no" (please check, Im not sure)
Create a file named no.php
Put it in includes/classes/ssu/plugins/languages/
Now, for the content of the file, put it:
(make sure this php file is utf8 encoded)
<?php
/**
* @package Pages
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: ru.php 218 2009-07-20 02:38:17Z yellow1912 $
*/
// note: we can later move part of this function into sub-functions, which we can store in the base class.
class SSULanguageNo extends SSULanguage{
static function parseName($name){
$cyrillic = array("æ", "ø", "å");
$translit = array("ae", "o", "a");
$name = str_replace($cyrillic, $translit, $name);
$name = strtolower($name);
// we replace any non alpha numeric characters by the name delimiter
$name = self::removeNonAlphaNumeric($name, SSUConfig::registry('delimiters', 'name'));
// Remove short words first
$name = self::removeShortWords($name, SSUConfig::registry('configs', 'minimum_word_length'), SSUConfig::registry('delimiters', 'name'));
// trim the sentence
$name = self::trimLongName($name);
// remove excess SSUConfig::registry('delimiters', 'name')
$name = self::removeDelimiter($name);
// remove identifiers
$name = self::removeIdentifiers($name);
// remove trailing _
$name = trim($name, SSUConfig::registry('delimiters', 'name'));
return urlencode($name);
}
}
```Then rename local.config.php.example in includes/classes/ssu/ to local.config.php and edit it:
>
> ```php
<?php
/**
* @package Pages
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: local.config.php.example 149 2009-03-04 05:23:35Z yellow1912 $
*/
$ssuLocalConfig = array(
'languages' => array( 'no' => 'no'
)
);
```
>
> Then go to Admin->Extras->SSU Manager to clear out the cache then check your links again.
> Troubleshooting:
> 1. Make sure the first file is uploaded with utf8 encode
> 2. Make sure the language code is correct (this is easy, in the normal form Zencart language links look like this: index.php?.......&language=language_code
> More info:
> <http://wiki.rubikintegration.com/zencart/modules/ssu/for_developers/parsers/language_parser#how_to_create_your_own_parser>
>
> **Note that I assume the language code is "no"**
Hello. I have the same problem as mr. from Norway up there. I did everything as you mentioned above, but the SSU works, however Slovenian language does NOT. For all the special characters I get "-" instead of the letter.
Here's the UTF-8 encoded
/includes/classes/ssu/plugins/languages/**si.php**
```php
<?php
/**
* @package Pages
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: ru.php 218 2009-07-20 02:38:17Z yellow1912 $
*/
// note: we can later move part of this function into sub-functions, which we can store in the base class.
class SSULanguageSi extends SSULanguage{
static function parseName($name){
$cyrillic = array("č", "Č", "Š", "š", "Ž", "ž", "Ć", "ć");
$translit = array("c", "C", "S", "s", "Z", "z", "C", "c");
$name = str_replace($cyrillic, $translit, $name);
$name = strtolower($name);
// we replace any non alpha numeric characters by the name delimiter
$name = self::removeNonAlphaNumeric($name, SSUConfig::registry('delimiters', 'name'));
// Remove short words first
$name = self::removeShortWords($name, SSUConfig::registry('configs', 'minimum_word_length'), SSUConfig::registry('delimiters', 'name'));
// trim the sentence
$name = self::trimLongName($name);
// remove excess SSUConfig::registry('delimiters', 'name')
$name = self::removeDelimiter($name);
// remove identifiers
$name = self::removeIdentifiers($name);
// remove trailing _
$name = trim($name, SSUConfig::registry('delimiters', 'name'));
return urlencode($name);
}
}
```
and here's the includes/classes/ssu/local.config.php
```php
<?php
/**
* @package Pages
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
* @version $Id: local.config.php.example 149 2009-03-04 05:23:35Z yellow1912 $
*/
$ssuLocalConfig = array(
'languages' => array( 'si' => 'si'
)
);
```
I cleared the cache also after the modification, but still doesn't work.
check my [WEBSITE](http://www.pocenigume.net) where I'm trying to fix it... click on the "Platišča" for instance, and you'll see.. :(