So, if I have typed
Once I’ve closed the file, it’s changed to
It will do this for all the tags: onload, onblur, onfocus, etc…
I’ve tried setting my default document type, the validation fallback, everything I could find to XHTML 1.0 Strict, which requires lowercase attributes, but Dreamweaver isn’t smart enough to realize that I mean for this to apply to all of my files, even .php includes.
Finally, I’d had enough and started looking for a solution. I found two different ways of getting this done.
First method: click on Edit -> Preferences -> Code Format. Change “Default tag case” to lowercase, “Default attribute case” to lowercase=’value’, and in “Override case of”, place checkmarks next to Tags and Attributes.
You can also modify each of these attributes in the Tag Library Editor.
Second method: click on Edit -> Preferences -> Code Hints, and under the Menus area, click on the Tag Library Editor link.
A Tag Library Editor window will open. If you wanted to change the body’s onload attribute, for example, you would expand the HTML folder, then the body folder. Highlight onLoad and in the “Attribute case:” menu, select Lowercase, then click “Set default”.
At long last, valid XHTML code from Dreamweaver, even if I shouldn’t be using body onload and inline event handlers in the first place.