forked from PurdueIEEE/old-IEEE-Website
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjoin.php
executable file
·104 lines (83 loc) · 4.73 KB
/
join.php
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
95
96
97
98
99
100
101
102
103
104
<?php
$page_title = 'Join';
$site_title = 'Purdue IEEE';
$site_index = '/';
include 'header.php';
require_once 'DirectoryServices/lists.php';
?>
<div class="well card-1">
<div class="row">
<div class="col-lg-12 text-dark">
<h1 class="text-center">Subscribe to our Mailing Lists</h1>
<div class="col-md-8 col-md-offset-2 text-dark" id="content">
<form id="#-form" action="DirectoryServices/directories.php" title="" method="post" style="font-size: 18px">
<label># for our announcements mailing list (Email): </label><br>
<input type="email" id="email" name="email" class="form-control"><br>
<label>Which technical committees would you like to additionally receive emails from?</label>
<div class="checkbox" style="margin-top: 0">
<?php foreach (Lists::all(true) as $key => $value): if ($key !== 'ieee-announcements'): ?>
<label><input class="tc-check" type="checkbox" name="list[]" value="<?php echo $key; ?>"><?php echo $value; ?></label><br>
<?php endif; endforeach; ?>
<input type="checkbox" name="list[]" checked="true" value="ieee-announcements" hidden>
</div>
<button class="btn btn-primary btn-raised ripple-effect" type="submit" value="submit">Submit</button>
<button class="btn btn-danger btn-raised ripple-effect" type="button" onclick="clearEntries();">Clear</button><br><br>
</form>
</div>
<script type="application/javascript">
$("##-form").submit(function(event) {
/* stop form from submitting normally */
event.preventDefault();
var $form = $( this ),
url = $form.attr( 'action' );
var list = $('input:checked').map(function(){
return $(this).val();
}).get();
var posting = $.post(url, {
email: $('#email').val(),
list: list
});
posting.done(function(data) {
var messages = data.split("%%");
$("#content > .alert-info").remove();
$("#content > .alert-danger").remove();
if (messages[0].length > 0) {
$("#content").append('<div class="alert alert-info"><strong>'+messages[0]+'</strong></div>');
}
if (messages[1].length > 0) {
//There were some errors
$("#content").append('<div class="alert alert-danger"><strong>'+messages[1]+'</strong></div>');
}
});
});
function clearEntries() {
$('#email').val("");
$('.tc-check').each(function(){
$(this).removeAttr("checked");
})
$("#content > .alert-info").remove();
$("#content > .alert-danger").remove();
$('#email').focus();
}
</script>
</div>
</div>
</div>
<div class="well card-1">
<div class="row">
<div class="col-md-8 col-md-offset-2 text-dark">
<h1 class="text-center">IEEE Dues</h1>
<p>
Purdue IEEE Student Organization follows a simple dues basis for membership. Membership fees are $10 for two semesters, which allows each person to have access to IEEE resources, such as:
<ul>
<li>Access to extras at Learning Events by Learning Committee</li>
<li>Trip expense coverage for committee competitions and social events</li>
<li>Free food at General Assemblies</li>
<li>Recognition for contributed work with final projects</li>
</ul>
To pay dues, please contact the Treasurer, Michael Anderson, at <a href="mailto:IEEE-Treas@purdueieee.org">IEEE-Treas@purdueieee.org</a>, go to EE 014 and use leave your email and dues with a Treasurer-authorized attendant inside the office, or give it to the Treasurer at General Assemblies.
</p>
</div>
</div>
</div>
<?php include 'footer.php'; ?>