mailtrain icon indicating copy to clipboard operation
mailtrain copied to clipboard

HTML on the start-page is not shown as HTML

Open saschafoerster opened this issue 3 years ago • 6 comments

In the settings, there is an option to show a message on the start-page, which can be configured with HTML, as the explainer-text says. But it seems not to work, or am I missing some HTML-formatting?

Backend: Bildschirmfoto 2022-04-23 um 14 58 52

Frontend: Bildschirmfoto 2022-04-23 um 14 58 43

saschafoerster avatar Apr 23 '22 13:04 saschafoerster

@saschafoerster what is your goal with this? Since this info is only shown when logged in.

the mailtrain.example.com is the backend, frontend is newsletter.example.com

forge0ne avatar Apr 23 '22 13:04 forge0ne

@talheim-it Thank you for pointing out! So still it promised to show HTML, which it doesn't. ;)

What I am actually trying to do is to show the basic information any webpage needs to show, even though there is only a login-window: Impressum and data protection policy. So if someone is checking any of the three new URLs in V2 will find these links.

saschafoerster avatar Apr 23 '22 13:04 saschafoerster

So I guess I need to change this line: https://github.com/Mailtrain-org/mailtrain/blob/197ed4e94692f3b6d1d876179b9bd653c42c22be/client/src/lib/page.js#L214

saschafoerster avatar Apr 24 '22 12:04 saschafoerster

I'm not sure what you want. But the landing page after login is this one: https://github.com/Mailtrain-org/mailtrain/blob/197ed4e94692f3b6d1d876179b9bd653c42c22be/client/src/Home.js

bures avatar Apr 24 '22 15:04 bures

It's just a little thing, but still. :) I try to explain better.

I wanted to add content to that landing page (actually two links). And the shoutout helper text says, you can use HTML:

https://github.com/Mailtrain-org/mailtrain/blob/5add1541d6b2c4c2e3422e85597330933e216374/locales/en-US/common.json#L893

But when I use HTML like the tag a href, then it will not be interpreted as a link but as plaintext, which was not what I expected.

So either the shout-out should be changed, or HTML should be correctly interpreted on the startpage.

saschafoerster avatar Apr 24 '22 19:04 saschafoerster

@bures The text in the config-sections says "HTML code shown in the front page header section" (htmlCodeShownInTheFrontPageHeaderSection), but it should be "Text shown on the front page" cause the html-elements never get rendered.

jfqd avatar Oct 12 '22 11:10 jfqd

We are going to start with the development and testing of mailtrain v3 in the next weeks.

You are welcome to help us with the testing as soon as the first release candidate is available.

forge0ne avatar Mar 16 '24 09:03 forge0ne