22i design - web design Farnborough

Monday, October 06, 2008



This page uses Valid CSS
Valid HTML 4.01!
For what it's worth, 22i design is a member of the UKWDA
Get FireFox - The Browser ReLoaded



22i DESiGN » Design Blog » Design Blog: HTML Tidy

Tuesday, September 19, 2006

HTML Tidy

A great item for any designer's toolbox is the HTML or Tidy Online.

Whilst shifting thousands of pages of legacy HTML code from one system to another (flat, individual HTML pages to Content Management System (CMS)) I found that numerous people had hacked the code over a period of 5 years...

...and HTML tidy made "cleaning" the code a little easier.

What this was particularly handy for was for placing readable HTML code in a WYSIWYG or online text editor window ni the browser-based CMS. Being able to wrap the text to 72 characters meant it is so much more easy to manage in the CMS.

Oh, and if you're using CMS like Joomla then don't forget to save the HTML files to a source folder and when pasting the new code into the interface, remove all the code before, after and inclusive of the body tags.

Advantages of HTML tidy
  • Indents Code
  • Export to XHTML
  • Limits the text wrap (default 72 chars)
  • Provides Error reporting
Disadvantages
  • Strips HTML special character coding unless you use the ASCII-friendly HTML Tidy from infohound
  • Can add extra kilobytes to the eventual file
  • Watch out for {mospeagebreak} commands in Mambo and Joomla - if you split those command lines they do not read in the CMS!
  • PDF-printouts in Joomla! will be literal - a 72 character wrap of your HTML will produce narrower Joomla PDF output!

0 Comments:

Post a Comment

Links to this post:

Create a Link

<< Home