Bug 1707360 Comment 1 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

Vielen Dank, WaltiS!

Confirming exactly as reported, tested on 78.10.0 (32-bit).
Indeed, links with long URLs having spaces are seriously broken - cunning!
From an end user perspective, also wearing my enterprise hat, I consider this a serious UX fail for an everyday scenario (P2/S2).

**Reduced STR:**

1) Compose HTML message
2) Insert > Link (Ctrl+K), Link Text: `long test link`, Link Location (long URL with space):
https://www.124spiderclub.ch/veranstaltungen/2021/124 Spiderclub Einladung Jubilaeum Wallis.pdf
3) For comparison, short URL:
Insert > Link (Ctrl+K), link text: `test link`, Link Location (short URL with space):
http://www.example.com/foo bar.pdf
4) Send Later (Ctrl+Shift+Enter)
5) Check sent msg source in Outbox

**Actual result:**

*long URL with space fails (due to source formatting: `href` split up with line break and indent)*
```
    <a moz-do-not-send="true"
      href="https://www.124spiderclub.ch/veranstaltungen/2021/124
      Spiderclub Einladung Jubilaeum Wallis.pdf">long test link</a><br>
    <br>
```

*short URL with space works (`href` on a single line)*
```
    <a moz-do-not-send="true" href="http://www.example.com/foo bar.pdf">test
      link</a><br>
    <br>
```

**Expected result**

- link with long URL with space must be preserved correctly so that it renders correctly for message recipient

**Analysis**

Apparently the reason is that Thunderbird will format the source with indents and tries to keep line length at average, then the href="foo bar" attribute is broken across two lines and indented without escaping or otherwise indicating that there's a space which still belongs to the URL.
The erroneous extra spaces are exactly the 6 indent spaces after the linebreak inside the href attribute.
Vielen Dank, WaltiS!

Confirming exactly as reported, tested on 78.10.0 (32-bit).
Indeed, links with long URLs having spaces are seriously broken - cunning!
From an end user perspective, also wearing my enterprise hat, I consider this a serious UX fail for an everyday scenario (P2/S2).

**Reduced STR:**

1) Compose HTML message
2) Insert > Link (Ctrl+K), Link Text: `long test link`, Link Location (long URL with space):
https://www.124spiderclub.ch/veranstaltungen/2021/124 Spiderclub Einladung Jubilaeum Wallis.pdf
3) For comparison, short URL:
Insert > Link (Ctrl+K), link text: `test link`, Link Location (short URL with space):
http://www.example.com/foo bar.pdf
4) Send Later (Ctrl+Shift+Enter)
5) Check sent msg source in Outbox

**Actual result:**

- *long URL with space fails (due to source formatting: `href` split up with line break and indent)*
```
    <a moz-do-not-send="true"
      href="https://www.124spiderclub.ch/veranstaltungen/2021/124
      Spiderclub Einladung Jubilaeum Wallis.pdf">long test link</a><br>
    <br>
```

- *short URL with space works (`href` on a single line)*
```
    <a moz-do-not-send="true" href="http://www.example.com/foo bar.pdf">test
      link</a><br>
    <br>
```

**Expected result**

- link with long URL with space must be preserved correctly so that it renders correctly for message recipient

**Analysis**

Apparently the reason is that Thunderbird will format the source with indents and tries to keep line length at average, then the href="foo bar" attribute is broken across two lines and indented without escaping or otherwise indicating that there's a space which still belongs to the URL.
The erroneous extra spaces are exactly the 6 indent spaces after the linebreak inside the href attribute.

Back to Bug 1707360 Comment 1