When using the Link feature in the Rich Text editor, I encounter an issue when adding a link without https://.
If I use https://www.nrk.no/, it opens NRK correctly.
However, if I add www.nrk.no, it resolves to: https://myapp-dev.appfarm.app/mypath/mypath/www.nrk.no
Is this intended behavior? If so, is there a workaround to block users from adding links without https:// or formatting it correctly?
It looks like this is default behavior for all links that are missing https:// and that this is not limited to the Rich Text component. I tested now with the Open URL action node for www.nrk.no, and the end result was the same. It looks like the platform’s way of verifying the link then adds the entire app hostname to the URL.
Changing this behavior from the platform’s side would cause a lot of behavioral changes to existing functionality in end applications, so the preferred approach would be to use a workaround at the solution level to ensure the URL format.
Upon clicking the submit button, I use Value Processor to map the rich text content to App Variables, of type Plaintext, Markdown and HTML (shown in the three lines above).
A useful bit of functionality could be to map to a string when someone clicks the Send button, and run some verification functionality on the String App Variable to ensure that all provided URLs in the Rich Text content begin with https://. In a case where a broken link is provided, the “send” functionality could be blocked, and an error message sent to the user.