问题
is there any quick and easy way to convert code from looking like this:
<style>
element { property:value; property:value;
property:value;
property:value; }
element { property:value; property:value; property:value; property:value; property:value; }
element {property:value; property:value; property:value;
property:value;
property:value; property:value;
}
</style>
<div>
content content content <div> content </div>
</div>
to being nice and neat like this:
<style>
element { property:value; property:value; property:value; property:value; }
element { property:value; property:value; property:value; property:value; }
element { property:value; property:value; property:value; property:value; }
</style>
<div>
content content content
<div>
content
</div>
</div>
it would also make life easier if there was a button to put css in alphabetical order
回答1:
See these similar questions / answers:
Is it possible to auto-format your code in Dreamweaver?
dreamweaver CS5 code formatter
I do not have Dreamweaver installed myself, but according to this answer the following commands should be available:
- Commands > Apply Formatting
- Commands > Clean up HTML
回答2:
Try:
Command -> Apply Source Formatting
来源:https://stackoverflow.com/questions/12340396/how-to-make-code-neater-in-dreamweaver