Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 926973
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T19:46:34+00:00 2026-05-15T19:46:34+00:00

I remember when I used to develop website in Japan – where there are

  • 0

I remember when I used to develop website in Japan – where there are three different character encodings in currency – the developers had a trick to “force” the encoding of a source file so it would always open in their IDEs in the correct encoding.

What they did was to put a comment at the top of the file containing a Japanese character that only existed in that particular character encoding – it wasn’t in any of the others! This worked perfectly.

I remember this because now I have a similar, albeit Anglophone, problem.

I’ve got some files that MUST be ISO-8859-1 but keep opening in my editor (Bluefish 1.0.7 on Linux) as UTF-8. This isn’t normally a problem EXCEPT for pound (£) symbols and whatnot. Don’t get me wrong, I can fix the file and save it out again as ISO-8859-1, but I want it to always open as ISO-8859-1 in my editor.

So, are there any sort of character hacks – like I mention above – to do this? Or any other methods?

PS. Unicode advocates / evangelists needn’t waste their time trying to convert me because I’m already one of them! This is a rickety older system I’ve inherited 🙁

PPS. Please don’t say “use a different editor” because I’m an old fart and set in my ways 🙂

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T19:46:34+00:00Added an answer on May 15, 2026 at 7:46 pm

    Normally, if you have a £ encoded as ISO-8859-1 (ie. a single byte 0xA3), that’s not going to form part of a valid UTF-8 byte sequence, unless you’re unlucky and it comes right after another top-bit-set character in such a way to make them work together as a UTF-8 sequence. (You could guard against that by putting a £ on its own at the top of the file.)

    So no editor should open any such file as UTF-8; if it did, it’d lose the £ completely. If your editor does that, “use a different editor”—seriously! If your problem is that your editor is loading files that don’t contain £ or any other non-ASCII character as UTF-8, causing any new £ you add to them to be saved as UTF-8 afterwards, then again, simply adding a £ character on its own to the top of the file should certainly stop that.

    What you can’t necessarily do is make the editor load it as ISO-8859-1 as opposed to any other character set where all single top-bit-set bytes are valid. It’s only multibyte encodings like UTF-8 and Shift-JIS which you can exclude them by using byte sequences that are invalid for that encoding.

    What will usually happen on Windows is that the editor will load the file using the system default code page, typically 1252 on a Western machine. (Not actually quite the same as ISO-8859-1, but close.)

    Some editors have a feature where you can give them a hint what encoding to use with a comment in the first line, eg. for vim:

    # vim: set fileencoding=iso-8859-1 :
    

    The syntax will vary from editor to editor/configuration. But it’s usually pretty ugly. Other controls may exist to change default encodings on a directory basis, but since we don’t know what you’re using…

    In the long run, files stored as ISO-8859-1 or any other encoding that isn’t UTF-8 need to go away and die, of course. 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.