How to keep Byte Order Marks from files?

Closed Office

Verified User
Joined
May 9, 2008
Messages
17
Location
Calgary, Alberta
The html, css and xml pages I upload all have these 3 (let's face it they're weird) characters right at the beginning of the file after they are uploaded. "" It doesn't matter which text editor I use, notepad, notepad++ (Also I believe Netbeans and PS Pad, but can't remember for sure).

Google does have info about them, but none of it seems to help with this problem.

After they are uploaded either by ftp or by the DA upload, I have to go through every file and delete these 3 characters. Is there any setting I can modify to save this unproductive job? The pages are saved when I work on them as UTF-8.

just hoping,
../lloyd
 
I use PSPad all the time so I can help you with that app, but it's pretty much the same in others.

Go to Settings -> Program settings -> Program (Part2) and uncheck Ident. bytes in UTF-8 coding

OK I just checked PS Pad and that part is unchecked, just by default as I had never wandered there. So I uploaded a file that was already saved in PS Pad and sure enough, those strange characters were right at the start again. In other words that didn't work.

Notepad++ has an option to save files as 'UTF-8 without BOM' and that works but it is really touchy. When I have that selected the file reverts back to ANSI at every possible chance and I have to keep watching and switching it back.

I did see the wikipedia entry while looking around and enough other info about byte order marks, but just nothing that would help with this problem. Anyway thanks for the suggestion, learned something about PS Pad.

lloyd
 
PS jazzman, under Format in PS Pad, do you have UTF-8 selected, and you upload without those characters showing up? That would be interesting if you do.

Notepad default saves to ANSI (I have no idea why) but I suppose a lot of people just go with that and just by accident it saves this pain in the neck? Have been dealing with it now for 2 years with 4 different editors, still baffled.
 
The only time I have seen this is when using Expression Web. Here are the instructions for removing it in EW. I know you don't use EW but you might find something useful anyway that is related. I think it has to do with the meta tag you might have in your file.
 
I use PSPad all the time so I can help you with that app, but it's pretty much the same in others.

Go to Settings -> Program settings -> Program (Part2) and uncheck Ident. bytes in UTF-8 coding[/url]

OK I got it, thanks for the help jazzman. The page I uploaded in my last post was open in PS Pad and didn't need saving, so I just assumed it was good to try. Turns out it must have been changed in Notepad++.

When I tried again, changing a page in PS and then uploading it, that worked, without the marks, so guess I'll be using it a lot more now.

It's too bad about Notepad++, I really like it otherwise.

And thanks for the comment floyd. You never know when the smallest bit of communication is going to help with a problem. In fact I've got a story about that, but that's another blog post :)

Solved for now I think but I reserve the right to get back here if anything needs a bit more finesse.

best wishes,
lloyd
 
Back
Top