Social Login - Version 5.4.4

Version Description

  • Social Network "Draugiem" added
  • Social Network "Mixer" added
  • Comment approval fixed
  • New hooks added
  • PHP 7.2 fixes
Download this release

Release Info

Developer ClaudeSchlesser
Plugin Icon 128x128 Social Login
Version 5.4.4
Comparing to
See all releases

Code changes from version 5.4.3 to 5.4.4

assets/css/admin.css CHANGED
@@ -1,14 +1,13 @@
1
  /* ********************* Page Wrapper */
2
  #oa_social_login_page {
3
- max-width: 900px;
4
  }
5
 
6
- #oa_social_login_page.oa_social_login_more{
7
- width:774px;
8
  }
9
 
10
-
11
- #oa_social_login_page .nav-tab-wrapper{
12
  border-bottom: 3px solid #0073aa;
13
  }
14
 
@@ -28,19 +27,19 @@
28
  }
29
 
30
  /* ********************* Plugins */
31
- .oa_social_login_plugin{
32
  border: 1px solid #ccc;
33
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
34
  margin: 10px 0 25px;
35
  }
36
 
37
- .oa_social_login_plugin .oa_social_login_plugin_img img{
38
  float: left;
39
  height: 250px;
40
  width: 772px;
41
  }
42
 
43
- .oa_social_login_plugin a.button-primary{
44
  height: 21px;
45
  line-height: 19px;
46
  padding: 0 10px;
@@ -48,7 +47,7 @@
48
  }
49
 
50
  .oa_social_login_plugin .oa_social_login_plugin_desc {
51
- background: #eee none repeat scroll 0 0;
52
  border-top: 1px solid #fcfcfc;
53
  box-shadow: 0 0 42px 0 rgba(100, 100, 100, 0.1) inset;
54
  font-size: 16px;
@@ -60,387 +59,382 @@
60
 
61
  /* ********************* Boxes */
62
  .oa_social_login_box {
63
- border: 1px solid #CCCCCC;
64
- margin-bottom: 35px;
65
- padding: 10px 15px;
66
  }
67
 
68
- .oa_social_login_box p{
69
- font-size:14px;
70
  }
71
 
72
  .oa_social_login_box .oa_social_login_box_title {
73
- border-bottom: 1px solid #ccc;
74
- font-size: 15px;
75
- font-weight: bold;
76
- padding-bottom: 5px;
77
  }
78
 
79
- .oa_social_login_box .oa_social_login_button_wrap{
80
- text-align:center;
81
  padding: 10px 0 20px;
82
  }
83
 
84
- .oa_social_login_box .oa_social_login_button_wrap a{
85
  font-size: 14px;
86
  height: 40px;
87
  line-height: 40px;
88
- padding: 0 33px;
89
- margin:0 10px;
90
  }
91
 
92
- #oa_social_login_box_started{
93
- background-color: #dff0d8;
94
- border-color: #c4d7b4;
95
- color: #3c763d;
96
  }
97
 
98
  #oa_social_login_box_started a {
99
  color: #1a541b;
100
  }
101
 
102
- #oa_social_login_box_started a:hover{
103
- text-decoration:none;
104
  color: #111;
105
  }
106
 
107
- #oa_social_login_box_started a.button-secondary{
108
  color: #555;
109
  }
110
 
111
- #oa_social_login_box_started h3{
112
- text-align:center;
113
  color: #4a844b;
114
  }
115
 
116
  #oa_social_login_box_status {
117
- background-color: #E1EDFF;
118
- margin-bottom: 10px;
119
  }
120
 
121
- #oa_social_login_box_status p{
122
- text-align:center;
123
  font-size: 15px;
124
  }
125
 
126
  #oa_social_login_box_notice {
127
- background-color: #C4F095;
128
  }
129
 
130
  #oa_social_login_box_help {
131
- background-color: #FFFFE0;
132
- border-color: #E6DB55;
133
- margin-bottom: 35px;
134
  }
135
 
136
  #oa_social_login_box_help ul {
137
- padding-left: 20px;
138
- list-style-type: disc;
139
  }
140
 
141
  #oa_social_login_box_help .oa_social_login_box_title {
142
- border-color: #E6DB55;
143
  }
144
 
145
  #oa_social_login_box_help a {
146
- color: #111;
147
  }
148
 
149
  #oa_social_login_box_help a:hover {
150
- color: #d54e21;
151
  }
152
 
153
  #oa_social_login_box_updated {
154
- background-color: green;
155
- color: #fff;
156
- font-weight: bold;
157
  }
158
 
159
  /* ********************* Tables */
160
  .oa_social_login_table {
161
- background-color: #efefef;
162
- border: 1px solid #ccc;
163
- margin: 0 0 25px;
164
  }
165
 
166
- .oa_social_login_table textarea,.oa_social_login_table input {
167
- border-color: #aaa;
 
168
  }
169
 
170
  .oa_social_login_table tr.row_head th {
171
- font-size: 14px;
172
- font-weight: bold;
173
- background-color: #3E687B;
174
- color: #fff;
175
- text-shadow: 0 1px 0 #333;
176
- padding: 15px 10px;
177
  }
178
 
179
- .oa_social_login_table tr td img{
180
- vertical-align:middle;
181
  }
182
 
183
  .oa_social_login_table tr.row_head th a {
184
- color: #F1EE10;
185
  }
186
 
187
  .oa_social_login_table tr.row_head th a:hover {
188
- color: #fff;
189
- text-decoration: none;
190
  }
191
 
192
- .oa_social_login_table tr.row_odd,
193
  .oa_social_login_table tr.row_odd td {
194
- color: #222;
195
- background-color: #ddd;
196
- border-bottom: 1px dotted #BBBBBB;
197
- line-height: 23px
198
  }
199
 
200
- .oa_social_login_table tr.row_even,
201
  .oa_social_login_table tr.row_even td {
202
- color: #333;
203
- background-color: #fff;
204
- border-bottom: 1px dotted #bbb;
205
- line-height: 23px
206
  }
207
 
208
-
209
- .oa_social_login_table td.col_unpadded{
210
- padding:0;
211
  }
212
 
213
  .oa_social_login_table tr td.row_multi {
214
- border-right: 1px dotted #BBBBBB;
215
  }
216
 
217
  .oa_social_login_table tr.row_foot td {
218
- background-color: #ddd;
219
  }
220
 
221
  .oa_social_login_table tr.row_foot .error_message {
222
- color: red;
223
- background: url("../img/status_error.png") no-repeat scroll 0 50% #ddd;
224
- padding-left: 25px;
225
- font-weight: bold;
226
  }
227
 
228
- .oa_social_login_table tr.row_foot .error_message,.oa_social_login_table tr.row_foot .error_message a {
229
- color: red;
230
- font-weight: bold;
 
231
  }
232
 
233
  .oa_social_login_table tr.row_foot .working_message {
234
- color: blue;
235
- background: url("../img/status_loading.gif") no-repeat scroll 0 50% #ddd;
236
- padding-left: 25px;
237
- font-weight: bold;
238
  }
239
 
240
  .oa_social_login_table tr.row_foot .error_message a:hover {
241
- color: #C70000;
242
  }
243
 
244
  .oa_social_login_table tr.row_foot .success_message {
245
- color: green;
246
- background: url("../img/status_ok.png") no-repeat scroll 0 50% #ddd;
247
- padding-left: 25px;
248
- font-weight: bold;
249
  }
250
 
251
-
252
- .oa_social_login_table a.social-sharing{
253
  background-image: url("../img/social_sharing.png");
254
- background-repeat:no-repeat;
255
  display: block;
256
  height: 250px;
257
- width:772px;
258
  }
259
 
260
  /* ********************* Providers */
261
  .oa_social_login_table tr.row_provider td {
262
- line-height: 35px;
263
  }
264
 
265
  .oa_social_login_table tr.row_provider td.cell_provider_icon {
266
- width: 50px;
267
- text-align: center !important;
268
  }
269
 
270
  .oa_social_login_table tr.row_provider td.cell_provider_label {
271
- text-align: left !important;
272
  }
273
 
274
  .oa_social_login_provider {
275
- background-image: url("../img/sprite_35_35.png");
276
- text-indent: -9999px;
277
- height: 35px;
278
- width: 35px;
279
- display: inline-block;
280
  }
281
 
282
-
283
  /* Buttons */
284
- .oa_social_login_provider_vimeo {
285
- background-position: -2px -1px;
286
- }
287
-
288
- .oa_social_login_provider_blogger {
289
- background-position: -39px -1px;
290
  }
291
 
292
- .oa_social_login_provider_facebook {
293
- background-position: -76px -1px;
294
  }
295
 
296
- .oa_social_login_provider_foursquare {
297
- background-position: -113px -1px;
298
  }
299
 
300
- .oa_social_login_provider_google {
301
- background-position: -150px -1px;
302
  }
303
 
304
- .oa_social_login_provider_reddit {
305
- background-position: -187px -1px;
306
  }
307
 
308
- .oa_social_login_provider_linkedin {
309
- background-position: -224px -1px;
310
  }
311
 
312
- .oa_social_login_provider_windowslive {
313
- background-position: -261px -1px;
314
  }
315
 
316
- .oa_social_login_provider_livejournal {
317
- background-position: -298px -1px;
318
  }
319
 
320
- .oa_social_login_provider_myspace {
321
- background-position: -372px -1px;
322
  }
323
 
324
- .oa_social_login_provider_openid {
325
- background-position: -409px -1px;
326
  }
327
 
328
- .oa_social_login_provider_draugiem {
329
- background-position: -446px -1px;
330
  }
331
 
332
- .oa_social_login_provider_twitter {
333
- background-position: -520px -1px;
334
  }
335
 
336
- .oa_social_login_provider_vkontakte {
337
- background-position: -631px -1px;
338
  }
339
 
340
- .oa_social_login_provider_wordpress {
341
- background-position: -668px -1px;
342
  }
343
 
344
- .oa_social_login_provider_yahoo {
345
- background-position: -705px -1px;
346
  }
347
 
348
- .oa_social_login_provider_paypal {
349
- background-position: -742px -1px;
350
  }
351
 
352
- .oa_social_login_provider_stackexchange {
353
- background-position: -779px -1px;
354
  }
355
 
356
- .oa_social_login_provider_steam {
357
- background-position: -816px -1px;
358
  }
359
 
360
- .oa_social_login_provider_mailru {
361
- background-position: -853px -1px;
362
  }
363
 
364
- .oa_social_login_provider_skyrock {
365
- background-position: -890px -1px;
366
  }
367
 
368
- .oa_social_login_provider_github {
369
- background-position: -927px -1px;
370
  }
371
 
372
- .oa_social_login_provider_disqus {
373
- background-position: -964px -1px;
374
  }
375
 
376
- .oa_social_login_provider_youtube {
377
- background-position: -1001px -1px;
378
  }
379
 
380
- .oa_social_login_provider_odnoklassniki {
381
- background-position: -1038px -1px;
382
  }
383
 
384
- .oa_social_login_provider_deviantart {
385
- background-position: -1075px -1px;
386
  }
387
 
388
- .oa_social_login_provider_twitch {
389
- background-position: -1112px -1px;
390
  }
391
 
392
- .oa_social_login_provider_amazon {
393
- background-position: -1149px -1px;
394
  }
395
 
396
- .oa_social_login_provider_instagram {
397
- background-position: -1186px -1px;
398
  }
399
 
400
- .oa_social_login_provider_battlenet {
401
- background-position: -1223px -1px;
402
  }
403
 
404
- .oa_social_login_provider_dribbble {
405
- background-position: -1260px -1px;
406
  }
407
 
408
- .oa_social_login_provider_pinterest {
409
- background-position: -1297px -1px;
410
  }
411
 
412
- .oa_social_login_provider_pixelpin {
413
- background-position: -1334px -1px;
414
  }
415
 
416
- .oa_social_login_provider_storage {
417
- background-position: -1371px -1px;
418
  }
419
 
420
- .oa_social_login_provider_meetup {
421
- background-position: -1408px -1px;
422
  }
423
 
424
- .oa_social_login_provider_xing {
425
- background-position: -372px -1px;
426
  }
427
 
428
- .oa_social_login_provider_line {
429
- background-position: -1445px -1px;
430
  }
431
 
432
- .oa_social_login_provider_soundcloud {
433
- background-position: -1482px -1px;
434
  }
435
 
436
- .oa_social_login_provider_discord {
437
- background-position: -1519px -1px;
438
  }
439
 
440
- .oa_social_login_provider_weibo {
441
- background-position: -1556px -1px;
442
  }
443
 
444
- .oa_social_login_provider_tumblr {
445
- background-position: -1593px -1px;
446
- }
1
  /* ********************* Page Wrapper */
2
  #oa_social_login_page {
3
+ max-width: 900px;
4
  }
5
 
6
+ #oa_social_login_page.oa_social_login_more {
7
+ width: 774px;
8
  }
9
 
10
+ #oa_social_login_page .nav-tab-wrapper {
 
11
  border-bottom: 3px solid #0073aa;
12
  }
13
 
27
  }
28
 
29
  /* ********************* Plugins */
30
+ .oa_social_login_plugin {
31
  border: 1px solid #ccc;
32
  box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04);
33
  margin: 10px 0 25px;
34
  }
35
 
36
+ .oa_social_login_plugin .oa_social_login_plugin_img img {
37
  float: left;
38
  height: 250px;
39
  width: 772px;
40
  }
41
 
42
+ .oa_social_login_plugin a.button-primary {
43
  height: 21px;
44
  line-height: 19px;
45
  padding: 0 10px;
47
  }
48
 
49
  .oa_social_login_plugin .oa_social_login_plugin_desc {
50
+ background: #eee none repeat scroll 0 0;
51
  border-top: 1px solid #fcfcfc;
52
  box-shadow: 0 0 42px 0 rgba(100, 100, 100, 0.1) inset;
53
  font-size: 16px;
59
 
60
  /* ********************* Boxes */
61
  .oa_social_login_box {
62
+ border: 1px solid #CCCCCC;
63
+ margin-bottom: 35px;
64
+ padding: 10px 15px;
65
  }
66
 
67
+ .oa_social_login_box p {
68
+ font-size: 14px;
69
  }
70
 
71
  .oa_social_login_box .oa_social_login_box_title {
72
+ border-bottom: 1px solid #ccc;
73
+ font-size: 15px;
74
+ font-weight: bold;
75
+ padding-bottom: 5px;
76
  }
77
 
78
+ .oa_social_login_box .oa_social_login_button_wrap {
79
+ text-align: center;
80
  padding: 10px 0 20px;
81
  }
82
 
83
+ .oa_social_login_box .oa_social_login_button_wrap a {
84
  font-size: 14px;
85
  height: 40px;
86
  line-height: 40px;
87
+ padding: 0 33px;
88
+ margin: 0 10px;
89
  }
90
 
91
+ #oa_social_login_box_started {
92
+ background-color: #dff0d8;
93
+ border-color: #c4d7b4;
94
+ color: #3c763d;
95
  }
96
 
97
  #oa_social_login_box_started a {
98
  color: #1a541b;
99
  }
100
 
101
+ #oa_social_login_box_started a:hover {
102
+ text-decoration: none;
103
  color: #111;
104
  }
105
 
106
+ #oa_social_login_box_started a.button-secondary {
107
  color: #555;
108
  }
109
 
110
+ #oa_social_login_box_started h3 {
111
+ text-align: center;
112
  color: #4a844b;
113
  }
114
 
115
  #oa_social_login_box_status {
116
+ background-color: #E1EDFF;
117
+ margin-bottom: 10px;
118
  }
119
 
120
+ #oa_social_login_box_status p {
121
+ text-align: center;
122
  font-size: 15px;
123
  }
124
 
125
  #oa_social_login_box_notice {
126
+ background-color: #C4F095;
127
  }
128
 
129
  #oa_social_login_box_help {
130
+ background-color: #FFFFE0;
131
+ border-color: #E6DB55;
132
+ margin-bottom: 35px;
133
  }
134
 
135
  #oa_social_login_box_help ul {
136
+ padding-left: 20px;
137
+ list-style-type: disc;
138
  }
139
 
140
  #oa_social_login_box_help .oa_social_login_box_title {
141
+ border-color: #E6DB55;
142
  }
143
 
144
  #oa_social_login_box_help a {
145
+ color: #111;
146
  }
147
 
148
  #oa_social_login_box_help a:hover {
149
+ color: #d54e21;
150
  }
151
 
152
  #oa_social_login_box_updated {
153
+ background-color: green;
154
+ color: #fff;
155
+ font-weight: bold;
156
  }
157
 
158
  /* ********************* Tables */
159
  .oa_social_login_table {
160
+ background-color: #efefef;
161
+ border: 1px solid #ccc;
162
+ margin: 0 0 25px;
163
  }
164
 
165
+ .oa_social_login_table textarea,
166
+ .oa_social_login_table input {
167
+ border-color: #aaa;
168
  }
169
 
170
  .oa_social_login_table tr.row_head th {
171
+ font-size: 14px;
172
+ font-weight: bold;
173
+ background-color: #3E687B;
174
+ color: #fff;
175
+ text-shadow: 0 1px 0 #333;
176
+ padding: 15px 10px;
177
  }
178
 
179
+ .oa_social_login_table tr td img {
180
+ vertical-align: middle;
181
  }
182
 
183
  .oa_social_login_table tr.row_head th a {
184
+ color: #F1EE10;
185
  }
186
 
187
  .oa_social_login_table tr.row_head th a:hover {
188
+ color: #fff;
189
+ text-decoration: none;
190
  }
191
 
192
+ .oa_social_login_table tr.row_odd,
193
  .oa_social_login_table tr.row_odd td {
194
+ color: #222;
195
+ background-color: #ddd;
196
+ border-bottom: 1px dotted #BBBBBB;
197
+ line-height: 23px
198
  }
199
 
200
+ .oa_social_login_table tr.row_even,
201
  .oa_social_login_table tr.row_even td {
202
+ color: #333;
203
+ background-color: #fff;
204
+ border-bottom: 1px dotted #bbb;
205
+ line-height: 23px
206
  }
207
 
208
+ .oa_social_login_table td.col_unpadded {
209
+ padding: 0;
 
210
  }
211
 
212
  .oa_social_login_table tr td.row_multi {
213
+ border-right: 1px dotted #BBBBBB;
214
  }
215
 
216
  .oa_social_login_table tr.row_foot td {
217
+ background-color: #ddd;
218
  }
219
 
220
  .oa_social_login_table tr.row_foot .error_message {
221
+ color: red;
222
+ background: url("../img/status_error.png") no-repeat scroll 0 50% #ddd;
223
+ padding-left: 25px;
224
+ font-weight: bold;
225
  }
226
 
227
+ .oa_social_login_table tr.row_foot .error_message,
228
+ .oa_social_login_table tr.row_foot .error_message a {
229
+ color: red;
230
+ font-weight: bold;
231
  }
232
 
233
  .oa_social_login_table tr.row_foot .working_message {
234
+ color: blue;
235
+ background: url("../img/status_loading.gif") no-repeat scroll 0 50% #ddd;
236
+ padding-left: 25px;
237
+ font-weight: bold;
238
  }
239
 
240
  .oa_social_login_table tr.row_foot .error_message a:hover {
241
+ color: #C70000;
242
  }
243
 
244
  .oa_social_login_table tr.row_foot .success_message {
245
+ color: green;
246
+ background: url("../img/status_ok.png") no-repeat scroll 0 50% #ddd;
247
+ padding-left: 25px;
248
+ font-weight: bold;
249
  }
250
 
251
+ .oa_social_login_table a.social-sharing {
 
252
  background-image: url("../img/social_sharing.png");
253
+ background-repeat: no-repeat;
254
  display: block;
255
  height: 250px;
256
+ width: 772px;
257
  }
258
 
259
  /* ********************* Providers */
260
  .oa_social_login_table tr.row_provider td {
261
+ line-height: 35px;
262
  }
263
 
264
  .oa_social_login_table tr.row_provider td.cell_provider_icon {
265
+ width: 50px;
266
+ text-align: center !important;
267
  }
268
 
269
  .oa_social_login_table tr.row_provider td.cell_provider_label {
270
+ text-align: left !important;
271
  }
272
 
273
  .oa_social_login_provider {
274
+ background-image: url("../img/sprite_35_35.png");
275
+ text-indent: -9999px;
276
+ height: 35px;
277
+ width: 35px;
278
+ display: inline-block;
279
  }
280
 
 
281
  /* Buttons */
282
+ .oa_social_login_provider_amazon {
283
+ background-position: -1149px -1px;
 
 
 
 
284
  }
285
 
286
+ .oa_social_login_provider_battlenet {
287
+ background-position: -1223px -1px;
288
  }
289
 
290
+ .oa_social_login_provider_blogger {
291
+ background-position: -39px -1px;
292
  }
293
 
294
+ .oa_social_login_provider_discord {
295
+ background-position: -1519px -1px;
296
  }
297
 
298
+ .oa_social_login_provider_disqus {
299
+ background-position: -964px -1px;
300
  }
301
 
302
+ .oa_social_login_provider_draugiem {
303
+ background-position: -446px -1px;
304
  }
305
 
306
+ .oa_social_login_provider_dribbble {
307
+ background-position: -1260px -1px;
308
  }
309
 
310
+ .oa_social_login_provider_facebook {
311
+ background-position: -76px -1px;
312
  }
313
 
314
+ .oa_social_login_provider_foursquare {
315
+ background-position: -113px -1px;
316
  }
317
 
318
+ .oa_social_login_provider_github {
319
+ background-position: -927px -1px;
320
  }
321
 
322
+ .oa_social_login_provider_google {
323
+ background-position: -150px -1px;
324
  }
325
 
326
+ .oa_social_login_provider_instagram {
327
+ background-position: -1186px -1px;
328
  }
329
 
330
+ .oa_social_login_provider_line {
331
+ background-position: -1445px -1px;
332
  }
333
 
334
+ .oa_social_login_provider_linkedin {
335
+ background-position: -224px -1px;
336
  }
337
 
338
+ .oa_social_login_provider_livejournal {
339
+ background-position: -298px -1px;
340
  }
341
 
342
+ .oa_social_login_provider_mailru {
343
+ background-position: -853px -1px;
344
  }
345
 
346
+ .oa_social_login_provider_meetup {
347
+ background-position: -1408px -1px;
348
  }
349
 
350
+ .oa_social_login_provider_mixer {
351
+ background-position: -1667px -1px;
352
  }
353
 
354
+ .oa_social_login_provider_odnoklassniki {
355
+ background-position: -1038px -1px;
356
  }
357
 
358
+ .oa_social_login_provider_openid {
359
+ background-position: -409px -1px;
360
  }
361
 
362
+ .oa_social_login_provider_paypal {
363
+ background-position: -742px -1px;
364
  }
365
 
366
+ .oa_social_login_provider_pinterest {
367
+ background-position: -1297px -1px;
368
  }
369
 
370
+ .oa_social_login_provider_pixelpin {
371
+ background-position: -1334px -1px;
372
  }
373
 
374
+ .oa_social_login_provider_reddit {
375
+ background-position: -187px -1px;
376
  }
377
 
378
+ .oa_social_login_provider_skyrock {
379
+ background-position: -890px -1px;
380
  }
381
 
382
+ .oa_social_login_provider_storage {
383
+ background-position: -1371px -1px;
384
  }
385
 
386
+ .oa_social_login_provider_soundcloud {
387
+ background-position: -1482px -1px;
388
  }
389
 
390
+ .oa_social_login_provider_stackexchange {
391
+ background-position: -779px -1px;
392
  }
393
 
394
+ .oa_social_login_provider_steam {
395
+ background-position: -816px -1px;
396
  }
397
 
398
+ .oa_social_login_provider_tumblr {
399
+ background-position: -1593px -1px;
400
  }
401
 
402
+ .oa_social_login_provider_twitch {
403
+ background-position: -1112px -1px;
404
  }
405
 
406
+ .oa_social_login_provider_twitter {
407
+ background-position: -520px -1px;
408
  }
409
 
410
+ .oa_social_login_provider_vimeo {
411
+ background-position: -2px -1px;
412
  }
413
 
414
+ .oa_social_login_provider_vkontakte {
415
+ background-position: -631px -1px;
416
  }
417
 
418
+ .oa_social_login_provider_weibo {
419
+ background-position: -1556px -1px;
420
  }
421
 
422
+ .oa_social_login_provider_windowslive {
423
+ background-position: -261px -1px;
424
  }
425
 
426
+ .oa_social_login_provider_wordpress {
427
+ background-position: -668px -1px;
428
  }
429
 
430
+ .oa_social_login_provider_xing {
431
+ background-position: -372px -1px;
432
  }
433
 
434
+ .oa_social_login_provider_yahoo {
435
+ background-position: -705px -1px;
436
  }
437
 
438
+ .oa_social_login_provider_youtube {
439
+ background-position: -1001px -1px;
440
+ }
assets/img/single-sign-on.png ADDED
Binary file
assets/img/sprite_35_35.png CHANGED
Binary file
includes/admin.php CHANGED
@@ -94,19 +94,24 @@ add_action ('admin_menu', 'oa_social_login_admin_menu');
94
  **/
95
  function oa_social_login_admin_pre_comment_approved ($approved)
96
  {
97
- // No need to do the check if the comment has already been approved
98
  if (empty ($approved))
99
  {
100
- //Read settings
101
  $settings = get_option ('oa_social_login_settings');
102
 
103
- //Check if enabled
104
  if (!empty ($settings ['plugin_comment_auto_approve']))
105
  {
 
106
  $user_id = get_current_user_id ();
107
  if (is_numeric ($user_id))
108
  {
109
- if (get_user_meta ($user_id, 'oa_social_login_user_token', true) !== false)
 
 
 
 
110
  {
111
  $approved = 1;
112
  }
@@ -631,7 +636,7 @@ function oa_display_social_login_more ()
631
  <a href="<?php echo $more_url; ?>"><img src="<?php echo plugin_dir_url( __FILE__ ) . '../assets/img/social_sharing.png' ?>" alt="<?php _e ('Social Login', 'oa_social_login') ?>" /></a>
632
  </div>
633
  <div class="oa_social_login_plugin_desc">
634
- <?php _e ('Allow your visitors to comment, login and register with 30+ social networks like for example Twitter, Facebook, Pinterest, Instagram, Paypal, LinkedIn, OpenID, VKontakte or Google+. Easy to use and 100% FREE.', 'oa_social_login'); ?>
635
  <a href="<?php echo $more_url; ?>" class="button-primary"><?php _e ('More Info', 'oa_social_login'); ?></a>
636
  </div>
637
  </div>
@@ -644,7 +649,20 @@ function oa_display_social_login_more ()
644
  <a href="<?php echo $more_url; ?>"><img src="<?php echo plugin_dir_url( __FILE__ ) . '../assets/img/loudvoice.png' ?>" alt="<?php _e ('LoudVoice Comment System', 'oa_social_login') ?>" /></a>
645
  </div>
646
  <div class="oa_social_login_plugin_desc">
647
- <?php _e ('LoudVoice replaces the basic WordPress comments by a powerful comment system that includes logging in with 30+ social networks, spam filters and more. Easy to use and 100% FREE. Existing comments can be imported!', 'oa_social_login'); ?>
 
 
 
 
 
 
 
 
 
 
 
 
 
648
  <a href="<?php echo $more_url; ?>" class="button-primary"><?php _e ('More Info', 'oa_social_login'); ?></a>
649
  </div>
650
  </div>
@@ -675,7 +693,7 @@ function oa_display_social_login_setup ()
675
  {
676
  ?>
677
  <p>
678
- <?php _e ('Allow your visitors to comment, login and register with 30+ Social Networks like for example Twitter, Facebook, LinkedIn, Instagram, VKontakte, Google or Yahoo.', 'oa_social_login'); ?>
679
  <strong><?php _e ('Draw a larger audience and increase your user engagement in a few simple steps.', 'oa_social_login'); ?> </strong>
680
  </p>
681
  <div class="oa_social_login_box" id="oa_social_login_box_started">
94
  **/
95
  function oa_social_login_admin_pre_comment_approved ($approved)
96
  {
97
+ // No need to do the check if the comment has already been approved.
98
  if (empty ($approved))
99
  {
100
+ // Read settings.
101
  $settings = get_option ('oa_social_login_settings');
102
 
103
+ // Check if pre approval is enabled.
104
  if (!empty ($settings ['plugin_comment_auto_approve']))
105
  {
106
+ // Read comment user.
107
  $user_id = get_current_user_id ();
108
  if (is_numeric ($user_id))
109
  {
110
+ // Read user token.
111
+ $user_token = trim (get_user_meta ($user_id, 'oa_social_login_user_token', true));
112
+
113
+ // If not empty, it's a social login user.
114
+ if ( ! empty ($user_token))
115
  {
116
  $approved = 1;
117
  }
636
  <a href="<?php echo $more_url; ?>"><img src="<?php echo plugin_dir_url( __FILE__ ) . '../assets/img/social_sharing.png' ?>" alt="<?php _e ('Social Login', 'oa_social_login') ?>" /></a>
637
  </div>
638
  <div class="oa_social_login_plugin_desc">
639
+ <?php _e ('Allow your visitors to comment, login and register with 40+ social networks like for example Twitter, Facebook, Pinterest, Instagram, Paypal, LinkedIn, OpenID, VKontakte or Google+. Easy to use and 100% FREE.', 'oa_social_login'); ?>
640
  <a href="<?php echo $more_url; ?>" class="button-primary"><?php _e ('More Info', 'oa_social_login'); ?></a>
641
  </div>
642
  </div>
649
  <a href="<?php echo $more_url; ?>"><img src="<?php echo plugin_dir_url( __FILE__ ) . '../assets/img/loudvoice.png' ?>" alt="<?php _e ('LoudVoice Comment System', 'oa_social_login') ?>" /></a>
650
  </div>
651
  <div class="oa_social_login_plugin_desc">
652
+ <?php _e ('LoudVoice replaces the basic WordPress comments by a powerful comment system that includes logging in with 40+ social networks, spam filters and more. Easy to use and 100% FREE. Existing comments can be imported!', 'oa_social_login'); ?>
653
+ <a href="<?php echo $more_url; ?>" class="button-primary"><?php _e ('More Info', 'oa_social_login'); ?></a>
654
+ </div>
655
+ </div>
656
+
657
+ <?php
658
+ $more_url = admin_url('plugin-install.php?s=sso+oneall&tab=search&type=term');
659
+ ?>
660
+ <div class="oa_social_login_plugin">
661
+ <div class="oa_social_login_plugin_img">
662
+ <a href="<?php echo $more_url; ?>"><img src="<?php echo plugin_dir_url( __FILE__ ) . '../assets/img/single-sign-on.png' ?>" alt="<?php _e ('Single Sign-On', 'oa_social_login') ?>" /></a>
663
+ </div>
664
+ <div class="oa_social_login_plugin_desc">
665
+ <?php _e ('Automatically creates accounts and signs users in as they browse between multiple and independent WordPress blogs or websites in your network. Take away the need for your users to create new accounts or re-enter their authentication credentials on every of your websites.', 'oa_social_login'); ?>
666
  <a href="<?php echo $more_url; ?>" class="button-primary"><?php _e ('More Info', 'oa_social_login'); ?></a>
667
  </div>
668
  </div>
693
  {
694
  ?>
695
  <p>
696
+ <?php _e ('Allow your visitors to comment, login and register with 40+ Social Networks like for example Twitter, Facebook, LinkedIn, Instagram, VKontakte, Google or Yahoo.', 'oa_social_login'); ?>
697
  <strong><?php _e ('Draw a larger audience and increase your user engagement in a few simple steps.', 'oa_social_login'); ?> </strong>
698
  </p>
699
  <div class="oa_social_login_box" id="oa_social_login_box_started">
includes/communication.php CHANGED
@@ -48,7 +48,7 @@ function oa_social_login_callback ()
48
  $identity = $user_data->identity;
49
 
50
  // Unique user token provided by OneAll.
51
- $user_token = $user_data->user_token;
52
 
53
  // Identity Provider.
54
  $user_identity_provider = $identity->source->name;
@@ -224,20 +224,25 @@ function oa_social_login_callback ()
224
  do
225
  {
226
  $user_login_tmp = $user_login . ($i++);
 
227
  }
228
  while (username_exists ($user_login_tmp));
229
  $user_login = $user_login_tmp;
230
  }
231
 
 
 
 
232
  // Email Filter.
233
  $user_email = apply_filters ('oa_social_login_filter_new_user_email', $user_email);
234
 
235
  // Email must be unique.
236
  $placeholder_email_used = false;
237
- if (!isset ($user_email) OR !is_email ($user_email) OR email_exists ($user_email))
238
  {
239
- $user_email = oa_social_login_create_rand_email ();
240
- $placeholder_email_used = true;
 
241
  }
242
 
243
  // Setup the user's password.
@@ -553,6 +558,14 @@ function oa_social_login_callback ()
553
  exit ();
554
  }
555
  }
 
 
 
 
 
 
 
 
556
  }
557
  }
558
  }
48
  $identity = $user_data->identity;
49
 
50
  // Unique user token provided by OneAll.
51
+ $user_token = apply_filters ('oa_social_login_filter_get_user_token', $user_data->user_token);
52
 
53
  // Identity Provider.
54
  $user_identity_provider = $identity->source->name;
224
  do
225
  {
226
  $user_login_tmp = $user_login . ($i++);
227
+ $user_login_tmp = apply_filters ('oa_social_login_filter_new_user_generic_login', $user_login_tmp);
228
  }
229
  while (username_exists ($user_login_tmp));
230
  $user_login = $user_login_tmp;
231
  }
232
 
233
+ // Email Filter.
234
+ $user_login = apply_filters ('oa_social_login_filter_new_user_login', $user_login);
235
+
236
  // Email Filter.
237
  $user_email = apply_filters ('oa_social_login_filter_new_user_email', $user_email);
238
 
239
  // Email must be unique.
240
  $placeholder_email_used = false;
241
+ if ( !is_email ($user_email) || email_exists ($user_email))
242
  {
243
+ $user_email = oa_social_login_create_rand_email ();
244
+ $user_email = apply_filters ('oa_social_login_filter_new_user_random_email', $user_email);
245
+ $placeholder_email_used = true;
246
  }
247
 
248
  // Setup the user's password.
558
  exit ();
559
  }
560
  }
561
+ else
562
+ {
563
+ oa_social_login_log ('Callback failed, invalid data ' .$result->http_code);
564
+ }
565
+ }
566
+ else
567
+ {
568
+ oa_social_login_log ('Callback failed, HTTP code');
569
  }
570
  }
571
  }
includes/settings.php CHANGED
@@ -22,6 +22,9 @@ $oa_social_login_providers = array(
22
  'dribbble' => array(
23
  'name' => 'Dribbble'
24
  ),
 
 
 
25
  'facebook' => array(
26
  'name' => 'Facebook'
27
  ),
@@ -52,6 +55,9 @@ $oa_social_login_providers = array(
52
  'meetup' => array(
53
  'name' => 'Meetup'
54
  ),
 
 
 
55
  'odnoklassniki' => array(
56
  'name' => 'Odnoklassniki'
57
  ),
22
  'dribbble' => array(
23
  'name' => 'Dribbble'
24
  ),
25
+ 'draugiem' => array(
26
+ 'name' => 'Draugiem'
27
+ ),
28
  'facebook' => array(
29
  'name' => 'Facebook'
30
  ),
55
  'meetup' => array(
56
  'name' => 'Meetup'
57
  ),
58
+ 'mixer' => array(
59
+ 'name' => 'Mixer'
60
+ ),
61
  'odnoklassniki' => array(
62
  'name' => 'Odnoklassniki'
63
  ),
includes/toolbox.php CHANGED
@@ -1,327 +1,327 @@
1
- <?php
2
-
3
- /**
4
- * Initialise
5
- */
6
- function oa_social_login_init ()
7
- {
8
- //Add language file.
9
- if (function_exists ('load_plugin_textdomain'))
10
- {
11
- load_plugin_textdomain ('oa_social_login', false, OA_SOCIAL_LOGIN_BASE_PATH . '/languages/');
12
- }
13
-
14
- //Launch the callback handler.
15
- oa_social_login_callback ();
16
- }
17
-
18
-
19
- /**
20
- * Add Site CSS
21
- **/
22
- function oa_social_login_add_site_css ()
23
- {
24
- if (!wp_style_is ('oa_social_login_site_css', 'registered'))
25
- {
26
- wp_register_style ('oa_social_login_site_css', OA_SOCIAL_LOGIN_PLUGIN_URL . "/assets/css/site.css");
27
- }
28
-
29
- if (did_action ('wp_print_styles'))
30
- {
31
- wp_print_styles ('oa_social_login_site_css');
32
- }
33
- else
34
- {
35
- wp_enqueue_style ('oa_social_login_site_css');
36
- }
37
- }
38
-
39
-
40
- /**
41
- * Check if the current connection is being made over https
42
- */
43
- function oa_social_login_https_on ()
44
- {
45
- if (!empty ($_SERVER ['SERVER_PORT']))
46
- {
47
- if (trim ($_SERVER ['SERVER_PORT']) == '443')
48
- {
49
- return true;
50
- }
51
- }
52
-
53
- if (!empty ($_SERVER ['HTTP_X_FORWARDED_PROTO']))
54
- {
55
- if (strtolower (trim ($_SERVER ['HTTP_X_FORWARDED_PROTO'])) == 'https')
56
- {
57
- return true;
58
- }
59
- }
60
-
61
- if (!empty ($_SERVER ['HTTPS']))
62
- {
63
- if (strtolower (trim ($_SERVER ['HTTPS'])) == 'on' OR trim ($_SERVER ['HTTPS']) == '1')
64
- {
65
- return true;
66
- }
67
- }
68
-
69
- return false;
70
- }
71
-
72
-
73
- /**
74
- * Send a notification to the administrator
75
- */
76
- function oa_social_login_user_notification ($user_id, $user_identity_provider)
77
- {
78
- //Get the user details
79
- $user = new WP_User ($user_id);
80
- $user_login = stripslashes ($user->user_login);
81
-
82
- //The blogname option is escaped with esc_html on the way into the database
83
- $blogname = wp_specialchars_decode (get_option ('blogname'), ENT_QUOTES);
84
-
85
- //Setup Mail Header
86
  $recipient = get_bloginfo ('admin_email');
87
- $subject = '[Social Login] ' . sprintf (__ ('[%s] New User Registration', 'oa_social_login'), $blogname);
88
-
89
- //Setup Mail Body
90
- $body = sprintf (__ ('New user registration on your site %s:', 'oa_social_login'), $blogname) . "\r\n\r\n";
91
- $body .= sprintf (__ ('Username: %s', 'oa_social_login'), $user_login) . "\r\n\r\n";
92
- $body .= sprintf (__ ('Social Network: %s', 'oa_social_login'), $user_identity_provider) . "\r\n";
93
-
94
- //Send Mail
95
- @wp_mail ($recipient, $subject, $body);
96
- }
97
-
98
-
99
- /**
100
- * Return the current url
101
- */
102
- function oa_social_login_get_current_url ()
103
- {
104
- //Extract parts
105
- $request_uri = (isset ($_SERVER ['REQUEST_URI']) ? $_SERVER ['REQUEST_URI'] : $_SERVER ['PHP_SELF']);
106
- $request_protocol = (oa_social_login_https_on () ? 'https' : 'http');
107
- $request_host = (isset ($_SERVER ['HTTP_X_FORWARDED_HOST']) ? $_SERVER ['HTTP_X_FORWARDED_HOST'] : (isset ($_SERVER ['HTTP_HOST']) ? $_SERVER ['HTTP_HOST'] : $_SERVER ['SERVER_NAME']));
108
-
109
- //Port of this request
110
- $request_port = '';
111
-
112
- //We are using a proxy
113
- if (isset ($_SERVER ['HTTP_X_FORWARDED_PORT']))
114
- {
115
- // SERVER_PORT is usually wrong on proxies, don't use it!
116
- $request_port = intval ($_SERVER ['HTTP_X_FORWARDED_PORT']);
117
- }
118
- //Does not seem like a proxy
119
- elseif (isset ($_SERVER ['SERVER_PORT']))
120
- {
121
- $request_port = intval ($_SERVER ['SERVER_PORT']);
122
- }
123
-
124
- // Remove standard ports
125
  $request_port = (!in_array ($request_port, array (80, 443)) ? $request_port : '');
126
-
127
- //Add your own filters
128
- $request_port = apply_filters ('oa_social_login_filter_current_url_port', $request_port);
129
- $request_protocol = apply_filters ('oa_social_login_filter_current_url_protocol', $request_protocol);
130
- $request_host = apply_filters ('oa_social_login_filter_current_url_host', $request_host);
131
- $request_uri = apply_filters ('oa_social_login_filter_current_url_uri', $request_uri);
132
-
133
- //Build url
134
- $current_url = $request_protocol . '://' . $request_host . ( ! empty ($request_port) ? (':'.$request_port) : '') . $request_uri;
135
-
136
- //Remove the oa_social_login_source argument
137
- if (strpos ($current_url, 'oa_social_login_source') !== false)
138
- {
139
- //Break up url
140
- list($url_part, $query_part) = array_pad (explode ('?', $current_url), 2, '');
141
- parse_str ($query_part, $query_vars);
142
-
143
- //Remove oa_social_login_source argument
144
- if (is_array ($query_vars) AND isset ($query_vars ['oa_social_login_source']))
145
- {
146
- unset ($query_vars ['oa_social_login_source']);
147
- }
148
-
149
- //Build new url
150
- $current_url = $url_part . ((is_array ($query_vars) AND count ($query_vars) > 0) ? ('?' . http_build_query ($query_vars)) : '');
151
- }
152
-
153
- //Apply filters
154
- $current_url = apply_filters ('oa_social_login_filter_current_url', $current_url);
155
-
156
- //Done
157
- return $current_url;
158
- }
159
-
160
-
161
- /**
162
- * Return the list of disabled functions.
163
- */
164
- function oa_social_login_get_disabled_functions ()
165
- {
166
- $disabled_functions = trim (ini_get ('disable_functions'));
167
- if (strlen ($disabled_functions) == 0)
168
- {
169
- $disabled_functions = array ();
170
- }
171
- else
172
- {
173
- $disabled_functions = explode (',', $disabled_functions);
174
- $disabled_functions = array_map ('trim', $disabled_functions);
175
- }
176
- return $disabled_functions;
177
- }
178
-
179
- /**
180
- * Return the URL of the CSS theme
181
- */
182
- function oa_social_login_get_theme_css_url ($theme_id = 0)
183
- {
184
- // Themes are served from the CDN
185
- $cdn_uri = (oa_social_login_https_on () ? 'https://secure.oneallcdn.com' : 'http://public.oneallcdn.com');
186
-
187
- // Build Theme
188
- switch ($theme_id)
189
- {
190
- case '1':
191
- return ($cdn_uri . '/css/api/socialize/themes/wordpress/modern.css');
192
-
193
- case '2':
194
- return ($cdn_uri . '/css/api/socialize/themes/wordpress/small.css');
195
-
196
- default:
197
- return ($cdn_uri . '/css/api/socialize/themes/wordpress/default.css');
198
- }
199
- }
200
-
201
- /**
202
- * Return the current WordPress Version
203
- */
204
- function oa_social_login_get_wp_version ()
205
- {
206
- GLOBAL $wp_version;
207
-
208
- // Version
209
- $version = (isset ($wp_version) ? trim ($wp_version) : '');
210
- if (empty ($wp_version))
211
- {
212
- if (function_exists ('get_bloginfo'))
213
- {
214
- $version = get_bloginfo('version');
215
- }
216
- }
217
-
218
- return (empty ($version) ? '?' : $version);
219
- }
220
-
221
-
222
- /**
223
- * Escape an attribute
224
- */
225
- function oa_social_login_esc_attr ($string)
226
- {
227
- //Available since Wordpress 2.8
228
- if (function_exists ('esc_attr'))
229
- {
230
- return esc_attr ($string);
231
- }
232
- //Deprecated as of Wordpress 2.8
233
- elseif (function_exists ('attribute_escape'))
234
- {
235
- return attribute_escape ($string);
236
- }
237
- return htmlspecialchars ($string);
238
- }
239
-
240
-
241
- /**
242
- * Get the userid for a given token
243
- */
244
- function oa_social_login_get_userid_by_token ($token)
245
- {
246
- GLOBAL $wpdb;
247
-
248
- // Sanitize token.
249
- $token = trim (strval ($token));
250
-
251
- // The token is required.
252
- if (strlen ($token) == 0)
253
- {
254
- return false;
255
- }
256
-
257
- // Read user for this token.
258
- $sql = "SELECT u.ID FROM " . $wpdb->usermeta . " AS um INNER JOIN " . $wpdb->users . " AS u ON (um.user_id=u.ID) WHERE um.meta_key = 'oa_social_login_user_token' AND um.meta_value=%s";
259
- return $wpdb->get_var ($wpdb->prepare ($sql, $token));
260
- }
261
-
262
-
263
- /**
264
- * Get the token for a given userid
265
- */
266
- function oa_social_login_get_token_by_userid ($userid)
267
- {
268
- GLOBAL $wpdb;
269
- $sql = "SELECT um.meta_value FROM " . $wpdb->usermeta . " AS um INNER JOIN " . $wpdb->users . " AS u ON (um.user_id=u.ID) WHERE um.meta_key = 'oa_social_login_user_token' AND u.ID=%d";
270
- return $wpdb->get_var ($wpdb->prepare ($sql, $userid));
271
- }
272
-
273
-
274
- /**
275
- * Create a random email
276
- */
277
- function oa_social_login_create_rand_email ()
278
- {
279
- do
280
- {
281
- //Create a random email.
282
- $email = md5 (uniqid (wp_rand (10000, 99000))) . "@example.com";
283
-
284
- //Allow it to be customized.
285
- $email = apply_filters ('oa_social_login_filter_create_random_email', $email);
286
- }
287
- while (email_exists ($email));
288
-
289
- //Done
290
- return $email;
291
- }
292
-
293
-
294
- /**
295
- * Check if a BuddyPress user has uploaded an avatar
296
- */
297
- function oa_social_login_has_bp_user_uploaded_avatar ($user_id)
298
- {
299
- $has_bp_user_uploaded_avatar = false;
300
-
301
- // Use build-in function
302
- if (function_exists ('bp_get_user_has_avatar'))
303
- {
304
- $has_bp_user_uploaded_avatar = bp_get_user_has_avatar ($user_id);
305
- }
306
- // Do custom processing
307
- else
308
- {
309
- // Make sure we can actually do this
310
- if (function_exists ('bp_core_fetch_avatar') && function_exists ('bp_core_avatar_default'))
311
- {
312
- // Fetch the custom BuddyPress avatar for this user
313
- $bp_user_avatar = strtolower (trim (strval (bp_core_fetch_avatar (array ('item_id' => $user_id, 'no_grav' => true, 'html' => false, 'type' => 'full')))));
314
-
315
- // Fetch the default BuddyPress avatar
316
- $bp_default_avatar = strtolower (trim (strval (bp_core_avatar_default ('local'))));
317
-
318
- // Custom Avatar?
319
- $has_bp_user_uploaded_avatar = (($bp_user_avatar == $bp_default_avatar) ? false : true);
320
-
321
- // Done
322
- $has_bp_user_uploaded_avatar = apply_filters('bp_get_user_has_avatar', $has_bp_user_uploaded_avatar, $user_id);
323
- }
324
- }
325
-
326
- return $has_bp_user_uploaded_avatar;
327
  }
1
+ <?php
2
+
3
+ /**
4
+ * Initialise
5
+ */
6
+ function oa_social_login_init ()
7
+ {
8
+ //Add language file.
9
+ if (function_exists ('load_plugin_textdomain'))
10
+ {
11
+ load_plugin_textdomain ('oa_social_login', false, OA_SOCIAL_LOGIN_BASE_PATH . '/languages/');
12
+ }
13
+
14
+ //Launch the callback handler.
15
+ oa_social_login_callback ();
16
+ }
17
+
18
+
19
+ /**
20
+ * Add Site CSS
21
+ **/
22
+ function oa_social_login_add_site_css ()
23
+ {
24
+ if (!wp_style_is ('oa_social_login_site_css', 'registered'))
25
+ {
26
+ wp_register_style ('oa_social_login_site_css', OA_SOCIAL_LOGIN_PLUGIN_URL . "/assets/css/site.css");
27
+ }
28
+
29
+ if (did_action ('wp_print_styles'))
30
+ {
31
+ wp_print_styles ('oa_social_login_site_css');
32
+ }
33
+ else
34
+ {
35
+ wp_enqueue_style ('oa_social_login_site_css');
36
+ }
37
+ }
38
+
39
+
40
+ /**
41
+ * Check if the current connection is being made over https
42
+ */
43
+ function oa_social_login_https_on ()
44
+ {
45
+ if (!empty ($_SERVER ['SERVER_PORT']))
46
+ {
47
+ if (trim ($_SERVER ['SERVER_PORT']) == '443')
48
+ {
49
+ return true;
50
+ }
51
+ }
52
+
53
+ if (!empty ($_SERVER ['HTTP_X_FORWARDED_PROTO']))
54
+ {
55
+ if (strtolower (trim ($_SERVER ['HTTP_X_FORWARDED_PROTO'])) == 'https')
56
+ {
57
+ return true;
58
+ }
59
+ }
60
+
61
+ if (!empty ($_SERVER ['HTTPS']))
62
+ {
63
+ if (strtolower (trim ($_SERVER ['HTTPS'])) == 'on' OR trim ($_SERVER ['HTTPS']) == '1')
64
+ {
65
+ return true;
66
+ }
67
+ }
68
+
69
+ return false;
70
+ }
71
+
72
+
73
+ /**
74
+ * Send a notification to the administrator
75
+ */
76
+ function oa_social_login_user_notification ($user_id, $user_identity_provider)
77
+ {
78
+ //Get the user details
79
+ $user = new WP_User ($user_id);
80
+ $user_login = stripslashes ($user->user_login);
81
+
82
+ //The blogname option is escaped with esc_html on the way into the database
83
+ $blogname = wp_specialchars_decode (get_option ('blogname'), ENT_QUOTES);
84
+
85
+ //Setup Mail Header
86
  $recipient = get_bloginfo ('admin_email');
87
+ $subject = '[Social Login] ' . sprintf (__ ('[%s] New User Registration', 'oa_social_login'), $blogname);
88
+
89
+ //Setup Mail Body
90
+ $body = sprintf (__ ('New user registration on your site %s:', 'oa_social_login'), $blogname) . "\r\n\r\n";
91
+ $body .= sprintf (__ ('Username: %s', 'oa_social_login'), $user_login) . "\r\n\r\n";
92
+ $body .= sprintf (__ ('Social Network: %s', 'oa_social_login'), $user_identity_provider) . "\r\n";
93
+
94
+ //Send Mail
95
+ @wp_mail ($recipient, $subject, $body);
96
+ }
97
+
98
+
99
+ /**
100
+ * Return the current url
101
+ */
102
+ function oa_social_login_get_current_url ()
103
+ {
104
+ //Extract parts
105
+ $request_uri = (isset ($_SERVER ['REQUEST_URI']) ? $_SERVER ['REQUEST_URI'] : $_SERVER ['PHP_SELF']);
106
+ $request_protocol = (oa_social_login_https_on () ? 'https' : 'http');
107
+ $request_host = (isset ($_SERVER ['HTTP_X_FORWARDED_HOST']) ? $_SERVER ['HTTP_X_FORWARDED_HOST'] : (isset ($_SERVER ['HTTP_HOST']) ? $_SERVER ['HTTP_HOST'] : $_SERVER ['SERVER_NAME']));
108
+
109
+ //Port of this request
110
+ $request_port = '';
111
+
112
+ //We are using a proxy
113
+ if (isset ($_SERVER ['HTTP_X_FORWARDED_PORT']))
114
+ {
115
+ // SERVER_PORT is usually wrong on proxies, don't use it!
116
+ $request_port = intval ($_SERVER ['HTTP_X_FORWARDED_PORT']);
117
+ }
118
+ //Does not seem like a proxy
119
+ elseif (isset ($_SERVER ['SERVER_PORT']))
120
+ {
121
+ $request_port = intval ($_SERVER ['SERVER_PORT']);
122
+ }
123
+
124
+ // Remove standard ports
125
  $request_port = (!in_array ($request_port, array (80, 443)) ? $request_port : '');
126
+
127
+ //Add your own filters
128
+ $request_port = apply_filters ('oa_social_login_filter_current_url_port', $request_port);
129
+ $request_protocol = apply_filters ('oa_social_login_filter_current_url_protocol', $request_protocol);
130
+ $request_host = apply_filters ('oa_social_login_filter_current_url_host', $request_host);
131
+ $request_uri = apply_filters ('oa_social_login_filter_current_url_uri', $request_uri);
132
+
133
+ //Build url
134
+ $current_url = $request_protocol . '://' . $request_host . ( ! empty ($request_port) ? (':'.$request_port) : '') . $request_uri;
135
+
136
+ //Remove the oa_social_login_source argument
137
+ if (strpos ($current_url, 'oa_social_login_source') !== false)
138
+ {
139
+ //Break up url
140
+ list($url_part, $query_part) = array_pad (explode ('?', $current_url), 2, '');
141
+ parse_str ($query_part, $query_vars);
142
+
143
+ //Remove oa_social_login_source argument
144
+ if (is_array ($query_vars) AND isset ($query_vars ['oa_social_login_source']))
145
+ {
146
+ unset ($query_vars ['oa_social_login_source']);
147
+ }
148
+
149
+ //Build new url
150
+ $current_url = $url_part . ((is_array ($query_vars) AND count ($query_vars) > 0) ? ('?' . http_build_query ($query_vars)) : '');
151
+ }
152
+
153
+ //Apply filters
154
+ $current_url = apply_filters ('oa_social_login_filter_current_url', $current_url);
155
+
156
+ //Done
157
+ return $current_url;
158
+ }
159
+
160
+
161
+ /**
162
+ * Return the list of disabled functions.
163
+ */
164
+ function oa_social_login_get_disabled_functions ()
165
+ {
166
+ $disabled_functions = trim (ini_get ('disable_functions'));
167
+ if (strlen ($disabled_functions) == 0)
168
+ {
169
+ $disabled_functions = array ();
170
+ }
171
+ else
172
+ {
173
+ $disabled_functions = explode (',', $disabled_functions);
174
+ $disabled_functions = array_map ('trim', $disabled_functions);
175
+ }
176
+ return $disabled_functions;
177
+ }
178
+
179
+ /**
180
+ * Return the URL of the CSS theme
181
+ */
182
+ function oa_social_login_get_theme_css_url ($theme_id = 0)
183
+ {
184
+ // Themes are served from the CDN
185
+ $cdn_uri = (oa_social_login_https_on () ? 'https://secure.oneallcdn.com' : 'http://public.oneallcdn.com');
186
+
187
+ // Build Theme
188
+ switch ($theme_id)
189
+ {
190
+ case '1':
191
+ return ($cdn_uri . '/css/api/socialize/themes/wordpress/modern.css');
192
+
193
+ case '2':
194
+ return ($cdn_uri . '/css/api/socialize/themes/wordpress/small.css');
195
+
196
+ default:
197
+ return ($cdn_uri . '/css/api/socialize/themes/wordpress/default.css');
198
+ }
199
+ }
200
+
201
+ /**
202
+ * Return the current WordPress Version
203
+ */
204
+ function oa_social_login_get_wp_version ()
205
+ {
206
+ GLOBAL $wp_version;
207
+
208
+ // Version
209
+ $version = (isset ($wp_version) ? trim ($wp_version) : '');
210
+ if (empty ($wp_version))
211
+ {
212
+ if (function_exists ('get_bloginfo'))
213
+ {
214
+ $version = get_bloginfo('version');
215
+ }
216
+ }
217
+
218
+ return (empty ($version) ? '?' : $version);
219
+ }
220
+
221
+
222
+ /**
223
+ * Escape an attribute
224
+ */
225
+ function oa_social_login_esc_attr ($string)
226
+ {
227
+ //Available since Wordpress 2.8
228
+ if (function_exists ('esc_attr'))
229
+ {
230
+ return esc_attr ($string);
231
+ }
232
+ //Deprecated as of Wordpress 2.8
233
+ elseif (function_exists ('attribute_escape'))
234
+ {
235
+ return attribute_escape ($string);
236
+ }
237
+ return htmlspecialchars ($string);
238
+ }
239
+
240
+
241
+ /**
242
+ * Get the userid for a given token
243
+ */
244
+ function oa_social_login_get_userid_by_token ($token)
245
+ {
246
+ GLOBAL $wpdb;
247
+
248
+ // Sanitize token.
249
+ $token = trim (strval ($token));
250
+
251
+ // The token is required.
252
+ if (strlen ($token) == 0)
253
+ {
254
+ return false;
255
+ }
256
+
257
+ // Read user for this token.
258
+ $sql = "SELECT u.ID FROM " . $wpdb->usermeta . " AS um INNER JOIN " . $wpdb->users . " AS u ON (um.user_id=u.ID) WHERE um.meta_key = 'oa_social_login_user_token' AND um.meta_value=%s";
259
+ return $wpdb->get_var ($wpdb->prepare ($sql, $token));
260
+ }
261
+
262
+
263
+ /**
264
+ * Get the token for a given userid
265
+ */
266
+ function oa_social_login_get_token_by_userid ($userid)
267
+ {
268
+ GLOBAL $wpdb;
269
+ $sql = "SELECT um.meta_value FROM " . $wpdb->usermeta . " AS um INNER JOIN " . $wpdb->users . " AS u ON (um.user_id=u.ID) WHERE um.meta_key = 'oa_social_login_user_token' AND u.ID=%d";
270
+ return $wpdb->get_var ($wpdb->prepare ($sql, $userid));
271
+ }
272
+
273
+
274
+ /**
275
+ * Create a random email
276
+ */
277
+ function oa_social_login_create_rand_email ()
278
+ {
279
+ do
280
+ {
281
+ //Create a random email.
282
+ $email = md5 (uniqid (wp_rand (10000, 99000))) . "@example.com";
283
+
284
+ //Allow it to be customized.
285
+ $email = apply_filters ('oa_social_login_filter_create_random_email', $email);
286
+ }
287
+ while (email_exists ($email));
288
+
289
+ //Done
290
+ return $email;
291
+ }
292
+
293
+
294
+ /**
295
+ * Check if a BuddyPress user has uploaded an avatar
296
+ */
297
+ function oa_social_login_has_bp_user_uploaded_avatar ($user_id)
298
+ {
299
+ $has_bp_user_uploaded_avatar = false;
300
+
301
+ // Use build-in function
302
+ if (function_exists ('bp_get_user_has_avatar'))
303
+ {
304
+ $has_bp_user_uploaded_avatar = bp_get_user_has_avatar ($user_id);
305
+ }
306
+ // Do custom processing
307
+ else
308
+ {
309
+ // Make sure we can actually do this
310
+ if (function_exists ('bp_core_fetch_avatar') && function_exists ('bp_core_avatar_default'))
311
+ {
312
+ // Fetch the custom BuddyPress avatar for this user
313
+ $bp_user_avatar = strtolower (trim (strval (bp_core_fetch_avatar (array ('item_id' => $user_id, 'no_grav' => true, 'html' => false, 'type' => 'full')))));
314
+
315
+ // Fetch the default BuddyPress avatar
316
+ $bp_default_avatar = strtolower (trim (strval (bp_core_avatar_default ('local'))));
317
+
318
+ // Custom Avatar?
319
+ $has_bp_user_uploaded_avatar = (($bp_user_avatar == $bp_default_avatar) ? false : true);
320
+
321
+ // Done
322
+ $has_bp_user_uploaded_avatar = apply_filters('bp_get_user_has_avatar', $has_bp_user_uploaded_avatar, $user_id);
323
+ }
324
+ }
325
+
326
+ return $has_bp_user_uploaded_avatar;
327
  }
oa-social-login.php CHANGED
@@ -2,16 +2,16 @@
2
  /*
3
  Plugin Name: Social Login
4
  Plugin URI: http://www.oneall.com/
5
- Description: Social Login allows your users to <strong>comment, login and register with 35+ social networks</strong> like Twitter, Facebook, LinkedIn, Instagram, Вконтакте, Google or Yahoo.
6
- Version: 5.4.3
7
- Author: OneAll - Social Network Integration <support@oneall.com>
8
- Author URI: http://www.oneall.com/
9
  License: GPL2
10
  */
11
 
12
  define ('OA_SOCIAL_LOGIN_PLUGIN_URL', plugins_url () . '/' . basename (dirname (__FILE__)));
13
  define ('OA_SOCIAL_LOGIN_BASE_PATH', dirname (plugin_basename (__FILE__)));
14
- define ('OA_SOCIAL_LOGIN_VERSION', '5.4.3');
15
 
16
  /**
17
  * Check technical requirements before activating the plugin (Wordpress 3.0 or newer required)
@@ -51,6 +51,17 @@ function oa_social_login_add_setup_link ($links, $file)
51
  add_filter ('plugin_action_links', 'oa_social_login_add_setup_link', 10, 2);
52
 
53
 
 
 
 
 
 
 
 
 
 
 
 
54
  /**
55
  * This file only has to be included for versions before 3.1.
56
  * Deprecated since version 3.1, the functions are included by default
@@ -64,6 +75,7 @@ if (!function_exists ('email_exists'))
64
  /**
65
  * Include required files
66
  */
 
67
  require_once(dirname (__FILE__) . '/includes/settings.php');
68
  require_once(dirname (__FILE__) . '/includes/communication.php');
69
  require_once(dirname (__FILE__) . '/includes/toolbox.php');
@@ -74,5 +86,6 @@ require_once(dirname (__FILE__) . '/includes/widget.php');
74
 
75
  /**
76
  * Initialise
 
77
  */
78
- add_action ('init', 'oa_social_login_init', 9);
2
  /*
3
  Plugin Name: Social Login
4
  Plugin URI: http://www.oneall.com/
5
+ Description: Social Login allows your users to <strong>comment, login and register with 40+ social networks</strong> like Twitter, Facebook, LinkedIn, Instagram, Вконтакте, Google or Yahoo.
6
+ Version: 5.4.4
7
+ Author: OneAll Social Login <support@oneall.com>
8
+ Author URI: https://www.oneall.com/services/social-network-integration/social-login/
9
  License: GPL2
10
  */
11
 
12
  define ('OA_SOCIAL_LOGIN_PLUGIN_URL', plugins_url () . '/' . basename (dirname (__FILE__)));
13
  define ('OA_SOCIAL_LOGIN_BASE_PATH', dirname (plugin_basename (__FILE__)));
14
+ define ('OA_SOCIAL_LOGIN_VERSION', '5.4.4');
15
 
16
  /**
17
  * Check technical requirements before activating the plugin (Wordpress 3.0 or newer required)
51
  add_filter ('plugin_action_links', 'oa_social_login_add_setup_link', 10, 2);
52
 
53
 
54
+ /**
55
+ * Log
56
+ */
57
+ function oa_social_login_log ($message)
58
+ {
59
+ if (defined ('WP_DEBUG_LOG') && WP_DEBUG_LOG)
60
+ {
61
+ error_log('[OneAll Social Login] '.date("d.m.Y G:i").' : '.print_r( $message, true ));
62
+ }
63
+ }
64
+
65
  /**
66
  * This file only has to be included for versions before 3.1.
67
  * Deprecated since version 3.1, the functions are included by default
75
  /**
76
  * Include required files
77
  */
78
+
79
  require_once(dirname (__FILE__) . '/includes/settings.php');
80
  require_once(dirname (__FILE__) . '/includes/communication.php');
81
  require_once(dirname (__FILE__) . '/includes/toolbox.php');
86
 
87
  /**
88
  * Initialise
89
+ * Load Social Login > 10 for BuddyPress compatibility (bp_init=10).
90
  */
91
+ add_action ('init', 'oa_social_login_init', 11);
readme.txt CHANGED
@@ -2,17 +2,17 @@
2
  Contributors: OneAll.com, ClaudeSchlesser
3
  Tags: social login, social network login, social connect, facebook login, twitter login, linkedin login
4
  Requires at least: 3.0
5
- Tested up to: 4.9.7
6
- Stable tag: 5.4.3
7
  License: GPLv2 or later
8
 
9
- Social Login is fully GDPR compliant and allows your users to login, register and comment with 35+ Social Networks.
10
 
11
  == Description ==
12
 
13
  = Social Login Plugin =
14
 
15
- Social Login is a **professionally developed** and free Wordpress plugin that allows your visitors to **comment, login and register with 30+ Social Networks** like for example Facebook, Twitter, Google, LinkedIn, PayPal, LiveJournal, Instagram, Вконтакте or Yahoo amongst other.
16
 
17
  **Data Protection Guarantee**<br />
18
  Social Login is fully compliant with all European and U.S. data protection laws. As required by the General Data Protection Regulation (GDPR) the OneAll Terms of Service include a Data Processing Agreement that we can countersign on request.
@@ -42,6 +42,7 @@ You can easily configure which social accounts to enable/disable for login and o
42
  * Blogger
43
  * Discord
44
  * Disqus
 
45
  * Dribbble
46
  * Facebook
47
  * Foursquare
@@ -53,6 +54,7 @@ You can easily configure which social accounts to enable/disable for login and o
53
  * LiveJournal
54
  * Mail.ru
55
  * Meetup
 
56
  * Odnoklassniki
57
  * OpenID
58
  * PayPal
@@ -76,9 +78,9 @@ You can easily configure which social accounts to enable/disable for login and o
76
  * YouTube
77
 
78
  **Professionally Developed and Maintained**
79
- Social Login is maintained by [OneAll](http://www.oneall.com), a technology company offering a set of web-delivered tools to simplify the integration of 30+ social networks into business and personal websites and apps.
80
 
81
- The OneAll API unifies 30+ Social Networks and consolidates the most powerful social network features in a single solution. You can work with multiple social networks at once and you will obtain a standardized field structure for data received from any of the social networks. Save time and development resources and focus on your core business.
82
 
83
  == Installation ==
84
 
@@ -148,6 +150,13 @@ http://docs.oneall.com/plugins/guide/social-login-wordpress/
148
 
149
  == Changelog ==
150
 
 
 
 
 
 
 
 
151
  = 5.4.3 =
152
  * Warning missing quotes fixed
153
 
2
  Contributors: OneAll.com, ClaudeSchlesser
3
  Tags: social login, social network login, social connect, facebook login, twitter login, linkedin login
4
  Requires at least: 3.0
5
+ Tested up to: 5.2
6
+ Stable tag: 5.4.4
7
  License: GPLv2 or later
8
 
9
+ Social Login allows your users to login, register and comment with 40+ Social Networks. Professional development and support included.
10
 
11
  == Description ==
12
 
13
  = Social Login Plugin =
14
 
15
+ Social Login is a **professionally developed** and free Wordpress plugin that allows your visitors to **comment, login and register with 40+ Social Networks** like for example Facebook, Twitter, Google, LinkedIn, PayPal, LiveJournal, Instagram, Вконтакте or Yahoo amongst other.
16
 
17
  **Data Protection Guarantee**<br />
18
  Social Login is fully compliant with all European and U.S. data protection laws. As required by the General Data Protection Regulation (GDPR) the OneAll Terms of Service include a Data Processing Agreement that we can countersign on request.
42
  * Blogger
43
  * Discord
44
  * Disqus
45
+ * Draugiem
46
  * Dribbble
47
  * Facebook
48
  * Foursquare
54
  * LiveJournal
55
  * Mail.ru
56
  * Meetup
57
+ * Mixer
58
  * Odnoklassniki
59
  * OpenID
60
  * PayPal
78
  * YouTube
79
 
80
  **Professionally Developed and Maintained**
81
+ Social Login is maintained by [OneAll](http://www.oneall.com), a technology company offering a set of web-delivered tools to simplify the integration of 40+ social networks into business and personal websites and apps.
82
 
83
+ The OneAll API unifies 40+ Social Networks and consolidates the most powerful social network features in a single solution. You can work with multiple social networks at once and you will obtain a standardized field structure for data received from any of the social networks. Save time and development resources and focus on your core business.
84
 
85
  == Installation ==
86
 
150
 
151
  == Changelog ==
152
 
153
+ = 5.4.4 =
154
+ * Social Network "Draugiem" added
155
+ * Social Network "Mixer" added
156
+ * Comment approval fixed
157
+ * New hooks added
158
+ * PHP 7.2 fixes
159
+
160
  = 5.4.3 =
161
  * Warning missing quotes fixed
162