Skip to main content
Participant
November 12, 2018
Answered

Formatting code question

  • November 12, 2018
  • 2 replies
  • 920 views

This is probably a simple question. Is it possible to set Dreamweaver to add a extra, indented line when I press enter between opening and closing html tags? Such as, say I am entering a table. I enter the following:

    <table></table>

Right now, if I press enter between the tags, I get the following:

    <table>

    </table>

What I would like to get is:

    <table>

        Indent to here

    </table>

I would like this to happen with any tags. Any help is appreciated.

This topic has been closed for replies.
Correct answer Paul-M

I think the short answer is the code formatting option isn't working 100% as it should in Dreamweaver

I tested at my end with Dreamweaver CC 2019 (on Windows 10) and get the same result as you. If you look on the uservoice website you'll see that there have been niggles and issues with Dreamweaver's code formatting option since CC2017 when Brackets was embedded into Dreamweaver as its new code editor.

My advice is report it to Adobe Support and/or post on the uservoice website.

2 replies

Paul-MCorrect answer
Legend
November 14, 2018

I think the short answer is the code formatting option isn't working 100% as it should in Dreamweaver

I tested at my end with Dreamweaver CC 2019 (on Windows 10) and get the same result as you. If you look on the uservoice website you'll see that there have been niggles and issues with Dreamweaver's code formatting option since CC2017 when Brackets was embedded into Dreamweaver as its new code editor.

My advice is report it to Adobe Support and/or post on the uservoice website.

Paul-M - Community Expert
Participant
November 14, 2018

Thanks for the response. I was afraid something like this may be the problem. I reported a bug on the Uservoice site, and will update this if I hear anything.

Until then, I am going back to using Aptana. It may be a minor thing, but it slows me down if I have to go through formatting my code myself, and I have enough to do that I don't want to be slowed down.

Nancy OShea
Community Expert
Community Expert
November 12, 2018

Go to Edit Tag Library to set up your code formatting rules.  You can reach it from the Apply Source Formatting tool.  See screenshots.

Nancy O'Shea— Product User & Community Expert
Participant
November 13, 2018

Thanks for the reply, but I already had that set, and I am still not getting the extra line and indenting between the tag. When I close the opening tag, it creates the closing tag with the cursor between the tags, but when I press enter, it just moves the closing tag down to the next line without creating and indenting the next line. See the screenshots below.

Nancy OShea
Community Expert
Community Expert
November 13, 2018

Paste this code and hit  Apply Source Formatting.

<body>

<table>

<tr>

<td></td>

</tr>

</table>

</body>

After formatting, it should resemble this:

<body>

    <table>

        <tr>

            <td></td>

        </tr>

    </table>

</body>

Nancy O'Shea— Product User & Community Expert