Page 1 of 1

CMSMS Forge : xml files with non-ascii char

Posted: Fri May 07, 2010 1:44 pm
by redwarp
Well, I'm developping a module, IPLock.
As I'm french, I made it in french.
And that means that I wrote the module description in french, and it contains accended accent.
My name contains accented accent as well : Benoît Vermont (check the "i", it's accented !)
Using the admin panel in CMSMS Forge, I uploaded my file, IPLock-0.3.4.xml, generated with CMSMadeSimple.
When, later, I tried to install it using the Module Manager, and, how, surprise ? Bad checksum error blahblahblah...
Then I started to think : could it be, like always, an encoding problem ?

Just to be sure, I tried to install another module, Import_Content. Why ? Because it's description is written in cyrillic, i.e. not ASCII chars. And I got the same bad checksum error

I opened my xml file, IPLock-0.3.4.xml, and its first line is :

Code: Select all

<?xml version="1.0" encoding="ISO-8859-1"?>
Funny. On my computer, the file is obviously encoded in UTF-8...
I tried to fix this first line, like this :

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
And uploaded this new file, named IPLock-0.3.5.xml
Well, it didn't fix anything.

I still have this awesome message "Bad Checksum blahblahblah"

Well... last resort... I removed the accent in my name (Now, I'm only Benoit Vermont), and rewrote the moddescription in english. No accented accent.
I then uploaded the file again, now named IPLock-0.3.5.1 and EUREKA ! It works ! No bad checksum error !

I guess I have a solution, but... it's not really what I wanted.
I mean, I wanted to translate the module, anyway, But I thought the moddescription, even in french, would work. And I thought the moddescription could be localized...

I posted this message, because I wanted to report a problem. Has anyone been confronted to the same kind of stuff ?

Cheers

--
Redwarp

Re: CMSMS Forge : xml files with non-ascii char

Posted: Fri May 07, 2010 2:51 pm
by calguy1000
Yes, we should support non latin characters in the name field... and I do know why it isn't working.  I am just wondering if I will break every other xml file available to fix it.

However...  for the rest, we require that everything for a module be in english first, and translated to other languages.
If there are modules that aren't in english first it won't be long before they disappear from the forge.  This is because
it makes the translation job easier, and actually improves usability for those people that don't know 'your first language'
but do know english.

Re: CMSMS Forge : xml files with non-ascii char

Posted: Fri May 07, 2010 3:11 pm
by redwarp
Really ?
we require that everything for a module be in english first, and translated to other languages.
Well, it's the first time I read that !
I'm okay to translate it in english, but my level is far from perfect. It's gonna be ugly. Euark.

When I read guides about creating modules, they said (they... always they. damn they) that if you develop a module, you should create a file named .php in the lang folder, and put additionnal langages in the ext folder. Never said nothing about writing it in english...

Anyway. This problem about ASCII char still sucks. Well, of course, it's unimportant, if we have to write in english. But still...
Because it would be great if the mod description could be localized as well, don't you think ?

Anyway, I'll work on a translation next week. It's getting late here, and I should leave the office and go home.

Have a nice day, evening, morning ?

--
Redwarp

Re: CMSMS Forge : xml files with non-ascii char

Posted: Fri May 07, 2010 3:17 pm
by calguy1000
Module descriptions can be localized as well... once it's translated.

However, yeah we've finalized on the english first thing for a few reasons
a) people don't have to translate from to   its just 'english' to
b) with the possible exception of french, english is the most predominant language in the IT industry
    (even the languages themselves are written assuming english... the function names are english or english abbreviations).

I'm sure somebody in the french translation project will be able to help you with translating the main lang file. to english.

Re: CMSMS Forge : xml files with non-ascii char

Posted: Fri May 07, 2010 5:11 pm
by redwarp
Na your right : english is the most predominant language in the IT industry.

It's just that : when I started this module, I didn't think I would share it. My boss asked me for this feature, so I developped it. In french of course.
But then I thought : what the hell, it could be usefull to other people as well !
And my superior gave me the green light to share it, and therefore, here I am !
With a minor detail to deal with of course : localisation.

Anyway, of course, Module description can be localized, but... The only place you can actually read this module description is when you use the Module Manager. And as for the Module Manager, it uses the Module Description written in the xml file. And it cannot be localised.
--
Redwarp