Monday, August 13, 2012

AppleScript fun: Previewing HTML from TextWrangler


If you edit HTML code on your Mac, you might find that Apple's text-handling programs like TextEdit may not suffice, especially since as a basic text editor it does not provide syntax-aware coloring, the option to collapse sections of code based on tags, and properly index lines of code. In addition, TextEdit relies on direct access to files from the Finder and cannot open remote files.


As a result of these limitations, alternative text-handling tools may be useful for managing HTML documents; one of the most popular is Bare Bones Software's TextWrangler (a free version of its powerful BBEdit package). This software allows you to open remote files using either FTP or SFTP protocols, and manipulate structured text in ways that are very convenient for coders; however, one limitation of the software is it does not have an option to preview relevant code in handling programs. For instance, if you create an HTML document, you may wish to preview your changes to ensure that your code is working as expected; to do so now you have to save the file and then open it directly in a browser like Safari that supports loading HTML from the file system.


As a result of this, to preview a file you will need to first set up Safari to open the HTML file on disk, and then when you save changes in TextWrangler you will need to refresh the browser to preview them. While not a difficult setup, it d... [Read more]



via CNET http://feedproxy.google.com/~r/cnet/NnTv/~3/3voo3Dhn9Rs/


No comments:

Post a Comment