You are not logged in.
Sorry, I don’t quite get it. I didn’t have Notepad so I just installed it, but how do I save a file as ANSI? Do I choose Format and check Encode in ANSI? Do I also have to check UTF-8 without BOM?
<txp:Els /> ;)
Tag Reference | Unexpected behaviour? Check the tag trace | Still no clue? Check the names of your custom fields
Offline
Never mind, I did it (without checking UTF-8 without BOM) and the BOM is gone!
Thanks for your trouble Ruud! Just curious: how on earth do you find and see that BOM? I never saw anything…
<txp:Els /> ;)
Tag Reference | Unexpected behaviour? Check the tag trace | Still no clue? Check the names of your custom fields
Offline
In Dutch: kladblok (should be installed by default in Windows)
Yes, choose the format ‘Ansi’. If “UTF-8 without BOM” is also a option you can check, that would be even better, although for this file it probably won’t matter.
Offline
Using a hexdump utility, you can easily find these things.
For Linux users, run this in the directory that contains the files you want to check (it matches images as well, but this is mostly to quickly find candidates that have a BOM, although it doesn’t work on files/dirs with spaces (should’ve used xargs)):
for i in `find . -type f|grep -v .svn`; do od -x $i |grep 'bbef' > /dev/null && echo $i; done
I confirmed this by viewing the file with ‘less’ (it shows “<EF><BB><BF>” at the beginning of the file). It probably helps that I have my locale set to POSIX or some single-byte charset (haven’t switched to UTF-8 yet), otherwise i’d have to use ‘hexdump’ to confirm it (the hexdump would have shown: “bbef 3cbf” as the first hex chars).
Last edited by ruud (2007-05-24 22:13:47)
Offline
Kladblok??? I hate that ;) That doesn’t have all those options. What I just installed is Notepad++.
Edit: (crossposting all the time…)
ruud wrote:
For Linux users,
Ah, learned something again. I should spend more time with my Linux laptop in stead of this Windows thing… ;)
Thanks again!
Last edited by Els (2007-05-24 22:08:04)
<txp:Els /> ;)
Tag Reference | Unexpected behaviour? Check the tag trace | Still no clue? Check the names of your custom fields
Offline
ruud
thanks for tracking this one down in the MLP. Your script example will come in handy too for checking files before packaging up future builds.
Do you happen to know the unix command line way of truncating the BOM from such files?
Edit: Think I just worked out a way to do it using “dd ibs=1 skip=3”. Anyway, will play with that and see what happens.
Edit2: Yes, dd if=l10n_base.php of=new_l10n_base.php bs=1 skip=3 does the job just fine.
Last edited by net-carver (2007-11-12 09:01:27)
— Steve
Textile | My plugins on GitHub | @netcarver
Offline
I have the Byte-Order Mark bug with the latest version of the pack (0.7.650).
I think the bug might be somewhere in the gbp_admin_library plugin.
When the gbp_admin_library plugin is inactive, I get an error-message at the first line of my document with the doctype on the second line.
When I activate the plugin, I get an empty line first before the doctype and my xhtml page renders invalid: Byte-Order Mark found …
Offline
The BOM problem should have been fixed. So you’d better post this in the plugin thread.
<txp:Els /> ;)
Tag Reference | Unexpected behaviour? Check the tag trace | Still no clue? Check the names of your custom fields
Offline
beatfreak
thanks, I’ll look into it.
— Steve
Textile | My plugins on GitHub | @netcarver
Offline
beatfreak
I’ve gone trough the source code and the files included in that version of the pack and I can’t detect any BOM there. There are some older versions of the plugin in the svn repository which do have a BOM in them — but they aren’t included in that build of the MLP Pack.
Are you using the latest gbp_admin_library?
— Steve
Textile | My plugins on GitHub | @netcarver
Offline