df5c5cd54f
1.) module dependency updated from jade 1.11.0 to pug 2.0.0-beta3 2.) All references to Jade have been changed to Pug 3.) /srv/web/jade.js is renamed to pug.js 4.) all template files renamed accordingly 5.) "mixin somename" is automatically considered a declaration, invocations must use "+somename" 6.) variable interpolation is no longer supported inside element attributes, use direct references and string concatenation instead. 7.) bumped minor version
48 lines
1.7 KiB
Plaintext
48 lines
1.7 KiB
Plaintext
mixin email(e, k)
|
|
button.btn.btn-xs.btn-default(onclick="showEmail(this, '"+e+"', '"+k+"')") Show Email
|
|
|
|
doctype html
|
|
html(lang="en")
|
|
head
|
|
include head
|
|
+head()
|
|
body
|
|
#wrap
|
|
nav.navbar.navbar-inverse.navbar-fixed-top(role="navigation")
|
|
include nav
|
|
+navheader()
|
|
#nav-collapsible.collapse.navbar-collapse
|
|
ul.nav.navbar-nav
|
|
+navdefaultlinks("/contact")
|
|
+navloginlogout("/contact")
|
|
section#mainpage
|
|
.container
|
|
.col-md-8.col-md-offset-2
|
|
h1 Contact
|
|
h3 Email
|
|
each contact in contacts
|
|
strong= contact.name
|
|
p.text-muted= contact.title
|
|
+email(contact.email, contact.emkey)
|
|
br
|
|
hr
|
|
h3 IRC
|
|
p.
|
|
The developer and other knowledgeable people are usually available on IRC for quick questions or comments. Official support can be provided for cytu.be and synchtube.6irc.net at <a href="http://webchat.6irc.net/?channels=cytube">irc.6irc.net#cytube</a>. These people can also address general questions about the software, but cannot provide technical support for third-party websites using this code.
|
|
include footer
|
|
+footer()
|
|
script(type="text/javascript").
|
|
function showEmail(btn, email, key) {
|
|
email = unescape(email);
|
|
key = unescape(key);
|
|
var dest = new Array(email.length);
|
|
for (var i = 0; i < email.length; i++) {
|
|
dest[i] = String.fromCharCode(email.charCodeAt(i) ^ key.charCodeAt(i % key.length));
|
|
}
|
|
email = dest.join("");
|
|
$("<a/>").attr("href", "mailto:" + email)
|
|
.text(email)
|
|
.insertBefore(btn);
|
|
$(btn).remove();
|
|
}
|