forked from markus/AMPERION_Webpage
new
This commit is contained in:
commit
1d8da2b6dd
824 changed files with 76366 additions and 0 deletions
10
layouts/shortcodes/cloak_email.html
Normal file
10
layouts/shortcodes/cloak_email.html
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
<!-- {{/*
|
||||
Cloak an e-mail address
|
||||
|
||||
Usage: {{< cloak_email EMAIL >}}
|
||||
*/}} -->
|
||||
{{- $address_parts := split (.Get 0) "@" -}}
|
||||
{{- $user := index $address_parts 0 -}}
|
||||
{{- $domain := index $address_parts 1 -}}
|
||||
<span class="cloaked-e-mail" data-user="{{ range $index := seq (sub (len $user) 1) 0 }}{{ substr $user $index 1 }}{{ end }}" data-domain="{{ range $index := seq (sub (len $domain) 1) 0 }}{{ substr $domain $index 1 }}{{ end }}"></span>
|
||||
{{- /* Dummy comment to strip trailing newline */ -}}
|
||||
Loading…
Add table
Add a link
Reference in a new issue