Welcome to WebmasterWorld Guest from 54.227.48.147

Forum Moderators: keyplyr & mack

Message Too Old, No Replies

I destroyed my site with HTML Tidy

Alternatives?

     
5:08 am on Jun 1, 2003 (gmt 0)

Junior Member

10+ Year Member

joined:Jan 4, 2003
posts:106
votes: 0


It was horrible. I've been wanting to convert my old Front Page 2000 generated site into XHTML. I heard that HTML Tidy would do the job for me. So I sat and ran it on every page of my site instead of running it on one and then testing that one page.

Well, it utterly destroyed my site. Thankfully I had not uploaded these "tidied" pages so I was able to download my site from the server so I once again have a site that while messy and not valid at least functions. All the work I had done this week that was not yet uploaded to the server is of course gone now.

I imagine it is a good program and I simply configured it wrong but I still don't want to use it again. Can anyone suggest an alternative?

5:36 am on June 1, 2003 (gmt 0)

Moderator from US 

WebmasterWorld Administrator martinibuster is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Apr 13, 2002
posts:14692
votes: 417


Wow, the hard lessons are the ones we learn the best. Although I use htmlkit, which ports html tidy, I take it's output as a suggestion only.

I had a client with truly horrendous coding problems and this is what I did: I ran it through the w3c validator and cleaned up the errors one at a time, starting with the alt tags and the invalid attributes all the way down to the funky javascript.

Bit by bit, then checking the "look," continually making backups (naming them like this: 052803-1, 052803-2, 052903-1, etc.).

I'm happy that you had a backup!

6:03 am on June 1, 2003 (gmt 0)

Junior Member

10+ Year Member

joined:Jan 4, 2003
posts:106
votes: 0


Now i think it was FP that destroyed my site when I reopened the "tidied" pages with it.

I played with the configuration some more, tidied one page, then opened it with Notepad. It looked good. I then opened it in FP and it was a disaster.

I'm too tired. I'll look at it some more tomorrow.

6:11 am on June 1, 2003 (gmt 0)

Senior Member

WebmasterWorld Senior Member mivox is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Dec 6, 2000
posts:3928
votes: 0


I know FrontPage likes to revert changes to files on the server when it didn't make the changes itself... it may be doing the same thing to the files on your hard drive.

If you are going to "Tidy" the files, you'll probably want to keep those files out of FrontPage afterward, unless you can find a preferences setting that will stop FP from reverting the changes Tidy makes... Hopefully an experienced FrontPage user can point you in the right direction on that. :)

6:28 am on June 1, 2003 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member pageoneresults is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Apr 27, 2001
posts:12172
votes: 61


An upgrade to FP2002 will fix that. When using FP2002, while in html view, right click the page and select apply XHTML formatting rules. Viola, the page will instantly be converted to xhmtl.

I've been testing it for the last couple of weeks, the XHTML feature, and it appears to work flawlessly. I've managed to validate XHMTL 1.0 Strict and now XHMTL 1.1.

I just took an entire site that was valid HTML 4.01 to begin with (75 pages) and did the conversion in less than 30 minutes. Open each page, do the right click routine, save, preview in browser, validate and then move on to the next page. It's a fairly simple process.

Note: Some things you'll need to fix before validating...

1. You'll need the appropriate DOCTYPE of course.

2. You'll need to remove all instances of border="0" from your images. I've still not found a way to stop FP from doing this. In your external css file put this...

img{border:none;}

That will take care of the border issue.

3. If you are using a javascript image rollover that uses the name="imagename" attribute, you won't be able to validate. I'm waiting to find a fix for that one now.

4. All images must have alt tags. Those that don't justify an alt tag should have an empty alt tag (alt=""), that's two quotation marks side by side, no space inbetween.

5. Of course anything that is deprecated will cause errors and you'll need to fix those.

Those are just a few things so far that I am finding. Oh, you won't be able to use FP's form validation scripts as they don't validate and I've dug through just about every config file trying to find a way to change them to no avail. You'll need to find a validation script that passes validation.

10:31 am on June 7, 2003 (gmt 0)

Junior Member

10+ Year Member

joined:Apr 11, 2003
posts:198
votes: 0


Also HTML Tidy is not so bug-free after all. I personally gave up validating xhtml 1.1 documents (some doctype problem).

You might want to check out [sourceforge.net...] for bugs and fixes lists.

10:54 am on June 7, 2003 (gmt 0)

Senior Member

WebmasterWorld Senior Member chiyo is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:June 21, 2000
posts:3170
votes: 0


Well the key thing is what i learned a long time ago. No matter how onerous it is, make a backup, and compress it and put it somehwere else, before implementing any site-wide changes. Rule number 1 in my book now.
10:01 pm on June 9, 2003 (gmt 0)

Senior Member

WebmasterWorld Senior Member g1smd is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:July 3, 2002
posts:18903
votes: 0


When making changes I always keep a before and after version.

If I add a date to the filename, then I use the yyyymmdd order for that, as then the filenames will then also automatically sort into the correct date order.

There is a tool to tidy up Frontpage code. I found it at: [webmaster-toolkit.com...]

Whatever you do it should always be fed through [validator.w3.org...] at some point.

12:13 pm on June 19, 2003 (gmt 0)

Junior Member

10+ Year Member

joined:Apr 6, 2003
posts:74
votes: 0


Hey that's a nice site you found there g1smd ;)