1 amoun Jun 29, 2019 20:26
3 amoun Jul 07, 2019 23:30
Hi @fplanque
- I never use WYSIWYG
I have just gone back to the post to edit it and removed all spaces and new lines, I usually have each item on a new line.
<ul><li><strong>May 20th</strong> From <span class="MT_yellow_back">62.5671</span> to 63.8371. First use this year. Only 20ml diff from last record (yellow)</li><li><strong>June 28/29th</strong> From <span class="MT_yellow_back">63.8376</span> to 65.7269. Left tap on for 24hrs. and although 2m<sup>3</sup> have been used I doubt I used even 1m<sup>3</sup></li><li><strong>June 28/29th</strong> From <span class="MT_yellow_back">63.8376</span> to 65.7269. Left tap on for 24hrs. and although 2m<sup>3</sup> have been used I doubt I used even 1m<sup>3</sup></li></ul>
and everything is fine, but I noticed in removing all the spaces and new lines that there was a new line before the closing tag of second list item. I have replicated it in the next code.
<ul><li><strong>May 20th</strong> From <span class="MT_yellow_back">62.5671</span> to 63.8371. First use this year. Only 20ml diff from last record (yellow)</li><li><strong>June 28/29th</strong> From <span class="MT_yellow_back">63.8376</span> to 65.7269. Left tap on for 24hrs. and although 2m<sup>3</sup> have been used I doubt I used even 1m<sup>3</sup>
</li><li><strong>June 28/29th</strong> From <span class="MT_yellow_back">63.8376</span> to 65.7269. Left tap on for 24hrs. and although 2m<sup>3</sup> have been used I doubt I used even 1m<sup>3</sup></li></ul>
This new line before the closing tag </li> makes that list item seem like a new paragraph to Auto P somehow.
I haven't done a screen shot of the back office editor as it seems clear where the issue lies, and the Auto P is checked.
Hope this reply is ok though not exactly what you asked for.
So this code is fine.
<ul>
<li><strong>May 20th</strong> From <span class="MT_yellow_back">62.5671</span> to 63.8371. First use this year. Only 20ml diff from last record (yellow)</li>
<li><strong>June 28/29th</strong> From <span class="MT_yellow_back">63.8376</span> to 65.7269. Left tap on for 24hrs. and although 2m<sup>3</sup> have been used I doubt I used even 1m<sup>3</sup></li>
</ul>
and this causes and indent.
<ul>
<li><strong>May 20th</strong> From <span class="MT_yellow_back">62.5671</span> to 63.8371. First use this year. Only 20ml diff from last record (yellow)</li>
<li><strong>June 28/29th</strong> From <span class="MT_yellow_back">63.8376</span> to 65.7269. Left tap on for 24hrs. and although 2m<sup>3</sup> have been used I doubt I used even 1m<sup>3</sup>
</li>
</ul>
4 fplanque Jul 07, 2019 23:45
Clearly, having a newline at that position is not something we are trying to support in the Auto P plugin.
Again the Auto P plugin is primarily designed for plain text and supports a little bit of cooperative HTML. Putting a newline before a closing tag when there is none after the opening tag is definitely not cooperative HTML.
5 amoun Jul 07, 2019 23:46
The source code for the indented case, via Firefox > Developer >Source code is:
<ul>
<li><strong>May 20th</strong> From <span class="MT_yellow_back">62.5671</span> to 63.8371. First use this year. Only 20ml diff from last record (yellow)</li>
<li><p><strong>June 28/29th</strong> From <span class="MT_yellow_back">63.8376</span> to 65.7269. Left tap on for 24hrs. and although 2m<sup>3</sup> have been used I doubt I used even 1m<sup>3</sup></p>
</li>
</ul>
So Auto P adds a paragraph when the closing tag is on a new line.
6 amoun Jul 07, 2019 23:48
Clearly, having a newline at that position is not something we are trying to support in the Auto P plugin.
Again the Auto P plugin is primarily designed for plain text and supports a little bit of cooperative HTML. Putting a newline before a closing tag when there is none after the opening tag is definitely not cooperative HTML.
It wasn't intentional just another example of my untidiness.
Thanks for helping me keep on the case.
7 fplanque Jul 07, 2019 23:49
ditto; same answer as above ;)
8 amoun Jul 08, 2019 00:38
Just thinking about it a bit more and I know where it comes from.
Way back in the 90's all tags had an ending tag on a new line at the same indentation as it was easier to follow where tags ended, rather than following lines of text to see where and if there was one.
<html>
<head>
</head>
<body>
<ul>
<li>
Some text.
</li>
<li>
<ol>
<li>
Item 1
</li>
<li>
Item 2
</li>
</ol>
</li>
</ul>
</body>
</html>
@amoun please screenshot the backoffice editor when editing this.
Show if you are in WYSIWYG or Markup mode.
Then please switch to Markup mode and copy paste the whole source into a
[code block lang="markup" line="1"]...[/codeblock]
here.(when you do it, remove space between
[code
andblock
)