I'm currently working on a redesign of a client's website. The site I'm designing will use only valid, XHTML-compliant, CSS-driven code. The site they have now definitely doesn't.
Last night, whle I was copying and pasting their existant content, remmoving <font> tags, adding missing tags, etc., I had an idea. I remembered that WordPRess uses something called Textile to format posts. Textile is published by Dean Allen and touts itself as "A Humane Web Text Generator." In its most-basic sense, it takes plain text and wraps paragraph tags wherever it sees a skipped line. It also converts illeagal characters, like angle brackets and quotes into their entity codes (&####;). The nice thing about Textile is that is is smart enough to know what is already HTML and it leaves it alone. Therefore, this text:
won't becomeCode:Check out <a href="http://www.jaguarpc.com">JaguarPC</a>
So anyway, back to last night...instead of copying the messy HTML code from their pages, I simply started copying text from the browser to paste into Textile. Then I just had to click a button and I got perfect XHTML! Yes, I lost my links and formatting, but luckily there aren't many links and most of the formatting I didn't really care about, so it was easy to add that stuff back in when necessary.Code:<p>Check out <a href="http://www.jaguarpc.com">JaguarPC</a></p>
If you build sites for clients or for yourself and you care about keeping your code valid, check out Textile: http://www.textism.com/tools/textile/index.html
--Jason


LinkBack URL
About LinkBacks



Reply With Quote
Bookmarks