Skip to main content
Jhon Carlo
Inspiring
December 22, 2017
Question

How to format the html code

  • December 22, 2017
  • 2 replies
  • 2450 views

Is there a way to automatically format the html code in dreamweaver?

I mean, for example, select the code and automatically get the right alignment of the code like it is possible do in action script.

Is it possible?

Is there a keyboard shortcut?

Thanks.

    This topic has been closed for replies.

    2 replies

    Nancy OShea
    Community Expert
    Community Expert
    December 22, 2017

    From the Common Toolbar (shown below) select Apply Source Formatting.  However, you must Edit Tag Libraries 1st to set up your indenting preferences.   Personally, I don't like indented code.

    Nancy O'Shea— Product User & Community Expert
    B i r n o u
    Legend
    December 22, 2017

    you're right, when code is indented it is too complex to read it, to clearly see the nested tags, having the starting/ending tag in a first view, well it is definitly better to have a one line code ... arf arf...

    B i r n o u
    Legend
    December 22, 2017

    in fact there are differents current feature requests to polish and greatly improve the code formatting / coloring.

    you can still have a drop down menu Edit > Code that open a child menu to format and indent the code, AFAIK there is not shortcur for it ?

    Jhon Carlo
    Inspiring
    December 22, 2017

    Thank you!

    Yes, but it does not work either with the mouse or with the keyboard.

    B i r n o u
    Legend
    December 22, 2017

    I agree that it really need improvment, but at least for HTML, it is more or less indenting the tags correctly... can you post a screen grab ?