Empty mailto: URL does not render a mailto-Link

Issue #9 resolved
Christoph Vigano created an issue

According to https://developer.mozilla.org/en-US/docs/Learn/HTML/Introduction_to_HTML/Creating_hyperlinks#E-mail_links, even an empty link "mailto:" is correct and can be used to trigger the creation of a new email to send.

Somewhere along the way, this functionality was removed, but I don't see a rationale for that in the commit messages or how one should address this. In our case, it would not be sensible to prefill an example email address in the plugin settings, as we don't know to which email address the user will share the current page.

Comments (8)

  1. Christoph Vigano reporter

    I think this is in your extension. In ShariffController L. 41 it is checked whether a mail URL is given. In the flexform_shariff.xml L 339 a placeholder is defined, but this placeholder does not act as a default value.

    This causes the condition to always be false if one does not want to provide a custom mail URL different from "mailto:", which is stated to be the default value in the FlexForm label.

    In my opinion, this is a breaking change, as especially in deployments where many instances of this plugin are deployed, an integrator would now have to comb through potentially tens or hundreds of plugin instances to re-configure those instances to the former default "mailto:".

  2. Christoph Vigano reporter

    Sure, I can provide a PR. Do I need to take anything into special consideration? It seems that I can't open a PR on this repository ("Access denied"). Should I fork this repository and provide a fix from there?

  3. Markus Klein

    Yes, that's how bitbucket/github works, you need to fork a repo unless you are a direct member of the project. Thanks.

  4. Log in to comment