|
Vocabulary Editor vs. external Editor
Hello,
I observed that when I use an external editor instead of the EM2 internal
Vocabulary Editor that after saving the file and accessing it in EM2
(eg.Location.txt) then EM2 changes the formatting and encoding-type of
'location.txt'.
For example when using the Vocabulary Editor and edit contents in the field
'Location' in the folder of default vocabulary then everything is just fine.
But when I open that same file in an external Editor (ClearEdit or
Notepad++) the editor shows that the file is encoded as 'UTF-16 little
endian' (=UCS-2 little endian).
One can enter or delete a location value and save the file 'location.txt'.
After accessing this file in EM2 by selecting a location value then one can
observe that the file-size changes. This can easily be observed for the
corresponding file in the folder of the default vocabulary.
Reopening the same file in an external editor reveals that EM2 has inserted
empty lines (?).
Also the first line now appears twice.
I find this a very strange behaviour.
I use both Editors to write code in HTML, PHP, XML, XSL and never had
Editor-specific issues.
So I am wondering what EM2 is doing to the file?
It would also be intersiting to know what character-encoding EM2 is actually
using. I might have missed it but didn't find any indication about the used
character encoding. I would presume that it is Windows/ANSI or iso-8859-1.
Saving the file in UTF-8 does not change this behaviour of EM2.
So here is the question: What is the proper way of editing files in the
vocabulary folder so that EM2 does not change the newly edited file?
To me this is hard to comprehend and ask you to please try it for yourself.
Any helpful advice is highly appreciated.
Many thanks, Hans.
|