Can Dreamweaver automatically re-format existing code?, Cleaning up an HTML block with auto-indenting to indicate nesting... |
![]() ![]() |
Can Dreamweaver automatically re-format existing code?, Cleaning up an HTML block with auto-indenting to indicate nesting... |
Sep 23 2008, 12:17 PM
Post
#1
|
|
|
Member ![]() ![]() Posts: 64 OS: Windows XP home |
I've inherited a mess of a website. It seems to have been built with an old WYSIWYG editor that wrote code kind of randomly, and it's hard to read through. Does anyone know if there's an option in DW CS3 that will automatically fix this, and create a series of indentations based on the nesting of different elements? It's a small thing, but would sure be convenient. I know DW will auto-indent new code that I write, I'm just curious about pre-exising stuff like this. Thanks, Joe |
|
|
Sep 23 2008, 01:06 PM
Post
#2
|
|
![]() Trusted Techie Posts: 4,632 From: Now in a MEMA (Katrina) Cottage OS: Win XP/Vista Home Premium. Backup PC: Commodore 64 with 300 baud modem! |
Dreamweaver is not much at correcting code to HTML 4.01/CSS 2.1 Standards. You might try HTML Tidy found in some of the free HTML Editors, but if the errors are really bad, you will have to do those by hand.
You might use the following validators to get an idea of coding errors: HTML Validator CSS Validator Link Checker Use the "More Options", "Verbose" output where available. |
|
|
Sep 23 2008, 02:37 PM
Post
#3
|
|
|
Member ![]() ![]() Posts: 64 OS: Windows XP home |
Thanks Major... it's not so much syntax I was wondering about correcting, but the actual structure of the code. This stuff actually mostly validates, with just a few errors I'm working my way through. The syntax is ok... the code is just scattered everywhere. I was hoping there was something to re-order it into readable chunks, with indenting showing the nesting of elements. If not, no big deal, I'll survive.
Thanks... Joe |
|
|
Sep 23 2008, 03:31 PM
Post
#4
|
|
![]() Trusted Techie Posts: 4,632 From: Now in a MEMA (Katrina) Cottage OS: Win XP/Vista Home Premium. Backup PC: Commodore 64 with 300 baud modem! |
I re-order mine using Copy/Fine/Replace function in my HTML Editor when a page's code is all over the place. Where I can't use that method, then I take it line by line using the Delete button until code is blocked out to where it is readable. All this has to be done manually although you could try HTML Tidy and let it correct/restructure the code for you. I don't really like the way HTML Tidy corrects code, but it is better than nothing.
This post has been edited by Major Payne: Sep 23 2008, 03:31 PM |
|
|
Sep 23 2008, 03:37 PM
Post
#5
|
|
|
Member ![]() ![]() Posts: 64 OS: Windows XP home |
Thanks, I'll check it out.
|
|
|
Sep 23 2008, 04:43 PM
Post
#6
|
|
![]() Trusted Techie Posts: 4,632 From: Now in a MEMA (Katrina) Cottage OS: Win XP/Vista Home Premium. Backup PC: Commodore 64 with 300 baud modem! |
You're welcome. Give a shout if you need more info concerning this problem.
|
|
|
![]() ![]() |
Similar Topics
| Topic Title | Replies / Views | Topic Information | |||||
|---|---|---|---|---|---|---|---|
![]() |
4 / 231 | 12th February 2007 - 01:53 AM hafizik started - last by hafizik |
|||||
![]() |
0 / 210 | 28th November 2007 - 07:47 PM stettybet0 started - last by stettybet0 |
|||||
![]() |
11 / 502 | 6th December 2007 - 10:28 AM mrtypr started - last by The Skeptic |
|||||
![]() |
2 / 106 | 31st December 2008 - 07:55 PM Jak6 started - last by Jak6 |
|||||
|
Time is now: 7th January 2009 - 07:40 PM |
| Advertisements do not imply our endorsement of that product or service. The forum is run by volunteers who donate their time and expertise. We make every attempt to ensure that the help and advice posted is accurate and will not cause harm to your computer. However, we do not guarantee that they are accurate and they are to be used at your own risk. |