forked from AndersonGroupPHInternal/HROnline
-
Notifications
You must be signed in to change notification settings - Fork 0
/
detectIpAddress.php
228 lines (107 loc) · 4.44 KB
/
detectIpAddress.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
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
<html>
<head>
<script src="https://npmcdn.com/[email protected]/dist/js/tether.min.js"></script>
<script type="text/javascript" src="js/jquery-3.1.1.js"></script>
<link rel="stylesheet" type="text/css" href="css/bootstrap.css">
<script type="text/javascript" src="js/bootstrap.js"></script>
<script type="text/javascript">
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','__gaTracker');
__gaTracker('create', 'UA-76297316-1', 'auto');
__gaTracker('set', 'forceSSL', true);
__gaTracker('send','pageview');
</script>
<title>Anderson Recruitment Management System</title>
<script type="text/javascript" src="http://l2.io/ip.js?var=userip"></script>
<script type="text/javascript">
$('document').ready(function () {
$('#Mymodal').modal('show');
$('#exam').css('display','none');
var IpAddress="";
if(typeof userip === 'undefined'){
$.getJSON("http://jsonip.com/?callback=?", function (data) {
IpAddress = data.ip;
});
}else{
IpAddress = userip;
}
$.ajax ({
type: "POST",
url: "address.php",
data: { ivalid : IpAddress },
success: function( result ) {
if(IpAddress==result){
var a_href = $('#exam').attr('href');
$('#exam').attr('href','http://localhost:8080/HROnlineV2/index.php?ref=<?php echo'raiven';?>&&fname=<?php echo'raiven';?>&&mname=<?php echo'flores';?>&&lname=<?php echo'lopez';?>');
$('#exam').css('display','block');
}
}
});
});
</script>
</head>
<body background='bg2.jpg' style="background-position: center center;background-repeat: no-repeat;background-attachment: fixed;background-size: cover;">
<hr style="padding-top: 150px">
<h3 style="text-align:center; color: #e6e6e6; text-shadow: 2px 2px #404040">Like our page and follow us on twitter for more updates!</h3>
<p style="text-align:center;">
<iframe src="https://www.facebook.com/plugins/page.php?href=https%3A%2F%2Fwww.facebook.com%2FAndersonGroupPH%2F&tabs=Header&width=450&height=130&small_header=false&adapt_container_width=false&hide_cover=false&show_facepile=false&appId" width="450" height="130" style="border:none;overflow:hidden" scrolling="no" frameborder="0" allowTransparency="true"></iframe><br/>
<script>
(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/en_US/sdk.js#xfbml=1&version=v2.8";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<a class="twitter-follow-button"
href="https://twitter.com/andersongroupph"
data-size="large">
Follow @AndersonGroupPH</a>
<script>window.twttr = (function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0],
t = window.twttr || {};
if (d.getElementById(id)) return t;
js = d.createElement(s);
js.id = id;
js.src = "https://platform.twitter.com/widgets.js";
fjs.parentNode.insertBefore(js, fjs);
t._e = [];
t.ready = function(f) {
t._e.push(f);
};
return t;
}(document, "script", "twitter-wjs"));</script>
<div class="row" style="text-align: center">
<a href="http://andersongroup.ph"> <button class="btn bnt-primary">Return</button></a>
</div>
<div class="container">
<div id="Mymodal" role="dialog" class="modal fade">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" data-dismiss="modal" class="close">×</button>
<h4 class="modal-title">Reference Code</h4>
</div>
<div class="modal-body">
Your application form has been successfully sent.
<p>Please remember your Reference Code:</p>
<a id="exam">Click Here for Exam</a>
<?php
if(isset($_SESSION['Application_Status'])){
echo'<p style="color:#ff6d00;">Note: Use this code to resume your application form.</p>';
}else{
echo'<p style="color:#ff6d00;">Note: Use this code to edit your application form and to take our exam.</p>';
}
?>
</div>
<div class="modal-footer">
<button type="button" data-dismiss="modal" class="btn btn-default">Close</button>
</div>
</div>
</div>
</div>
</div>
</body>
</html>