Copy link to clipboard
Copied
why the code dont auto indent in dreamweaver i use the latest cs6, as an example the table code below it
should indent the tr tag some spaces more than the parent table tag but it dont i need to do it manually so am i missing something ?
<table>
<tr>
<td>15</td>
<td>15</td>
<td>30</td>
</tr>
<tr>
<td>45</td>
<td>60</td>
<td>45</td>
</tr>
<tr>
<td>60</td>
<td>90</td>
<td>90</td>
</tr>
</table>
Copy link to clipboard
Copied
Edit > Preferences > Code Format
Make sure the Indent box is checked.
Copy link to clipboard
Copied
Hi
this otion is checked already and below is the code i get
<body>
<table>
<th></th>
</table>
</body>
</html>
Copy link to clipboard
Copied
Sorry, don't know any other settings.
For me, if I check that option, I get indented code.
If I don't check it, the code is left aligned.
Copy link to clipboard
Copied
Edit > Preferences > Code Format > hit Tag Library button for advanced features. See screenshot:
Code formatting changes won't effect your exisiting code. Only works on new code.
Nancy O.
Alt-Web Design & Publishing
Web | Graphics | Print | Media Specialists
Copy link to clipboard
Copied
With CS5 is the same, non of these settings have worked, but go to:
C:\Program Files (x86)\Adobe\Adobe Dreamweaver CS5\configuration\Commands\TableCommands.js
and 39-41 lines add some spaces bofere <
var tableCells=' <'+'TD>' + theNBSP + '<'+'/TD>\n';
var tableScopeRowCells=' <'+'TH>' + theNBSP + '<'+'/TH>\n';
var tableScopeColCells=' <'+'TH>' + theNBSP + '<'+'/TH>\n';
this have worked, but if you try to insert new row <td> is not indented:
<table cellspacing="0" cellpadding="0">
<tr>
<th> </th>
<th> </th>
</tr>
<tr>
<td> </td>
<td> </td>
</tr>
<tr>
<td>new row</td>
<td>not indented</td>
</tr>
</table>
and didnt have found how to fix insert new row (below or above same is not indented).
Copy link to clipboard
Copied
Just go into Preferences, Code Formating, and then the Tag Libraries. Find the TAG and change the line break setting to add line breaks for the before, inside, or after conditions.
After making the change, in Code View click: Format Source Code.