Looking for the right HTML editor

Joined
Jan 29, 2011
Messages
9
Reaction score
0
Points
1
Location
Sunny Caribbean
Your Mac's Specs
iMac 21.5 3.06GHz Intel Core Duo 4Gb 1067MHz DDR3
I'm switching to MAC and am having trouble finding a text editor for HTML that deals with character encoding other than UTF-8. I searched the forum and did find several HTML or Text editors that look very interesting and capable, but digging deep into the features I haven't found one that can convert character encoding. On Windows I used Notepad++ and sometimes PSPad, but neither has a Mac version. I have read that it is possible to use Notepad++ with Wine or DarWine, but can't find details of how that works. I downloaded Wine but haven't figured it out. I don't mind converting my sites to UTF-8, but when I have tried in TextEdit and TextWrangler, they open and save in utf-8, but don't actually convert the character encoding, it produces a mess. It does not convert from ISO-8859-1 to UTF-8, it just saves the existing text as UTF-8. If it was a page or two I would just start over, but there are thousands of pages that need editing from time to time. Has anyone here gone through this mess before?
 
Joined
Mar 30, 2004
Messages
4,744
Reaction score
381
Points
83
Location
USA
Your Mac's Specs
12" Apple PowerBook G4 (1.5GHz)
It's hard to say, since you don't describe what exactly you're trying to do or what kind of "mess" you're ending up with.

I can assure you that there are plenty of good Mac text editors, including TextWrangler, that can open, save, and convert just about any text encoding, including UTF-8 and ISO-8859-1, perfectly well.
 
OP
Macata
Joined
Jan 29, 2011
Messages
9
Reaction score
0
Points
1
Location
Sunny Caribbean
Your Mac's Specs
iMac 21.5 3.06GHz Intel Core Duo 4Gb 1067MHz DDR3
My sites are encoded in ISO-8859-1. Ideally, these html files could be opened and edited and saved in the same text encoding that they have but if necessary I will change each file as it is opened and save it as UTF-8.

In TextWrangler, the first html page I opened was instantly converted to UTF-8 but the Doctype was altered and all my html became html entities with "apple spans" inserted in the whitespace. The page had the proper Doctype declaration and to change that I would need to alter the page and the CSS which I wasn't planning to do for each of these pages. That is the mess I am referring to. Here is the first few lines:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="Content-Style-Type" content="text/css">
<title></title>
<meta name="Generator" content="Cocoa HTML Writer">
<meta name="CocoaVersion" content="1038.32">
</head>
<body>
<p class="p1"><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"></p>
<p class="p1"><html></p>
and
<p class="p1"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><link rel="shortcut icon" href="<a href="view-source: favicon.ico"><span class="s1">favicon.ico</span></a>"></p>
<p class="p1"><span class="Apple-tab-span"> </span></head></p>
<p class="p1"><span class="Apple-tab-span"> </span><body></p>

It is as if the program assumed that my html file was RTF and converted tags to character entities as in < becomes <. The terminology for character encodings seems to be proprietary, I never heard of the names in the list for preferences. I took a guess and selected ISO-Latin-1 for the format to open and kept the UTF-8 as the format to save.

I see there is a new version of TextWrangler available today so until I try that, I am not giving up. I can see why it is a strong temptation to run Windows on Mac though, just so you can keep on using familiar tools and get the job done.
 
Joined
Mar 30, 2004
Messages
4,744
Reaction score
381
Points
83
Location
USA
Your Mac's Specs
12" Apple PowerBook G4 (1.5GHz)
Pretty sure you're confusing TextWrangler with TextEdit.

TextEdit has several modes, one of which is a (very limited) WYSIWYG HTML editor which may well do what you're describing.

TextWrangler is a pure text editor, which is what you're looking for.
 
Joined
Jan 14, 2005
Messages
2,078
Reaction score
155
Points
63
If you're looking into something more (a lot more) powerful: TextMate is my editor of choice. It's a bit pricey, though.
 
OP
Macata
Joined
Jan 29, 2011
Messages
9
Reaction score
0
Points
1
Location
Sunny Caribbean
Your Mac's Specs
iMac 21.5 3.06GHz Intel Core Duo 4Gb 1067MHz DDR3
Text Edit is the first one I tried before I looked at Text Wrangler, it was a few months ago that I wrote off TextEdit. It is not impossible that the example I pasted was that result and not from TextWrangler since I didn't take notes. I downloaded the new TextWrangler today and it still has the strange names for character sets but I did not have the same problem I had before. It was about 6 months ago that I first tried these tools before I took the easy way out and went back to an old peecee until its hard drive died last week. I also found a pdf user's manual for TextWrangler that should make a difference.

In a few years I might get around to try all the tools I have found so far for Mac, I was just kind of hoping to get some recommendations from people who use some of them. BBEdit looks like it has more of the features I use, I will take a look at TextMate. Free is nice, but I don't mind buying useful tools.
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top