Menu

special characters in HTML

Meshack
2009-03-09
2012-11-13
  • Meshack

    Meshack - 2009-03-09

    For starters, I love Notepad++. I'm trying to work more efficiently in it however, one of the things I find myself doing often is copying and pasting text into the editor while working with HTML, text that is meant to display as copy on a website. When I view the HTML in a browser however, special characters are not translated and display as a diamond with a question mark. I can get around this by encoding the characters as HTML entities, but that is pretty cumbersome for long blocks of text, and the find and replace can get confused with characters like " and ', which are also used in HTML tags and should remain the unchanged.

    So my question is, is there some way to have Notepad++ encode these special characters for me, or is there some other approach I can use to accomplish the same thing.

    Thanks!!

     
    • Allen Zhu

      Allen Zhu - 2009-03-10

      I had that problem before when I was quick fixing digiclub.org.

      Except, the problem was that W3C's online validator kept telling me that there were special characters in my HTML file when it displayed properly...

      Try:

      Going to Format and selecting Convert to UTF-8 without BOM

      And try again, which made W3C happy and the page layout and text still looks the exact same.

      If you want, do a Google for BOM and you'll get what that is...

      Allen