E-Mail Adress hiding for spamcrawler


is there a solution for hiding email addresses in text automatic for spamcrawlers?
Here I found a solution for kirbytext, but I don’t use kirbytext in my website.
All php solutions I found have the weak point that I need to call the mailencryptionfunction direct where the address is wrote. This is also not really usable if I don’t know where the addresses are.

Have maybe someone a solution for me?


What do you use instead of Kirbytext?

Hi Lukas,
I use normal html. No Markdown or Kirbytext.

Is there any specific reason why you do this? In general, using HTML makes the whole site less maintainable, as you can’t change the templates or CSS without also having to change all content.

As you said: HTML also makes it difficult to apply filters to specific tags. You could use a RegEx replacement to search for mailto: and apply a filter on the value, but that can break very easily and is quite hackish.

Hallo Lukas,

because I don’t understand the benefits of markdown. I have to learn new, okay its easy but I have not all the benefits of HTML.
But could it be that we talk not from the same?
I use HTML inside a textfield of the panel. As example in the templates I use <?php echo html($page->title()) ?>.
This is the same like with Kirbytext or Markdown.

I don’t understand why that should be? Could you explain that me?


The main advantage of simple and abstracted content languages like Markdown and its extension Kirbytext is that they don’t offer all features HTML has to offer.

You might think that this is a disadvantage, but once you start using classes, inline styles, iframes and even more complicated content (all that is very tempting), you come into a situation where every piece of content gets coupled to the presentation (mainly with class names and inline styles). If you change your site layout or design in the future, you have a lot of unmaintainable HTML that isn’t compatible anymore.

I have seen this quite often on sites that use HTML for content or even WYSIWYG editors: The content isn’t consistent anymore and it is very difficult, much work and expensive to clean it up once it reached that state.

Actually you have. You can use HTML inside Kirbytext if you need special or custom markup. But Kirbytext also supports Kirbytags, which are easy to create yourself for situations where you need custom markup. They make sure that the markup you need is written only once, which makes it easy to change it if you ever need to.

Even if you don’t mess up your HTML with inline styles and such, there are advantages to using Markdown:

  • it is more esily readable, because it’s just plain text without obstructive tags
  • it’s more esily writable for the same reasons
  • you can convert to different output formats, not only HTML
  • as a side effect of its limitations, it forces you to structure you content more efficiently

Having said that, once you start using Kirbytags, some of the output conversion get’s lost, but you also win a lot of flexibility, because instead of changing your HTML in every single content file, you just need to change your tag output.

1 Like

Actually not even that, because you could implement equivalent tags for other output formats as well. :smile:

You are of course right, but it requires more work…

Try with javascript: http://jumk.de/nospam/stopspam.html

But that would require even more manual and unmaintainable HTML.