Auto-formatter doesn't break up HTML tags properly [message #1448396] |
Sun, 19 October 2014 22:45 |
Dave H Messages: 43 Registered: January 2010 |
Member |
|
|
I use Eclipse's Ctrl+Shift+F auto-formatter to make code easy to edit, but it can fudge up HTML as much as it cleans it up (NetBeans is better in some ways and worse in others). It also seems to break up tag content randomly by attributes; I've gone through settings and can't figure out how to make it format sensibly.
For instance:
<label for="form_URL">Website</label> <input id="form_URL" maxlength="80" name="URL" size="20" type="text" /> <label
for="form_industry">Industry</label> <select id="form_industry" name="industry">
<option value="">- none -</option>
It put four separated tags on the same line: the label tag, then the input tag then the following label tag, then the following select tag. These were all on different lines in the original code (formatted from WordPress), even one separated by two newlines. Nothing I do puts them on their own lines sensibly. All of the option values remained on their own lines indented properly.
Here's how it looked taken from the WordPress "Text" editor:
<label for="form_URL">Website</label>
<input id="form_URL" maxlength="80" name="URL" size="20" type="text" />
<label for="form_industry">Industry</label>
<select id="form_industry" name="industry">
<option value="">- none -</option>
Can someone explain why it's doing this or how to fix it?
[Updated on: Sun, 19 October 2014 22:49] Report message to a moderator
|
|
|
|
Powered by
FUDForum. Page generated in 0.04015 seconds