Hi all, just wondering if anyone here can help me out with a headache that Dreamweaver CS3 is causing me, when i write my HTML i have a certain way of laying it out so that i can quickly look it up and down and find any problems (not that i ever have any problems with my code, honest, lol) that might crop up while i'm building a site.

For example:
<div id="container">
<ul>
<li>
<a class="gallery g001">
<span>
</span>
</a>
</li>
</ul>
</div>

However, it seems now that whenever i go and edit my CSS on another page and return to my HTML Dreamweaver goes and rearranges it so it is all displayed in a straight line:

<div id="container"> <ul> <li> <a class="gallery g001">
<span> </span> </a> </li>

It might not seem like much to some of you here but it is very annoying for me, i cannot read that, it looks like junk to me, is there any way of disabling this annoying habit of Dreamweaver? i've tried using Dreamweavers Help option and Google but i cannot find the right keywords to locate a solution...

Dani AI

Generated

This is the formatter at work. Dreamweaver can (and by default sometimes does) reflow HTML to match its built‑in code‑formatting rules, which turns nicely indented, hand‑written markup into a compressed single line that’s hard to read. The change usually happens when the formatter runs automatically (for example when files are saved or when views are switched) or when a cleanup/format command is applied behind the scenes.

Quick, safe steps to stop it:

  • Make a copy of the file so you can test without risk.
  • Open Dreamweaver’s preferences and look for the code formatting / source formatting options. Disable any “auto‑format” or “format on save” type settings and enable anything that mentions preserving existing line breaks or wrapping attributes the way you prefer. Search the prefs for words like format, tidy, wrap or preserve if you can’t spot the exact control.
  • Test with the copy (save, switch views) to confirm the formatter no longer runs automatically.

If you can’t get preferences to behave, change workflow instead of battling the app: work in Code View only, edit pages in an external text editor and import/save the files back into Dreamweaver, or use a dedicated formatter/validator that you control so formatting happens when you want it. Keep files under version control or keep backups so you can see diffs and restore your preferred layout instantly.

As pointed out, the preference area is where to look. Given the other replies (, , ) recommending alternative editors or older versions, switching editors is a reasonable fallback if CS3 won’t stop reformatting. If further diagnosis is needed, share a small before/after diff and a screenshot of your code‑formatting preferences so the exact offending option can be identified.

Recommended Answers

All 5 Replies

Edit>Preferences(ctrl+U)>Code Format.

Mess around with it still you happy.
hope it helps

hi

Don't use Dreamweaver?

Or use Dreamweaver 8 - I've found too many annoying issues with CS3!

I know you have already spent money on dreamweaver but you can try html-kit by chami it's free

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.