How do I save HTML files from TextEdit?
I am new to the Mac world and I have started with Tiger. When I use the textedit program to type HTML code and save it as an HTML document all I see is the code when I open the file in any of the browsers that I use. Unlike Notepad in Window, why can't I see the results of my code in a web page? I am completely lost and have combed the Internet. The simple Text Editor program in the older versions of the Mac OSs' seemed to work just like Notepad in Windows. Please let me know what I am doing wrong.
Just as with NotePpad on the PC, there's a bit of a trick to getting TextEdit to save HTML files properly, and it's all to do with the filename extension.
Yes, we're now deep into the 21st Century, but computer operating systems still basically work like early DOS machines: If you have the wrong filename extension, either your OS itself won't understand it or your Web browser will be convinced that even though it looks like HTML inside it's really just plain text to show as-is.
In TextEdit, you'll type in some HTML and have a window that looks like this:
This is not good because the program wants to work with Rich Text Format, not plain text (the ruler is the giveaway). To fix that, go to Format --> Make Plain Text and, voila! It'll look like this:
Now, almost done (and you only have to go through this once: once the file is properly named, TextEdit will remember for future edit sessions). Choose File --> Save As... and type in a filename that includes a ".html" filename extension:
Looks good. Click on "OK", though, and now you get this:
Click on "Use .html" and, finally, you're done!
Yes, it's a bit of a pain, but, as I said, you only have to do this once, when you first save the file, and from then on, it'll work transparently.
More Useful Mac OS X Help Articles:
✔ Audacity can't find LAME library, I can't save Mp3?
Hey Dave. I read your article Audacity can't save mp3 audio files and am still puzzled because I downloaded the LAME Mp3 converter...✔ How to remove Dashboard as a "space" in Mac OS X Spaces?
I'm a big fan of the Spaces utility in Mac OS X that lets me have multiple virtual screens [see Set Up Mac...✔ Best place to buy a cheap MacBook laptop?
Hi Dave. I am looking for two gently used MacBook laptops for my teen daughters. Personal computers would greatly facilitate their studies as...✔ File too big error copying to USB flash drive on my Mac?
I'm baffled. I have a 16GB Kingston USB flash drive that I use on my Mac system and I'm trying to copy a...✔ Stealth image capture photo from webcam on my Mac?
Someone sneaks into my cubicle while I'm at lunch and takes candy out of my desk. Petty, but stupid too. I want to...
Let's stay in touch!
Sign up for my weekly AskDaveTaylor Newsletter and you'll receive even more tech and gadget help right to your inbox, along with exclusive news and industry updates. It's good stuff. I promise!
I do have a comment, now that you mention it!
Check This Out Too...
Look for Answers
All Our Categories
Apple iPad Help
Articles and Reviews
Auctions and Online Shopping
Blogs and Blogging
Building Web Site Traffic
Business and Management
Computer and Internet Basics
d) None of the Above
Google Gmail Help
Google Plus Help
Industry News and Trade Shows
iPhone and Cell Phone Help
iPod, Sony PSP and MP3 Player Help
Kindle Fire Help
Mac OS X Help
Pay Per Click (PPC) Advertising
Search Engine Optimization (SEO)
Shell Script Programming
Tech Support Video Help
The Writing Business
Twitter, LinkedIn and Social Network Help
Unix and Linux Help
Video Game Tips and Help
Windows PC Help
Find Me on Google+
ADT on G+