-
Notifications
You must be signed in to change notification settings - Fork 11
/
mail.tmpl
94 lines (76 loc) · 3.73 KB
/
mail.tmpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" type="text/css" href="/static/css/flags.css">
<link rel="stylesheet" type="text/css" href="/static/css/pimail.css">
<style>
.hidden {
display: none;
}
</style>
<script type="text/javascript" src="/static/js/jquery-latest.js"></script>
</head>
<title>Mail your MEP</title>
</head>
<body>
<div id=global>
<h1>Write MEPs! Demand the enforcement of a true and unconditional Net neutrality!</h1>
<div id="sent-message" class="hidden">Your email is in your mail client -<br/>
if this doesn't work: the email address is <a href="mailto:{{email}}">{{email}}</a><br/>
{% if facebook %}
<p>You can also send your message to the MEP on his/her <a href="{{facebook}}" target="_blank">Facebook Page</a>.</p>
{% endif %}
</div>
<div id=mep_infos>
<section id=mep_name>To:<br>{{name}} <img src="/static/groups/group_icon_{{group_short}}.png" style="vertical-align:middle;"> </section>
<section id=mep_pic><img src="/static/images/{{id}}.jpg" style="height:120px;"></section>
<section id=mep_group>{{group}}</section>
<section id=mep_country><img src="/static/blank.gif" class="flag flag-{{country_short}}" alt="{{country}}"> {{country}}</section>
{% if facebook %}
<a href="{{facebook}}" target="_blank"><img src="/static/images/fb.jpg"></img></a>
{% endif %}
{% if twitter %}
<a href="https://twitter.com/{{twitter}}" target="_blank"><img src="/static/images/tw.png"></img></a>
{% endif %}
</div>
<div id=actionbox>
<input id="subject" class=emailsubject placeholder="Subject" name="subject" value="" />
<textarea id="body" name="body" class=emailtext>
Dear MEP {{name}},
On 27th October, you will vote on the future of the Internet. This is the last chance to fix the ambiguous Telecom Single Market regulation and deliver on the promise of net neutrality.
Today, Internet users can access content from small blogs, news websites, and government websites just as easily as they can access content from large companies. But we could damage this thriving environment unless you adopt clear rules enshrining net neutrality and clearly outlawing network discrimination.
On the day of the vote, we ask that you do not leave it up to regulators to decide the future of the Internet in Europe. The current text of the Telecom Single Market regulation is unclear and could enable interpretations that would lead to discrimination on the network, stifling freedom of expression, economic growth, and online innovation.
Please vote for amendments to clarify the Telecom Single Market regulation and ensure that net neutrality is delivered across the EU.
Sincerely,
A concerned citizen
</textarea>
<section><a onclick="makeform()" class="button" id="mailtolink" href="#">Mail Now!</a></section>
</div>
</div>
<script>
var txt_changed = false;
document.getElementById('body').onkeyup = function () {
txt_changed = true;
}
function makeform() {
if (txt_changed || confirm('Personalized messages are much more effective to convince politicans. \n\nPlease take the time to write a text :)\n\nSend it anyway?')) {
var email="mailto:{{email}}?subject="
var body=encodeURIComponent(document.getElementById("body").value)
var subject=encodeURIComponent(document.getElementById("subject").value)
email+=subject+"&body="+body
a=window.open(email)
//a.close()
document.getElementById("sent-message").className="";
}
}
function log_activity (action, value) {
jQuery.ajax('https://piwik.netzfreiheit.org/piwik.php?idsite=11&rec=1&url=https%3A%2F%2Fsavetheinternet.eu&idgoal=1&e_c=contact&e_n=mail&e_v=' + (txt_changed ? 1 : 0));
}
$(function () {
$('#mailtolink').on('click', function () {
log_activity('mail');
})
});
</script>
</body>
</html>