Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Aiheen aloitti: Raffoz - kesäkuu 06, 2017, 03:36:36 AP

Otsikko: Name of attachments
Kirjoitti: Raffoz - kesäkuu 06, 2017, 03:36:36 AP
Before 2.0.14 when i used names of attachments with accents inside, it worked correctly.
Today with 2.0.14 SMF post the attachment, but the name of the file appear truncated, as if it was without name.

Any solution?
Tks
Otsikko: Re: Name of attachments
Kirjoitti: Kindred - kesäkuu 06, 2017, 06:19:48 AP
are you using utf-8?
Otsikko: Re: Name of attachments
Kirjoitti: Raffoz - kesäkuu 06, 2017, 06:24:23 AP
Italian: ISO-8859-1

I think this is the answer.
Otsikko: Re: Name of attachments
Kirjoitti: richardwbb - kesäkuu 07, 2017, 03:59:03 IP
Raffaele1977, did you know that accenting filenames in general isn't a great idea. Really. For smf, I don't know man, I wouldn't touch it inside smf, even if my users of my board can use that, I wouldn't touch that either.
Otsikko: Re: Name of attachments
Kirjoitti: Portugal - elokuu 14, 2019, 09:57:10 AP
I have the same problem since one year ago, anyone has solved this problem? My forum is in Portuguese language (we have some special characters) and isnt in UTF8.
Otsikko: Re: Name of attachments
Kirjoitti: Raffoz - elokuu 14, 2019, 09:58:25 AP
I didn't solve it, sorry :(
Otsikko: Re: Name of attachments
Kirjoitti: Aleksi "Lex" Kilpinen - elokuu 19, 2019, 01:13:53 AP
Lainaus käyttäjältä: Portugal - elokuu 14, 2019, 09:57:10 AP
(we have some special characters) and isnt in UTF8.
This in general isn't a good combo, and like mentioned - filenames typically shouldn't have special characters to begin with.
Otsikko: Re: Name of attachments
Kirjoitti: Raffoz - elokuu 19, 2019, 03:19:50 AP
Lainaus käyttäjältä: Aleksi "Lex" Kilpinen - elokuu 19, 2019, 01:13:53 AP
Lainaus käyttäjältä: Portugal - elokuu 14, 2019, 09:57:10 AP
(we have some special characters) and isnt in UTF8.
This in general isn't a good combo, and like mentioned - filenames typically shouldn't have special characters to begin with.

I understand and agree, in general.
But there are languages, like Italian, where accenting words are normal and create filenames without accents would result in a "grammatical error".
This is the reason.
Otsikko: Re: Name of attachments
Kirjoitti: Arantor - elokuu 19, 2019, 03:53:27 AP
There is actually nothing preventing accented characters in file names, the fact that the file name on disk on Windows is neither ISO-8859-anything or UTF-8 is no barrier as long as the forum is set up to use UTF-8 correctly.

(Windows uses UTF-16 under the hood. Linux uses UTF-8 I believe. As long as what gets into the database goes through the UTF-8 channels it should be fine.)
Otsikko: Re: Name of attachments
Kirjoitti: shawnb61 - elokuu 19, 2019, 11:03:31 AP
Yep.  This is a bug.

Note that 2.1 is far better at non-English support.