User Role Editor - Version 3.0

Version Description

  • 06.02.2011
  • Compatibility with WordPress 3.1 Release Candidate 3 and real multi-site feature are provided.
  • Role capabilities list are sorted now in the alphabetical order. Easier to find - easier to manage.
  • Code fix: allows to not lose new custom capability if it is added to other than 'Administrator' role. Thanks to Marcin for the contribution to the code of this plugin.
  • Under multi-site environment:
  • 1) URE has additional option 'Apply to All Sites' which allows you to apply updates to the selected role at all sites of your network. If some site has not such role, it will be added. You should know, that this option works for the role update only. All other actions as 'Add' or 'Delete' role still works for the currently selected blog/site only.
  • 2) URE plugin settings page is available only to user with network superadministrator rights.
Download this release

Release Info

Developer shinephp
Plugin Icon 128x128 User Role Editor
Version 3.0
Comparing to
See all releases

Code changes from version 2.2.2 to 3.0

Files changed (10) hide show
  1. images/cartaca.png +0 -0
  2. lang/ure-tr.mo +0 -0
  3. lang/ure-tr.po +225 -291
  4. lang/ure.mo +0 -0
  5. lang/ure.pot +155 -145
  6. readme.txt +22 -19
  7. screenshot-2.png +0 -0
  8. ure-lib.php +164 -50
  9. ure-options.php +99 -81
  10. user-role-editor.php +50 -23
images/cartaca.png ADDED
Binary file
lang/ure-tr.mo CHANGED
Binary file
lang/ure-tr.po CHANGED
@@ -1,563 +1,497 @@
1
  msgid ""
2
  msgstr ""
3
- "Project-Id-Version: User Role Editor 2.0\n"
4
  "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2010-11-07 16:27+0700\n"
6
  "PO-Revision-Date: \n"
7
- "Last-Translator: Vladimir <vladimir@shinephp.com>\n"
8
- "Language-Team: ShinePHP.com <vladimir@shinephp.com>\n"
9
  "MIME-Version: 1.0\n"
10
- "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
  "X-Poedit-Language: Turkish\n"
13
  "X-Poedit-Country: TURKEY\n"
14
  "X-Poedit-SourceCharset: utf-8\n"
15
  "X-Poedit-KeywordsList: __;_e\n"
16
- "X-Poedit-Basepath: .\n"
17
- "X-Poedit-SearchPath-0: ..\n"
18
 
19
- #: ../ure-options.php:112
20
  msgid "Backup record is created for the current role capabilities"
21
- msgstr "Geçerli Yetki İçin Yedek Oluşturuldu"
22
 
23
- #: ../ure-options.php:121
24
  msgid "Role"
25
- msgstr "Yetki"
26
 
27
- #: ../ure-options.php:121
28
  msgid "is updated successfully"
29
  msgstr "başarıyla güncellendi"
30
 
31
- #: ../ure-options.php:165
32
  msgid "About this Plugin:"
33
- msgstr "Plugin Hakkında"
34
 
35
- #: ../ure-options.php:166
36
  msgid "Author's website"
37
- msgstr "Yapımcının Websitesi"
38
 
39
- #: ../ure-options.php:167
40
  msgid "Plugin webpage"
41
- msgstr "Plugin Anasayfası"
42
 
43
- #: ../ure-options.php:168
44
  #: ../user-role-editor.php:206
45
  msgid "Changelog"
46
- msgstr "Değişiklikler"
47
 
48
- #: ../ure-options.php:169
49
  msgid "FAQ"
50
  msgstr "SSS"
51
 
52
- #: ../ure-options.php:170
53
  msgid "Donate"
54
- msgstr "Bağış Yap"
55
-
56
- #: ../ure-options.php:172
57
- msgid "More plugins from"
58
- msgstr "Daha Fazla Plugin"
59
 
60
- #: ../ure-options.php:175
61
  msgid "Greetings:"
62
- msgstr "Teşekkürler"
63
 
64
- #: ../ure-options.php:176
65
  msgid "It's me, the author"
66
- msgstr "O benim, yapımcı"
67
 
68
- #: ../ure-options.php:177
69
  msgid "For the help with Belorussian translation"
70
- msgstr "Belorusya çeviri yardımı için"
71
-
72
- #: ../ure-options.php:178
73
- msgid "For the help with Brasilian translation"
74
- msgstr "Portekizce çeviri yardımı için"
75
 
76
- #: ../ure-options.php:179
77
- msgid "For the help with Chinese translation"
78
- msgstr "Japonca çeviri yardımı için"
79
-
80
- #: ../ure-options.php:180
81
- msgid "For the help with Dutch translation"
82
- msgstr "Flemenkçe çeviri yardımı için"
83
-
84
- #: ../ure-options.php:181
85
  msgid "For the help with French translation"
86
- msgstr "Fransızca çeviri yardımı için"
87
 
88
- #: ../ure-options.php:182
89
  msgid "For the help with German translation"
90
- msgstr "Almanca çeviri yardımı için"
91
 
92
- #: ../ure-options.php:183
93
  msgid "For the help with Hungarian translation"
94
- msgstr "Macarca çeviri yardımı için"
95
 
96
- #: ../ure-options.php:184
97
- #: ../ure-options.php:185
98
  msgid "For the help with Italian translation"
99
- msgstr "İtalyanca çeviri yardımı için"
100
 
101
- #: ../ure-options.php:186
102
  msgid "For the help with Japanese translation"
103
- msgstr "Japonca çeviri yardımı için"
104
-
105
- #: ../ure-options.php:187
106
- msgid "For the help with Persian translation"
107
- msgstr "Farsça çeviri yardımı için"
108
 
109
- #: ../ure-options.php:188
110
  msgid "For the help with Polish translation"
111
- msgstr "Lehçe(Polonyaca) çeviri yardımı için"
112
 
113
- #: ../ure-options.php:189
114
  msgid "For the help with Spanish translation"
115
- msgstr "İspanyolca çeviri yardımı için"
116
-
117
- #: ../ure-options.php:190
118
- msgid "For the help with Turkish translation"
119
- msgstr "Türk çeviri yardımı için"
120
 
121
- #: ../ure-options.php:191
122
  msgid "For the code to hide administrator role"
123
- msgstr "Admin yetkilerini gizleyen kodlar için"
124
 
125
- #: ../ure-options.php:192
126
  msgid "Do you wish to see your name with link to your site here? You are welcome! Your help with translation and new ideas are very appreciated."
127
- msgstr "Sitenizin linkiyle birlikte isminizi burada görmek istermisiniz? Hoşgeldiniz! Yeni çeviriler ve yeni fikirleriniz bizleri mutlu edecektir."
128
 
129
- #: ../ure-options.php:208
130
  msgid "Role Name can not be empty!"
131
- msgstr "Yetki İsmi Boş Bırakılamaz!"
132
 
133
- #: ../ure-options.php:212
134
  msgid "Role Name must contain latin characters and digits only!"
135
- msgstr "Yetki ismi latin karakterler ve rakamlardan oluşmalıdır!"
136
 
137
- #: ../ure-options.php:217
138
- #: ../ure-options.php:344
139
  msgid "Delete Role"
140
- msgstr "Yetkiyi Sil"
141
 
142
- #: ../ure-options.php:219
143
  msgid "Change Default Role"
144
- msgstr "Geçerli Yetkiyi Değiştir"
145
 
146
- #: ../ure-options.php:221
147
- #: ../ure-options.php:304
148
  msgid "Restore Roles from backup copy"
149
- msgstr "Yetkileri yedek dosyasından geri yükle"
150
 
151
- #: ../ure-options.php:223
152
  msgid "Please confirm to continue"
153
- msgstr "Devam etmek için onaylayın"
154
 
155
- #: ../ure-options.php:248
156
  #, php-format
157
  msgid "Role \"%s\" update: please confirm to continue"
158
- msgstr "Yetki \"%s\" güncellendi: devam etmek için onaylayın"
159
 
160
- #: ../ure-options.php:256
161
  msgid "Select Role and change its capabilities list"
162
- msgstr "Seviye Seçin ve listeden yetkilerini değiştirin"
163
 
164
- #: ../ure-options.php:260
165
  msgid "Select Role:"
166
- msgstr "Seviye Seç"
167
 
168
- #: ../ure-options.php:302
169
  msgid "Update"
170
  msgstr "Güncelle"
171
 
172
- #: ../ure-options.php:302
173
  msgid "Save Changes"
174
- msgstr "Kaydet"
175
 
176
- #: ../ure-options.php:303
177
  msgid "Cancel"
178
  msgstr "İptal"
179
 
180
- #: ../ure-options.php:303
181
  msgid "Cancel not saved changes"
182
- msgstr "Değişiklikler iptal edildi"
183
 
184
- #: ../ure-options.php:304
185
  msgid "Reset"
186
- msgstr "Resetle"
187
 
188
- #: ../ure-options.php:315
189
  msgid "Show capabilities in human readable form"
190
- msgstr "Yetkileri okunabilir şekilde göster"
191
 
192
- #: ../ure-options.php:325
193
  msgid "Add New Role"
194
- msgstr "Yeni Seviye Ekle"
195
 
196
- #: ../ure-options.php:330
197
  msgid "Add"
198
  msgstr "Ekle"
199
 
200
- #: ../ure-options.php:330
201
  msgid "Add New User Role"
202
- msgstr "Yeni Kullanıcı Seviyesi Ekle"
203
 
204
- #: ../ure-options.php:334
 
 
 
 
 
 
 
 
205
  msgid "Default Role for New User"
206
- msgstr "Yeni Kullanıcılar için geçerli seviye"
207
 
208
- #: ../ure-options.php:339
209
  msgid "Change"
210
  msgstr "Değiştir"
211
 
212
- #: ../ure-options.php:339
213
  msgid "Set as Default User Role"
214
- msgstr "Geçerli kullanıcı seviyesi olarak belirle"
215
-
216
- #: ../ure-options.php:349
217
- msgid "Delete"
218
- msgstr "Sil"
219
-
220
- #: ../ure-options.php:349
221
- msgid "Delete User Role"
222
- msgstr "Kullanıcı Yetkisini Sil"
223
 
224
  #: ../user-role-editor.php:38
225
- msgid "User Role Editor requires WordPress 3.0 or newer."
226
- msgstr "Kullanıcı Yetki Editörü WordPress 3.0 yada daha üst sürümünü desteklemektedir."
227
 
228
  #: ../user-role-editor.php:38
229
  msgid "Please update!"
230
- msgstr "Lütfen Güncelleyin!"
231
 
232
  #: ../user-role-editor.php:63
233
  msgid "User Role Editor"
234
- msgstr "Kullanıcı Yetki Seviyeleri"
235
 
236
  #: ../user-role-editor.php:196
237
  msgid "Settings"
238
  msgstr "Ayarlar"
239
 
240
- #: ../ure-lib.php:54
241
  msgid "Error is occur. Please check the log file."
242
- msgstr "Hata oluştu.Log dosyasını inceleyin."
243
 
244
- #: ../ure-lib.php:110
245
  msgid "Database operation error. Check log file."
246
- msgstr "Database işlem hatası oluştu.Log dosyasını inceleyin."
247
 
248
- #: ../ure-lib.php:132
249
  msgid "Roles capabilities are restored from the backup data"
250
- msgstr "Yetkiler yedek dosyasından geri yüklendi."
251
 
252
- #: ../ure-lib.php:134
253
  msgid "No backup data. It is created automatically before the first role data update."
254
- msgstr "Yedek dosyasını bulunamadı.İlk yetki güncellemesinde otomatik olarak oluşturulur."
255
 
256
- #: ../ure-lib.php:175
257
  msgid "Error: Role name must contain latin characters and digits only!"
258
- msgstr "Hata:Yetki ismi sadece latin karakter yada rakamlardan oluşmalıdır!"
259
 
260
- #: ../ure-lib.php:183
261
  msgid "Roles list reading error is encountered"
262
- msgstr "Yetki listesi okunamıyor."
263
 
264
- #: ../ure-lib.php:189
265
  msgid "Error is encountered during new role create operation"
266
- msgstr "Yeni seviye oluşturulurken hata oluştu."
267
 
268
- #: ../ure-lib.php:191
269
  #, php-format
270
  msgid "Role %s is created successfully"
271
- msgstr "%s seviyesi başarıyla oluşturuldu."
272
 
273
- #: ../ure-lib.php:275
274
  msgid "Error encountered during role delete operation"
275
- msgstr "Seviye silinirken hata oluştu."
276
 
277
- #: ../ure-lib.php:277
278
  #, php-format
279
  msgid "Role %s is deleted successfully"
280
- msgstr "%s seviyesi başarıyla silindi"
281
 
282
- #: ../ure-lib.php:295
283
  msgid "Error encountered during default role change operation"
284
- msgstr "Geçerli seviye değişimi sırasında hata oluştu."
285
 
286
- #: ../ure-lib.php:301
287
  #, php-format
288
  msgid "Default role for new users is set to %s successfully"
289
- msgstr "Yeni kullanıcılar için geçerli üye seviyesi %s olarak başarıyla değiştirildi"
290
 
291
- #: ../ure-lib.php:355
292
  msgid "Editor"
293
  msgstr "Editör"
294
 
295
- #: ../ure-lib.php:356
296
  msgid "Author"
297
  msgstr "Yazar"
298
 
299
- #: ../ure-lib.php:357
300
  msgid "Contributor"
301
  msgstr "İçerik Sağlayıcı"
302
 
303
- #: ../ure-lib.php:358
304
  msgid "Subscriber"
305
- msgstr "Abone"
306
 
307
- #: ../ure-lib.php:360
308
  msgid "Switch themes"
309
- msgstr "Tema Seç"
310
 
311
- #: ../ure-lib.php:361
312
  msgid "Edit themes"
313
- msgstr "Tema Düzenle"
314
 
315
- #: ../ure-lib.php:362
316
  msgid "Activate plugins"
317
- msgstr "Pluginleri aktifle"
318
 
319
- #: ../ure-lib.php:363
320
  msgid "Edit plugins"
321
- msgstr "Pluginleri düzenle"
322
 
323
- #: ../ure-lib.php:364
324
  msgid "Edit users"
325
- msgstr "Üyeleri düzenle"
326
 
327
- #: ../ure-lib.php:365
328
  msgid "Edit files"
329
- msgstr "Dosyaları düzenle"
330
 
331
- #: ../ure-lib.php:366
332
  msgid "Manage options"
333
- msgstr "Ayarları yönet"
334
 
335
- #: ../ure-lib.php:367
336
  msgid "Moderate comments"
337
- msgstr "Yorumları onayla"
338
 
339
- #: ../ure-lib.php:368
340
  msgid "Manage categories"
341
- msgstr "Kategorileri düzenle"
342
 
343
- #: ../ure-lib.php:369
344
  msgid "Manage links"
345
- msgstr "Linkleri düzenle"
346
 
347
- #: ../ure-lib.php:370
348
  msgid "Upload files"
349
- msgstr "Dosya Yükle"
350
 
351
- #: ../ure-lib.php:371
352
  msgid "Import"
353
- msgstr "İçe Aktarma"
354
 
355
- #: ../ure-lib.php:372
356
  msgid "Unfiltered html"
357
- msgstr "Filtresiz html"
358
 
359
- #: ../ure-lib.php:373
360
  msgid "Edit posts"
361
- msgstr "Yazıları düzenle"
362
 
363
- #: ../ure-lib.php:374
364
  msgid "Edit others posts"
365
- msgstr "Diğer yazıları düzenle"
366
 
367
- #: ../ure-lib.php:375
368
  msgid "Edit published posts"
369
- msgstr "Yayınlanmış yazıları düzenle"
370
 
371
- #: ../ure-lib.php:376
372
  msgid "Publish posts"
373
- msgstr "Yazıları yayınla"
374
 
375
- #: ../ure-lib.php:377
376
  msgid "Edit pages"
377
- msgstr "Sayfaları düzenle"
378
 
379
- #: ../ure-lib.php:378
380
  msgid "Read"
381
- msgstr "Oku"
382
 
383
- #: ../ure-lib.php:379
384
  msgid "Level 10"
385
  msgstr "Seviye 10"
386
 
387
- #: ../ure-lib.php:380
388
  msgid "Level 9"
389
  msgstr "Seviye 9"
390
 
391
- #: ../ure-lib.php:381
392
  msgid "Level 8"
393
  msgstr "Seviye 8"
394
 
395
- #: ../ure-lib.php:382
396
  msgid "Level 7"
397
  msgstr "Seviye 7"
398
 
399
- #: ../ure-lib.php:383
400
  msgid "Level 6"
401
  msgstr "Seviye 6"
402
 
403
- #: ../ure-lib.php:384
404
  msgid "Level 5"
405
  msgstr "Seviye 5"
406
 
407
- #: ../ure-lib.php:385
408
  msgid "Level 4"
409
  msgstr "Seviye 4"
410
 
411
- #: ../ure-lib.php:386
412
  msgid "Level 3"
413
  msgstr "Seviye 3"
414
 
415
- #: ../ure-lib.php:387
416
  msgid "Level 2"
417
  msgstr "Seviye 2"
418
 
419
- #: ../ure-lib.php:388
420
  msgid "Level 1"
421
  msgstr "Seviye 1"
422
 
423
- #: ../ure-lib.php:389
424
  msgid "Level 0"
425
  msgstr "Seviye 0"
426
 
427
- #: ../ure-lib.php:390
428
  msgid "Edit others pages"
429
- msgstr "Diğerlerinin sayfalarını düzenle"
430
 
431
- #: ../ure-lib.php:391
432
  msgid "Edit published pages"
433
- msgstr "Yayınlanmış sayfaları düzenle"
434
 
435
- #: ../ure-lib.php:392
436
  msgid "Publish pages"
437
- msgstr "Sayfaları Yayınla"
438
 
439
- #: ../ure-lib.php:393
440
  msgid "Delete pages"
441
- msgstr "Sayfaları sil"
442
 
443
- #: ../ure-lib.php:394
444
  msgid "Delete others pages"
445
- msgstr "Diğerlerinin sayfalarını sil"
446
 
447
- #: ../ure-lib.php:395
448
  msgid "Delete published pages"
449
- msgstr "Yayınlanmış sayfaları sil"
450
 
451
- #: ../ure-lib.php:396
452
  msgid "Delete posts"
453
- msgstr "Yazıları sil"
454
 
455
- #: ../ure-lib.php:397
456
  msgid "Delete others posts"
457
- msgstr "Diğerlerinin yazılarını sil"
458
 
459
- #: ../ure-lib.php:398
460
  msgid "Delete published posts"
461
- msgstr "Yayınlanmış yazıları sil"
462
 
463
- #: ../ure-lib.php:399
464
  msgid "Delete private posts"
465
- msgstr "Özel yazıları sil"
466
 
467
- #: ../ure-lib.php:400
468
  msgid "Edit private posts"
469
- msgstr "Özel yazıları düzenle"
470
 
471
- #: ../ure-lib.php:401
472
  msgid "Read private posts"
473
- msgstr "Özel yazıları oku"
474
 
475
- #: ../ure-lib.php:402
476
  msgid "Delete private pages"
477
- msgstr "Özel sayfaları sil"
478
 
479
- #: ../ure-lib.php:403
480
  msgid "Edit private pages"
481
- msgstr "Özel sayfaları düzenle"
482
 
483
- #: ../ure-lib.php:404
484
  msgid "Read private pages"
485
- msgstr "Özel sayfaları oku"
486
 
487
- #: ../ure-lib.php:405
488
  msgid "Delete users"
489
- msgstr "Üyeleri sil"
490
 
491
- #: ../ure-lib.php:406
492
  msgid "Create users"
493
- msgstr "Üye Ekle"
494
 
495
- #: ../ure-lib.php:407
496
  msgid "Unfiltered upload"
497
- msgstr "Filtresiz dosya yükleme"
498
 
499
- #: ../ure-lib.php:408
500
  msgid "Edit dashboard"
501
- msgstr "Admin anasayfasını düzenleme"
502
 
503
- #: ../ure-lib.php:409
504
  msgid "Update plugins"
505
- msgstr "Plugin güncelleme"
506
 
507
- #: ../ure-lib.php:410
508
  msgid "Delete plugins"
509
- msgstr "Plugin silme"
510
 
511
- #: ../ure-lib.php:411
512
  msgid "Install plugins"
513
- msgstr "Plugin yükleme"
514
 
515
- #: ../ure-lib.php:412
516
  msgid "Update themes"
517
- msgstr "Temaları güncelleme"
518
 
519
- #: ../ure-lib.php:413
520
  msgid "Install themes"
521
- msgstr "Tema yükleme"
522
-
523
- #: ../ure-lib.php:414
524
- msgid "Update core"
525
- msgstr "Sistemi update etme"
526
-
527
- #: ../ure-lib.php:415
528
- msgid "List users"
529
- msgstr "Üyeleri listeleme"
530
-
531
- #: ../ure-lib.php:416
532
- msgid "Remove users"
533
- msgstr "Üyeleri atma"
534
-
535
- #: ../ure-lib.php:417
536
- msgid "Add users"
537
- msgstr "Üye ekleme"
538
-
539
- #: ../ure-lib.php:418
540
- msgid "Promote users"
541
- msgstr "Üye seviyelerini değiştirme"
542
-
543
- #: ../ure-lib.php:419
544
- msgid "Edit theme options"
545
- msgstr "Tema ayarlarını düzenleme"
546
-
547
- #: ../ure-lib.php:420
548
- msgid "Delete themes"
549
- msgstr "Tema silme"
550
-
551
- #: ../ure-lib.php:421
552
- msgid "Export"
553
- msgstr "Dışa aktarma(export)"
554
-
555
- #: ../ure-lib.php:442
556
- #: ../ure-lib.php:457
557
- msgid "No items found."
558
- msgstr "Öğe bulunamadı"
559
-
560
- #: ../ure-lib.php:445
561
- msgid "Recent Posts:"
562
- msgstr "Yeni yazılar"
563
 
1
  msgid ""
2
  msgstr ""
3
+ "Project-Id-Version: user-role-editor\n"
4
  "Report-Msgid-Bugs-To: \n"
5
+ "POT-Creation-Date: 2010-06-18 22:21+0700\n"
6
  "PO-Revision-Date: \n"
7
+ "Last-Translator: Can KAYA <can.kaya@kartaca.com>\n"
8
+ "Language-Team: \n"
9
  "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=utf-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
  "X-Poedit-Language: Turkish\n"
13
  "X-Poedit-Country: TURKEY\n"
14
  "X-Poedit-SourceCharset: utf-8\n"
15
  "X-Poedit-KeywordsList: __;_e\n"
16
+ "X-Poedit-Basepath: /home/cankaya/ortak/Gecici/cankaya/pukkalar/pukka/plugins/user-role-editor\n"
17
+ "X-Poedit-SearchPath-0: /home/cankaya/ortak/Gecici/cankaya/pukkalar/pukka/plugins/user-role-editor\n"
18
 
19
+ #: ../ure-options.php:111
20
  msgid "Backup record is created for the current role capabilities"
21
+ msgstr "Güncel rol yeterlilikleri için yedek kayıt yaratıldı"
22
 
23
+ #: ../ure-options.php:120
24
  msgid "Role"
25
+ msgstr "Rol:"
26
 
27
+ #: ../ure-options.php:120
28
  msgid "is updated successfully"
29
  msgstr "başarıyla güncellendi"
30
 
31
+ #: ../ure-options.php:164
32
  msgid "About this Plugin:"
33
+ msgstr "Bu eklenti hakkında:"
34
 
35
+ #: ../ure-options.php:165
36
  msgid "Author's website"
37
+ msgstr "Hazırlayanın websitesi"
38
 
39
+ #: ../ure-options.php:166
40
  msgid "Plugin webpage"
41
+ msgstr "Eklentinin websitesi"
42
 
43
+ #: ../ure-options.php:167
44
  #: ../user-role-editor.php:206
45
  msgid "Changelog"
46
+ msgstr "Changelog"
47
 
48
+ #: ../ure-options.php:168
49
  msgid "FAQ"
50
  msgstr "SSS"
51
 
52
+ #: ../ure-options.php:169
53
  msgid "Donate"
54
+ msgstr "Bağış Yapın"
 
 
 
 
55
 
56
+ #: ../ure-options.php:171
57
  msgid "Greetings:"
58
+ msgstr "Teşekkürlerimle:"
59
 
60
+ #: ../ure-options.php:172
61
  msgid "It's me, the author"
62
+ msgstr "Ben, hazırlayan"
63
 
64
+ #: ../ure-options.php:173
65
  msgid "For the help with Belorussian translation"
66
+ msgstr "Beyaz Rusça tercümesi için"
 
 
 
 
67
 
68
+ #: ../ure-options.php:174
 
 
 
 
 
 
 
 
69
  msgid "For the help with French translation"
70
+ msgstr "Fransızca tercümesi için"
71
 
72
+ #: ../ure-options.php:175
73
  msgid "For the help with German translation"
74
+ msgstr "Almanca tercümesi için"
75
 
76
+ #: ../ure-options.php:176
77
  msgid "For the help with Hungarian translation"
78
+ msgstr "Macarca tercümesi için"
79
 
80
+ #: ../ure-options.php:177
 
81
  msgid "For the help with Italian translation"
82
+ msgstr "İtalyanca tercümesi için"
83
 
84
+ #: ../ure-options.php:178
85
  msgid "For the help with Japanese translation"
86
+ msgstr "Japonca tercümesi için"
 
 
 
 
87
 
88
+ #: ../ure-options.php:179
89
  msgid "For the help with Polish translation"
90
+ msgstr "Lehçe tercümesi için"
91
 
92
+ #: ../ure-options.php:180
93
  msgid "For the help with Spanish translation"
94
+ msgstr "İspanyolca tercümesi için"
 
 
 
 
95
 
96
+ #: ../ure-options.php:181
97
  msgid "For the code to hide administrator role"
98
+ msgstr "Yönetici rolünü saklayan kod katkısı için"
99
 
100
+ #: ../ure-options.php:182
101
  msgid "Do you wish to see your name with link to your site here? You are welcome! Your help with translation and new ideas are very appreciated."
102
+ msgstr "İsminizi websitenize bir link ile birlikte burada görmek ister misiniz? Bu elbette mümkün! Tercüme yardımlarınız ve yeni fikirlerinize her zaman açığım."
103
 
104
+ #: ../ure-options.php:198
105
  msgid "Role Name can not be empty!"
106
+ msgstr "Rol Adı boş bırakılamaz!"
107
 
108
+ #: ../ure-options.php:202
109
  msgid "Role Name must contain latin characters and digits only!"
110
+ msgstr "Rol Adı, yalnızca latin karakterleri ve sayılardan oluşabilir!"
111
 
112
+ #: ../ure-options.php:207
113
+ #: ../ure-options.php:325
114
  msgid "Delete Role"
115
+ msgstr "Rolü Sil"
116
 
117
+ #: ../ure-options.php:209
118
  msgid "Change Default Role"
119
+ msgstr "Varsayılan Rolü Değiştir"
120
 
121
+ #: ../ure-options.php:211
122
+ #: ../ure-options.php:293
123
  msgid "Restore Roles from backup copy"
124
+ msgstr "Rolleri yedekten geri yükle"
125
 
126
+ #: ../ure-options.php:213
127
  msgid "Please confirm to continue"
128
+ msgstr "Devam etmek için lütfen onaylayın"
129
 
130
+ #: ../ure-options.php:238
131
  #, php-format
132
  msgid "Role \"%s\" update: please confirm to continue"
133
+ msgstr "\"%s\" rolü güncellendi: Devam etmek için lütfen onaylayın"
134
 
135
+ #: ../ure-options.php:246
136
  msgid "Select Role and change its capabilities list"
137
+ msgstr "Rolü seçin ve rolün yetki listesini değiştirin"
138
 
139
+ #: ../ure-options.php:250
140
  msgid "Select Role:"
141
+ msgstr "Rolü Seçin:"
142
 
143
+ #: ../ure-options.php:291
144
  msgid "Update"
145
  msgstr "Güncelle"
146
 
147
+ #: ../ure-options.php:291
148
  msgid "Save Changes"
149
+ msgstr "Değişiklikleri Kaydet"
150
 
151
+ #: ../ure-options.php:292
152
  msgid "Cancel"
153
  msgstr "İptal"
154
 
155
+ #: ../ure-options.php:292
156
  msgid "Cancel not saved changes"
157
+ msgstr "Kaydedilmemiş değişiklikleri iptal et"
158
 
159
+ #: ../ure-options.php:293
160
  msgid "Reset"
161
+ msgstr "Geri al"
162
 
163
+ #: ../ure-options.php:304
164
  msgid "Show capabilities in human readable form"
165
+ msgstr "Yetkileri insan tarafından okunabilir biçimde göster"
166
 
167
+ #: ../ure-options.php:315
168
  msgid "Add New Role"
169
+ msgstr "Yeni Rol Ekle"
170
 
171
+ #: ../ure-options.php:320
172
  msgid "Add"
173
  msgstr "Ekle"
174
 
175
+ #: ../ure-options.php:320
176
  msgid "Add New User Role"
177
+ msgstr "Yeni Kullanıcı Rolü Ekle"
178
 
179
+ #: ../ure-options.php:330
180
+ msgid "Delete"
181
+ msgstr "Sil"
182
+
183
+ #: ../ure-options.php:330
184
+ msgid "Delete User Role"
185
+ msgstr "Kullanıcı Rolünü Sil"
186
+
187
+ #: ../ure-options.php:335
188
  msgid "Default Role for New User"
189
+ msgstr "Yeni Kullanıcılar için Varsayılan Rol"
190
 
191
+ #: ../ure-options.php:340
192
  msgid "Change"
193
  msgstr "Değiştir"
194
 
195
+ #: ../ure-options.php:340
196
  msgid "Set as Default User Role"
197
+ msgstr "Varsayılan Kullanıcı Rolü olarak Seç"
 
 
 
 
 
 
 
 
198
 
199
  #: ../user-role-editor.php:38
200
+ msgid "User Role Editor requires WordPress 2.8 or newer."
201
+ msgstr "User Role Editor eklentisi en az WordPress 2.8 sürümüne ihtiyaç duymaktadır."
202
 
203
  #: ../user-role-editor.php:38
204
  msgid "Please update!"
205
+ msgstr "Lütfen güncelleyin!"
206
 
207
  #: ../user-role-editor.php:63
208
  msgid "User Role Editor"
209
+ msgstr "Kullanıcı Rol Editörü"
210
 
211
  #: ../user-role-editor.php:196
212
  msgid "Settings"
213
  msgstr "Ayarlar"
214
 
215
+ #: ../ure-lib.php:52
216
  msgid "Error is occur. Please check the log file."
217
+ msgstr "Bir hata oluştu. Lütfen günlük dosyasını kontrol edin."
218
 
219
+ #: ../ure-lib.php:108
220
  msgid "Database operation error. Check log file."
221
+ msgstr "Veritabanı operasyonu hatası. Günlük dosyasını kontrol edin."
222
 
223
+ #: ../ure-lib.php:130
224
  msgid "Roles capabilities are restored from the backup data"
225
+ msgstr "Rol yetkileri yedek verilerden geri yüklendi"
226
 
227
+ #: ../ure-lib.php:132
228
  msgid "No backup data. It is created automatically before the first role data update."
229
+ msgstr "Henüz yedekleme yapılmamış. İlk yedekleme, ilk rol verisi güncellemesi öncesi otomatik olarak yapılacaktır."
230
 
231
+ #: ../ure-lib.php:173
232
  msgid "Error: Role name must contain latin characters and digits only!"
233
+ msgstr "Hata: Rol adı yalnızca latin karakterleri ve sayılardan oluşabilir."
234
 
235
+ #: ../ure-lib.php:181
236
  msgid "Roles list reading error is encountered"
237
+ msgstr "Rol listesi okunurken hata"
238
 
239
+ #: ../ure-lib.php:187
240
  msgid "Error is encountered during new role create operation"
241
+ msgstr "Yeni rol yaratma işlemi sırasında hata"
242
 
243
+ #: ../ure-lib.php:189
244
  #, php-format
245
  msgid "Role %s is created successfully"
246
+ msgstr "%s rolü başarıyla yaratıldı"
247
 
248
+ #: ../ure-lib.php:273
249
  msgid "Error encountered during role delete operation"
250
+ msgstr "Rol silme işlemi sırasında hata"
251
 
252
+ #: ../ure-lib.php:275
253
  #, php-format
254
  msgid "Role %s is deleted successfully"
255
+ msgstr "%s rolü başarıyla silindi"
256
 
257
+ #: ../ure-lib.php:293
258
  msgid "Error encountered during default role change operation"
259
+ msgstr "Varsayılan rolü değiştirme işlemi sırasında hata"
260
 
261
+ #: ../ure-lib.php:299
262
  #, php-format
263
  msgid "Default role for new users is set to %s successfully"
264
+ msgstr "Yeni kullanıcılar için varsayılan rol %s olarak başarıyla değiştirildi"
265
 
266
+ #: ../ure-lib.php:353
267
  msgid "Editor"
268
  msgstr "Editör"
269
 
270
+ #: ../ure-lib.php:354
271
  msgid "Author"
272
  msgstr "Yazar"
273
 
274
+ #: ../ure-lib.php:355
275
  msgid "Contributor"
276
  msgstr "İçerik Sağlayıcı"
277
 
278
+ #: ../ure-lib.php:356
279
  msgid "Subscriber"
280
+ msgstr "Üye"
281
 
282
+ #: ../ure-lib.php:358
283
  msgid "Switch themes"
284
+ msgstr "Temaları değiştir"
285
 
286
+ #: ../ure-lib.php:359
287
  msgid "Edit themes"
288
+ msgstr "Temaları düzenle"
289
 
290
+ #: ../ure-lib.php:360
291
  msgid "Activate plugins"
292
+ msgstr "Eklentileri aktive et"
293
 
294
+ #: ../ure-lib.php:361
295
  msgid "Edit plugins"
296
+ msgstr "Eklentileri düzenlemek"
297
 
298
+ #: ../ure-lib.php:362
299
  msgid "Edit users"
300
+ msgstr "Kullanıcıları düzenlemek"
301
 
302
+ #: ../ure-lib.php:363
303
  msgid "Edit files"
304
+ msgstr "Dosyaları düzenlemek"
305
 
306
+ #: ../ure-lib.php:364
307
  msgid "Manage options"
308
+ msgstr "Seçenekleri yönetmek"
309
 
310
+ #: ../ure-lib.php:365
311
  msgid "Moderate comments"
312
+ msgstr "Yorumları yönetmek"
313
 
314
+ #: ../ure-lib.php:366
315
  msgid "Manage categories"
316
+ msgstr "Kategorileri yönetmek"
317
 
318
+ #: ../ure-lib.php:367
319
  msgid "Manage links"
320
+ msgstr "Linkleri yönetmek"
321
 
322
+ #: ../ure-lib.php:368
323
  msgid "Upload files"
324
+ msgstr "Dosya yüklemek"
325
 
326
+ #: ../ure-lib.php:369
327
  msgid "Import"
328
+ msgstr "İçeri aktarmak"
329
 
330
+ #: ../ure-lib.php:370
331
  msgid "Unfiltered html"
332
+ msgstr "Filtrelenmemiş HTML"
333
 
334
+ #: ../ure-lib.php:371
335
  msgid "Edit posts"
336
+ msgstr "Yazıları düzenlemek"
337
 
338
+ #: ../ure-lib.php:372
339
  msgid "Edit others posts"
340
+ msgstr "Başkalarının yazılarını düzenlemek"
341
 
342
+ #: ../ure-lib.php:373
343
  msgid "Edit published posts"
344
+ msgstr "Yayınlanmış yazıları düzenlemek"
345
 
346
+ #: ../ure-lib.php:374
347
  msgid "Publish posts"
348
+ msgstr "Yazıları yayınlamak"
349
 
350
+ #: ../ure-lib.php:375
351
  msgid "Edit pages"
352
+ msgstr "Sayfaları düzenlemek"
353
 
354
+ #: ../ure-lib.php:376
355
  msgid "Read"
356
+ msgstr "Okumak"
357
 
358
+ #: ../ure-lib.php:377
359
  msgid "Level 10"
360
  msgstr "Seviye 10"
361
 
362
+ #: ../ure-lib.php:378
363
  msgid "Level 9"
364
  msgstr "Seviye 9"
365
 
366
+ #: ../ure-lib.php:379
367
  msgid "Level 8"
368
  msgstr "Seviye 8"
369
 
370
+ #: ../ure-lib.php:380
371
  msgid "Level 7"
372
  msgstr "Seviye 7"
373
 
374
+ #: ../ure-lib.php:381
375
  msgid "Level 6"
376
  msgstr "Seviye 6"
377
 
378
+ #: ../ure-lib.php:382
379
  msgid "Level 5"
380
  msgstr "Seviye 5"
381
 
382
+ #: ../ure-lib.php:383
383
  msgid "Level 4"
384
  msgstr "Seviye 4"
385
 
386
+ #: ../ure-lib.php:384
387
  msgid "Level 3"
388
  msgstr "Seviye 3"
389
 
390
+ #: ../ure-lib.php:385
391
  msgid "Level 2"
392
  msgstr "Seviye 2"
393
 
394
+ #: ../ure-lib.php:386
395
  msgid "Level 1"
396
  msgstr "Seviye 1"
397
 
398
+ #: ../ure-lib.php:387
399
  msgid "Level 0"
400
  msgstr "Seviye 0"
401
 
402
+ #: ../ure-lib.php:388
403
  msgid "Edit others pages"
404
+ msgstr "Başkalarının sayfalarını düzenlemek"
405
 
406
+ #: ../ure-lib.php:389
407
  msgid "Edit published pages"
408
+ msgstr "Yayınlanmış sayfaları düzenlemek"
409
 
410
+ #: ../ure-lib.php:390
411
  msgid "Publish pages"
412
+ msgstr "Sayfaları yayınlamak"
413
 
414
+ #: ../ure-lib.php:391
415
  msgid "Delete pages"
416
+ msgstr "Sayfaları silmek"
417
 
418
+ #: ../ure-lib.php:392
419
  msgid "Delete others pages"
420
+ msgstr "Başkalarının sayfalarını silmek"
421
 
422
+ #: ../ure-lib.php:393
423
  msgid "Delete published pages"
424
+ msgstr "Yayınlanmış sayfaları silmek"
425
 
426
+ #: ../ure-lib.php:394
427
  msgid "Delete posts"
428
+ msgstr "Yazıları silmek"
429
 
430
+ #: ../ure-lib.php:395
431
  msgid "Delete others posts"
432
+ msgstr "Başkalarının yazılarını silmek"
433
 
434
+ #: ../ure-lib.php:396
435
  msgid "Delete published posts"
436
+ msgstr "Yayınlanmış yazıları silmek"
437
 
438
+ #: ../ure-lib.php:397
439
  msgid "Delete private posts"
440
+ msgstr "Özel yazıları silmek"
441
 
442
+ #: ../ure-lib.php:398
443
  msgid "Edit private posts"
444
+ msgstr "Özel yazıları düzenlemek"
445
 
446
+ #: ../ure-lib.php:399
447
  msgid "Read private posts"
448
+ msgstr "Özel yazıları okumak"
449
 
450
+ #: ../ure-lib.php:400
451
  msgid "Delete private pages"
452
+ msgstr "Özel sayfaları silmek"
453
 
454
+ #: ../ure-lib.php:401
455
  msgid "Edit private pages"
456
+ msgstr "Özel sayfaları düzenlemek"
457
 
458
+ #: ../ure-lib.php:402
459
  msgid "Read private pages"
460
+ msgstr "Özel yazıları okumak"
461
 
462
+ #: ../ure-lib.php:403
463
  msgid "Delete users"
464
+ msgstr "Kullanıcı silmek"
465
 
466
+ #: ../ure-lib.php:404
467
  msgid "Create users"
468
+ msgstr "Kullanıcı yaratmak"
469
 
470
+ #: ../ure-lib.php:405
471
  msgid "Unfiltered upload"
472
+ msgstr "Filtrelenmemiş dosya yüklemek"
473
 
474
+ #: ../ure-lib.php:406
475
  msgid "Edit dashboard"
476
+ msgstr "Paneli düzenlemek"
477
 
478
+ #: ../ure-lib.php:407
479
  msgid "Update plugins"
480
+ msgstr "Eklentileri güncellemek"
481
 
482
+ #: ../ure-lib.php:408
483
  msgid "Delete plugins"
484
+ msgstr "Eklenti silmek"
485
 
486
+ #: ../ure-lib.php:409
487
  msgid "Install plugins"
488
+ msgstr "Eklenti yüklemek"
489
 
490
+ #: ../ure-lib.php:410
491
  msgid "Update themes"
492
+ msgstr "Temaları güncellemek"
493
 
494
+ #: ../ure-lib.php:411
495
  msgid "Install themes"
496
+ msgstr "Temal yüklemek"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
497
 
lang/ure.mo CHANGED
Binary file
lang/ure.pot CHANGED
@@ -2,7 +2,7 @@ msgid ""
2
  msgstr ""
3
  "Project-Id-Version: User Role Editor 2.0\n"
4
  "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2010-11-07 16:34+0700\n"
6
  "PO-Revision-Date: \n"
7
  "Last-Translator: Vladimir <vladimir@shinephp.com>\n"
8
  "Language-Team: ShinePHP.com <vladimir@shinephp.com>\n"
@@ -16,148 +16,145 @@ msgstr ""
16
  "X-Poedit-Basepath: .\n"
17
  "X-Poedit-SearchPath-0: ..\n"
18
 
19
- #: ../ure-options.php:112
20
- msgid "Backup record is created for the current role capabilities"
21
- msgstr ""
22
-
23
- #: ../ure-options.php:121
24
  msgid "Role"
25
  msgstr ""
26
 
27
- #: ../ure-options.php:121
28
  msgid "is updated successfully"
29
  msgstr ""
30
 
31
- #: ../ure-options.php:165
32
  msgid "About this Plugin:"
33
  msgstr ""
34
 
35
- #: ../ure-options.php:166
36
  msgid "Author's website"
37
  msgstr ""
38
 
39
- #: ../ure-options.php:167
40
  msgid "Plugin webpage"
41
  msgstr ""
42
 
43
- #: ../ure-options.php:168
44
- #: ../user-role-editor.php:206
45
  msgid "Changelog"
46
  msgstr ""
47
 
48
- #: ../ure-options.php:169
49
  msgid "FAQ"
50
  msgstr ""
51
 
52
- #: ../ure-options.php:170
53
  msgid "Donate"
54
  msgstr ""
55
 
56
- #: ../ure-options.php:172
57
  msgid "More plugins from"
58
  msgstr ""
59
 
60
- #: ../ure-options.php:175
61
  msgid "Greetings:"
62
  msgstr ""
63
 
64
- #: ../ure-options.php:176
65
  msgid "It's me, the author"
66
  msgstr ""
67
 
68
- #: ../ure-options.php:177
69
  msgid "For the help with Belorussian translation"
70
  msgstr ""
71
 
72
- #: ../ure-options.php:178
73
  msgid "For the help with Brasilian translation"
74
  msgstr ""
75
 
76
- #: ../ure-options.php:179
77
  msgid "For the help with Chinese translation"
78
  msgstr ""
79
 
80
- #: ../ure-options.php:180
81
  msgid "For the help with Dutch translation"
82
  msgstr ""
83
 
84
- #: ../ure-options.php:181
85
  msgid "For the help with French translation"
86
  msgstr ""
87
 
88
- #: ../ure-options.php:182
89
  msgid "For the help with German translation"
90
  msgstr ""
91
 
92
- #: ../ure-options.php:183
93
  msgid "For the help with Hungarian translation"
94
  msgstr ""
95
 
96
- #: ../ure-options.php:184
97
- #: ../ure-options.php:185
98
  msgid "For the help with Italian translation"
99
  msgstr ""
100
 
101
- #: ../ure-options.php:186
102
  msgid "For the help with Japanese translation"
103
  msgstr ""
104
 
105
- #: ../ure-options.php:187
106
  msgid "For the help with Persian translation"
107
  msgstr ""
108
 
109
- #: ../ure-options.php:188
110
  msgid "For the help with Polish translation"
111
  msgstr ""
112
 
113
- #: ../ure-options.php:189
114
  msgid "For the help with Spanish translation"
115
  msgstr ""
116
 
117
- #: ../ure-options.php:190
 
118
  msgid "For the help with Turkish translation"
119
  msgstr ""
120
 
121
- #: ../ure-options.php:191
122
  msgid "For the code to hide administrator role"
123
  msgstr ""
124
 
125
- #: ../ure-options.php:192
126
  msgid "Do you wish to see your name with link to your site here? You are welcome! Your help with translation and new ideas are very appreciated."
127
  msgstr ""
128
 
129
- #: ../ure-options.php:208
130
  msgid "Role Name can not be empty!"
131
  msgstr ""
132
 
133
- #: ../ure-options.php:212
134
  msgid "Role Name must contain latin characters and digits only!"
135
  msgstr ""
136
 
137
- #: ../ure-options.php:217
138
- #: ../ure-options.php:344
139
  msgid "Delete Role"
140
  msgstr ""
141
 
142
- #: ../ure-options.php:219
143
  msgid "Change Default Role"
144
  msgstr ""
145
 
146
- #: ../ure-options.php:221
147
- #: ../ure-options.php:304
148
  msgid "Restore Roles from backup copy"
149
  msgstr ""
150
 
151
- #: ../ure-options.php:223
152
  msgid "Please confirm to continue"
153
  msgstr ""
154
 
155
- #: ../ure-options.php:248
156
  #, php-format
157
  msgid "Role \"%s\" update: please confirm to continue"
158
  msgstr ""
159
 
160
- #: ../ure-options.php:256
161
  msgid "Select Role and change its capabilities list"
162
  msgstr ""
163
 
@@ -165,399 +162,412 @@ msgstr ""
165
  msgid "Select Role:"
166
  msgstr ""
167
 
168
- #: ../ure-options.php:302
 
 
 
 
 
 
 
 
 
 
 
 
169
  msgid "Update"
170
  msgstr ""
171
 
172
- #: ../ure-options.php:302
173
  msgid "Save Changes"
174
  msgstr ""
175
 
176
- #: ../ure-options.php:303
177
  msgid "Cancel"
178
  msgstr ""
179
 
180
- #: ../ure-options.php:303
181
  msgid "Cancel not saved changes"
182
  msgstr ""
183
 
184
- #: ../ure-options.php:304
185
  msgid "Reset"
186
  msgstr ""
187
 
188
- #: ../ure-options.php:315
189
- msgid "Show capabilities in human readable form"
190
- msgstr ""
191
-
192
- #: ../ure-options.php:325
193
  msgid "Add New Role"
194
  msgstr ""
195
 
196
- #: ../ure-options.php:330
197
  msgid "Add"
198
  msgstr ""
199
 
200
- #: ../ure-options.php:330
201
  msgid "Add New User Role"
202
  msgstr ""
203
 
204
- #: ../ure-options.php:334
205
  msgid "Default Role for New User"
206
  msgstr ""
207
 
208
- #: ../ure-options.php:339
209
  msgid "Change"
210
  msgstr ""
211
 
212
- #: ../ure-options.php:339
213
  msgid "Set as Default User Role"
214
  msgstr ""
215
 
216
- #: ../ure-options.php:349
217
  msgid "Delete"
218
  msgstr ""
219
 
220
- #: ../ure-options.php:349
221
  msgid "Delete User Role"
222
  msgstr ""
223
 
224
- #: ../user-role-editor.php:38
225
  msgid "User Role Editor requires WordPress 3.0 or newer."
226
  msgstr ""
227
 
228
- #: ../user-role-editor.php:38
229
  msgid "Please update!"
230
  msgstr ""
231
 
232
- #: ../user-role-editor.php:63
 
233
  msgid "User Role Editor"
234
  msgstr ""
235
 
236
- #: ../user-role-editor.php:196
237
  msgid "Settings"
238
  msgstr ""
239
 
240
- #: ../ure-lib.php:54
241
  msgid "Error is occur. Please check the log file."
242
  msgstr ""
243
 
244
- #: ../ure-lib.php:110
245
  msgid "Database operation error. Check log file."
246
  msgstr ""
247
 
248
- #: ../ure-lib.php:132
249
  msgid "Roles capabilities are restored from the backup data"
250
  msgstr ""
251
 
252
- #: ../ure-lib.php:134
253
  msgid "No backup data. It is created automatically before the first role data update."
254
  msgstr ""
255
 
256
- #: ../ure-lib.php:175
 
 
 
 
257
  msgid "Error: Role name must contain latin characters and digits only!"
258
  msgstr ""
259
 
260
- #: ../ure-lib.php:183
261
  msgid "Roles list reading error is encountered"
262
  msgstr ""
263
 
264
- #: ../ure-lib.php:189
265
  msgid "Error is encountered during new role create operation"
266
  msgstr ""
267
 
268
- #: ../ure-lib.php:191
269
  #, php-format
270
  msgid "Role %s is created successfully"
271
  msgstr ""
272
 
273
- #: ../ure-lib.php:275
274
  msgid "Error encountered during role delete operation"
275
  msgstr ""
276
 
277
- #: ../ure-lib.php:277
278
  #, php-format
279
  msgid "Role %s is deleted successfully"
280
  msgstr ""
281
 
282
- #: ../ure-lib.php:295
283
  msgid "Error encountered during default role change operation"
284
  msgstr ""
285
 
286
- #: ../ure-lib.php:301
287
  #, php-format
288
  msgid "Default role for new users is set to %s successfully"
289
  msgstr ""
290
 
291
- #: ../ure-lib.php:355
292
  msgid "Editor"
293
  msgstr ""
294
 
295
- #: ../ure-lib.php:356
296
  msgid "Author"
297
  msgstr ""
298
 
299
- #: ../ure-lib.php:357
300
  msgid "Contributor"
301
  msgstr ""
302
 
303
- #: ../ure-lib.php:358
304
  msgid "Subscriber"
305
  msgstr ""
306
 
307
- #: ../ure-lib.php:360
308
  msgid "Switch themes"
309
  msgstr ""
310
 
311
- #: ../ure-lib.php:361
312
  msgid "Edit themes"
313
  msgstr ""
314
 
315
- #: ../ure-lib.php:362
316
  msgid "Activate plugins"
317
  msgstr ""
318
 
319
- #: ../ure-lib.php:363
320
  msgid "Edit plugins"
321
  msgstr ""
322
 
323
- #: ../ure-lib.php:364
324
  msgid "Edit users"
325
  msgstr ""
326
 
327
- #: ../ure-lib.php:365
328
  msgid "Edit files"
329
  msgstr ""
330
 
331
- #: ../ure-lib.php:366
332
  msgid "Manage options"
333
  msgstr ""
334
 
335
- #: ../ure-lib.php:367
336
  msgid "Moderate comments"
337
  msgstr ""
338
 
339
- #: ../ure-lib.php:368
340
  msgid "Manage categories"
341
  msgstr ""
342
 
343
- #: ../ure-lib.php:369
344
  msgid "Manage links"
345
  msgstr ""
346
 
347
- #: ../ure-lib.php:370
348
  msgid "Upload files"
349
  msgstr ""
350
 
351
- #: ../ure-lib.php:371
352
  msgid "Import"
353
  msgstr ""
354
 
355
- #: ../ure-lib.php:372
356
  msgid "Unfiltered html"
357
  msgstr ""
358
 
359
- #: ../ure-lib.php:373
360
  msgid "Edit posts"
361
  msgstr ""
362
 
363
- #: ../ure-lib.php:374
364
  msgid "Edit others posts"
365
  msgstr ""
366
 
367
- #: ../ure-lib.php:375
368
  msgid "Edit published posts"
369
  msgstr ""
370
 
371
- #: ../ure-lib.php:376
372
  msgid "Publish posts"
373
  msgstr ""
374
 
375
- #: ../ure-lib.php:377
376
  msgid "Edit pages"
377
  msgstr ""
378
 
379
- #: ../ure-lib.php:378
380
  msgid "Read"
381
  msgstr ""
382
 
383
- #: ../ure-lib.php:379
384
  msgid "Level 10"
385
  msgstr ""
386
 
387
- #: ../ure-lib.php:380
388
  msgid "Level 9"
389
  msgstr ""
390
 
391
- #: ../ure-lib.php:381
392
  msgid "Level 8"
393
  msgstr ""
394
 
395
- #: ../ure-lib.php:382
396
  msgid "Level 7"
397
  msgstr ""
398
 
399
- #: ../ure-lib.php:383
400
  msgid "Level 6"
401
  msgstr ""
402
 
403
- #: ../ure-lib.php:384
404
  msgid "Level 5"
405
  msgstr ""
406
 
407
- #: ../ure-lib.php:385
408
  msgid "Level 4"
409
  msgstr ""
410
 
411
- #: ../ure-lib.php:386
412
  msgid "Level 3"
413
  msgstr ""
414
 
415
- #: ../ure-lib.php:387
416
  msgid "Level 2"
417
  msgstr ""
418
 
419
- #: ../ure-lib.php:388
420
  msgid "Level 1"
421
  msgstr ""
422
 
423
- #: ../ure-lib.php:389
424
  msgid "Level 0"
425
  msgstr ""
426
 
427
- #: ../ure-lib.php:390
428
  msgid "Edit others pages"
429
  msgstr ""
430
 
431
- #: ../ure-lib.php:391
432
  msgid "Edit published pages"
433
  msgstr ""
434
 
435
- #: ../ure-lib.php:392
436
  msgid "Publish pages"
437
  msgstr ""
438
 
439
- #: ../ure-lib.php:393
440
  msgid "Delete pages"
441
  msgstr ""
442
 
443
- #: ../ure-lib.php:394
444
  msgid "Delete others pages"
445
  msgstr ""
446
 
447
- #: ../ure-lib.php:395
448
  msgid "Delete published pages"
449
  msgstr ""
450
 
451
- #: ../ure-lib.php:396
452
  msgid "Delete posts"
453
  msgstr ""
454
 
455
- #: ../ure-lib.php:397
456
  msgid "Delete others posts"
457
  msgstr ""
458
 
459
- #: ../ure-lib.php:398
460
  msgid "Delete published posts"
461
  msgstr ""
462
 
463
- #: ../ure-lib.php:399
464
  msgid "Delete private posts"
465
  msgstr ""
466
 
467
- #: ../ure-lib.php:400
468
  msgid "Edit private posts"
469
  msgstr ""
470
 
471
- #: ../ure-lib.php:401
472
  msgid "Read private posts"
473
  msgstr ""
474
 
475
- #: ../ure-lib.php:402
476
  msgid "Delete private pages"
477
  msgstr ""
478
 
479
- #: ../ure-lib.php:403
480
  msgid "Edit private pages"
481
  msgstr ""
482
 
483
- #: ../ure-lib.php:404
484
  msgid "Read private pages"
485
  msgstr ""
486
 
487
- #: ../ure-lib.php:405
488
  msgid "Delete users"
489
  msgstr ""
490
 
491
- #: ../ure-lib.php:406
492
  msgid "Create users"
493
  msgstr ""
494
 
495
- #: ../ure-lib.php:407
496
  msgid "Unfiltered upload"
497
  msgstr ""
498
 
499
- #: ../ure-lib.php:408
500
  msgid "Edit dashboard"
501
  msgstr ""
502
 
503
- #: ../ure-lib.php:409
504
  msgid "Update plugins"
505
  msgstr ""
506
 
507
- #: ../ure-lib.php:410
508
  msgid "Delete plugins"
509
  msgstr ""
510
 
511
- #: ../ure-lib.php:411
512
  msgid "Install plugins"
513
  msgstr ""
514
 
515
- #: ../ure-lib.php:412
516
  msgid "Update themes"
517
  msgstr ""
518
 
519
- #: ../ure-lib.php:413
520
  msgid "Install themes"
521
  msgstr ""
522
 
523
- #: ../ure-lib.php:414
524
  msgid "Update core"
525
  msgstr ""
526
 
527
- #: ../ure-lib.php:415
528
  msgid "List users"
529
  msgstr ""
530
 
531
- #: ../ure-lib.php:416
532
  msgid "Remove users"
533
  msgstr ""
534
 
535
- #: ../ure-lib.php:417
536
  msgid "Add users"
537
  msgstr ""
538
 
539
- #: ../ure-lib.php:418
540
  msgid "Promote users"
541
  msgstr ""
542
 
543
- #: ../ure-lib.php:419
544
  msgid "Edit theme options"
545
  msgstr ""
546
 
547
- #: ../ure-lib.php:420
548
  msgid "Delete themes"
549
  msgstr ""
550
 
551
- #: ../ure-lib.php:421
552
  msgid "Export"
553
  msgstr ""
554
 
555
- #: ../ure-lib.php:442
556
- #: ../ure-lib.php:457
557
  msgid "No items found."
558
  msgstr ""
559
 
560
- #: ../ure-lib.php:445
561
  msgid "Recent Posts:"
562
  msgstr ""
563
 
2
  msgstr ""
3
  "Project-Id-Version: User Role Editor 2.0\n"
4
  "Report-Msgid-Bugs-To: \n"
5
+ "POT-Creation-Date: 2011-02-06 20:58+0700\n"
6
  "PO-Revision-Date: \n"
7
  "Last-Translator: Vladimir <vladimir@shinephp.com>\n"
8
  "Language-Team: ShinePHP.com <vladimir@shinephp.com>\n"
16
  "X-Poedit-Basepath: .\n"
17
  "X-Poedit-SearchPath-0: ..\n"
18
 
19
+ #: ../ure-options.php:106
 
 
 
 
20
  msgid "Role"
21
  msgstr ""
22
 
23
+ #: ../ure-options.php:106
24
  msgid "is updated successfully"
25
  msgstr ""
26
 
27
+ #: ../ure-options.php:150
28
  msgid "About this Plugin:"
29
  msgstr ""
30
 
31
+ #: ../ure-options.php:151
32
  msgid "Author's website"
33
  msgstr ""
34
 
35
+ #: ../ure-options.php:152
36
  msgid "Plugin webpage"
37
  msgstr ""
38
 
39
+ #: ../ure-options.php:153
40
+ #: ../user-role-editor.php:232
41
  msgid "Changelog"
42
  msgstr ""
43
 
44
+ #: ../ure-options.php:154
45
  msgid "FAQ"
46
  msgstr ""
47
 
48
+ #: ../ure-options.php:155
49
  msgid "Donate"
50
  msgstr ""
51
 
52
+ #: ../ure-options.php:157
53
  msgid "More plugins from"
54
  msgstr ""
55
 
56
+ #: ../ure-options.php:160
57
  msgid "Greetings:"
58
  msgstr ""
59
 
60
+ #: ../ure-options.php:161
61
  msgid "It's me, the author"
62
  msgstr ""
63
 
64
+ #: ../ure-options.php:162
65
  msgid "For the help with Belorussian translation"
66
  msgstr ""
67
 
68
+ #: ../ure-options.php:163
69
  msgid "For the help with Brasilian translation"
70
  msgstr ""
71
 
72
+ #: ../ure-options.php:164
73
  msgid "For the help with Chinese translation"
74
  msgstr ""
75
 
76
+ #: ../ure-options.php:165
77
  msgid "For the help with Dutch translation"
78
  msgstr ""
79
 
80
+ #: ../ure-options.php:166
81
  msgid "For the help with French translation"
82
  msgstr ""
83
 
84
+ #: ../ure-options.php:167
85
  msgid "For the help with German translation"
86
  msgstr ""
87
 
88
+ #: ../ure-options.php:168
89
  msgid "For the help with Hungarian translation"
90
  msgstr ""
91
 
92
+ #: ../ure-options.php:169
93
+ #: ../ure-options.php:170
94
  msgid "For the help with Italian translation"
95
  msgstr ""
96
 
97
+ #: ../ure-options.php:171
98
  msgid "For the help with Japanese translation"
99
  msgstr ""
100
 
101
+ #: ../ure-options.php:172
102
  msgid "For the help with Persian translation"
103
  msgstr ""
104
 
105
+ #: ../ure-options.php:173
106
  msgid "For the help with Polish translation"
107
  msgstr ""
108
 
109
+ #: ../ure-options.php:174
110
  msgid "For the help with Spanish translation"
111
  msgstr ""
112
 
113
+ #: ../ure-options.php:175
114
+ #: ../ure-options.php:176
115
  msgid "For the help with Turkish translation"
116
  msgstr ""
117
 
118
+ #: ../ure-options.php:177
119
  msgid "For the code to hide administrator role"
120
  msgstr ""
121
 
122
+ #: ../ure-options.php:178
123
  msgid "Do you wish to see your name with link to your site here? You are welcome! Your help with translation and new ideas are very appreciated."
124
  msgstr ""
125
 
126
+ #: ../ure-options.php:210
127
  msgid "Role Name can not be empty!"
128
  msgstr ""
129
 
130
+ #: ../ure-options.php:214
131
  msgid "Role Name must contain latin characters and digits only!"
132
  msgstr ""
133
 
134
+ #: ../ure-options.php:219
135
+ #: ../ure-options.php:362
136
  msgid "Delete Role"
137
  msgstr ""
138
 
139
+ #: ../ure-options.php:221
140
  msgid "Change Default Role"
141
  msgstr ""
142
 
143
+ #: ../ure-options.php:223
144
+ #: ../ure-options.php:333
145
  msgid "Restore Roles from backup copy"
146
  msgstr ""
147
 
148
+ #: ../ure-options.php:225
149
  msgid "Please confirm to continue"
150
  msgstr ""
151
 
152
+ #: ../ure-options.php:250
153
  #, php-format
154
  msgid "Role \"%s\" update: please confirm to continue"
155
  msgstr ""
156
 
157
+ #: ../ure-options.php:258
158
  msgid "Select Role and change its capabilities list"
159
  msgstr ""
160
 
162
  msgid "Select Role:"
163
  msgstr ""
164
 
165
+ #: ../ure-options.php:269
166
+ msgid "Show capabilities in human readable form"
167
+ msgstr ""
168
+
169
+ #: ../ure-options.php:273
170
+ msgid "If checked, then apply action to ALL sites of this Network"
171
+ msgstr ""
172
+
173
+ #: ../ure-options.php:283
174
+ msgid "Apply to All Sites"
175
+ msgstr ""
176
+
177
+ #: ../ure-options.php:329
178
  msgid "Update"
179
  msgstr ""
180
 
181
+ #: ../ure-options.php:329
182
  msgid "Save Changes"
183
  msgstr ""
184
 
185
+ #: ../ure-options.php:330
186
  msgid "Cancel"
187
  msgstr ""
188
 
189
+ #: ../ure-options.php:330
190
  msgid "Cancel not saved changes"
191
  msgstr ""
192
 
193
+ #: ../ure-options.php:333
194
  msgid "Reset"
195
  msgstr ""
196
 
197
+ #: ../ure-options.php:343
 
 
 
 
198
  msgid "Add New Role"
199
  msgstr ""
200
 
201
+ #: ../ure-options.php:348
202
  msgid "Add"
203
  msgstr ""
204
 
205
+ #: ../ure-options.php:348
206
  msgid "Add New User Role"
207
  msgstr ""
208
 
209
+ #: ../ure-options.php:352
210
  msgid "Default Role for New User"
211
  msgstr ""
212
 
213
+ #: ../ure-options.php:357
214
  msgid "Change"
215
  msgstr ""
216
 
217
+ #: ../ure-options.php:357
218
  msgid "Set as Default User Role"
219
  msgstr ""
220
 
221
+ #: ../ure-options.php:367
222
  msgid "Delete"
223
  msgstr ""
224
 
225
+ #: ../ure-options.php:367
226
  msgid "Delete User Role"
227
  msgstr ""
228
 
229
+ #: ../user-role-editor.php:37
230
  msgid "User Role Editor requires WordPress 3.0 or newer."
231
  msgstr ""
232
 
233
+ #: ../user-role-editor.php:37
234
  msgid "Please update!"
235
  msgstr ""
236
 
237
+ #: ../user-role-editor.php:72
238
+ #: ../user-role-editor.php:246
239
  msgid "User Role Editor"
240
  msgstr ""
241
 
242
+ #: ../user-role-editor.php:222
243
  msgid "Settings"
244
  msgstr ""
245
 
246
+ #: ../ure-lib.php:56
247
  msgid "Error is occur. Please check the log file."
248
  msgstr ""
249
 
250
+ #: ../ure-lib.php:170
251
  msgid "Database operation error. Check log file."
252
  msgstr ""
253
 
254
+ #: ../ure-lib.php:193
255
  msgid "Roles capabilities are restored from the backup data"
256
  msgstr ""
257
 
258
+ #: ../ure-lib.php:195
259
  msgid "No backup data. It is created automatically before the first role data update."
260
  msgstr ""
261
 
262
+ #: ../ure-lib.php:234
263
+ msgid "Backup record is created for the current role capabilities"
264
+ msgstr ""
265
+
266
+ #: ../ure-lib.php:315
267
  msgid "Error: Role name must contain latin characters and digits only!"
268
  msgstr ""
269
 
270
+ #: ../ure-lib.php:323
271
  msgid "Roles list reading error is encountered"
272
  msgstr ""
273
 
274
+ #: ../ure-lib.php:329
275
  msgid "Error is encountered during new role create operation"
276
  msgstr ""
277
 
278
+ #: ../ure-lib.php:331
279
  #, php-format
280
  msgid "Role %s is created successfully"
281
  msgstr ""
282
 
283
+ #: ../ure-lib.php:415
284
  msgid "Error encountered during role delete operation"
285
  msgstr ""
286
 
287
+ #: ../ure-lib.php:417
288
  #, php-format
289
  msgid "Role %s is deleted successfully"
290
  msgstr ""
291
 
292
+ #: ../ure-lib.php:435
293
  msgid "Error encountered during default role change operation"
294
  msgstr ""
295
 
296
+ #: ../ure-lib.php:441
297
  #, php-format
298
  msgid "Default role for new users is set to %s successfully"
299
  msgstr ""
300
 
301
+ #: ../ure-lib.php:469
302
  msgid "Editor"
303
  msgstr ""
304
 
305
+ #: ../ure-lib.php:470
306
  msgid "Author"
307
  msgstr ""
308
 
309
+ #: ../ure-lib.php:471
310
  msgid "Contributor"
311
  msgstr ""
312
 
313
+ #: ../ure-lib.php:472
314
  msgid "Subscriber"
315
  msgstr ""
316
 
317
+ #: ../ure-lib.php:474
318
  msgid "Switch themes"
319
  msgstr ""
320
 
321
+ #: ../ure-lib.php:475
322
  msgid "Edit themes"
323
  msgstr ""
324
 
325
+ #: ../ure-lib.php:476
326
  msgid "Activate plugins"
327
  msgstr ""
328
 
329
+ #: ../ure-lib.php:477
330
  msgid "Edit plugins"
331
  msgstr ""
332
 
333
+ #: ../ure-lib.php:478
334
  msgid "Edit users"
335
  msgstr ""
336
 
337
+ #: ../ure-lib.php:479
338
  msgid "Edit files"
339
  msgstr ""
340
 
341
+ #: ../ure-lib.php:480
342
  msgid "Manage options"
343
  msgstr ""
344
 
345
+ #: ../ure-lib.php:481
346
  msgid "Moderate comments"
347
  msgstr ""
348
 
349
+ #: ../ure-lib.php:482
350
  msgid "Manage categories"
351
  msgstr ""
352
 
353
+ #: ../ure-lib.php:483
354
  msgid "Manage links"
355
  msgstr ""
356
 
357
+ #: ../ure-lib.php:484
358
  msgid "Upload files"
359
  msgstr ""
360
 
361
+ #: ../ure-lib.php:485
362
  msgid "Import"
363
  msgstr ""
364
 
365
+ #: ../ure-lib.php:486
366
  msgid "Unfiltered html"
367
  msgstr ""
368
 
369
+ #: ../ure-lib.php:487
370
  msgid "Edit posts"
371
  msgstr ""
372
 
373
+ #: ../ure-lib.php:488
374
  msgid "Edit others posts"
375
  msgstr ""
376
 
377
+ #: ../ure-lib.php:489
378
  msgid "Edit published posts"
379
  msgstr ""
380
 
381
+ #: ../ure-lib.php:490
382
  msgid "Publish posts"
383
  msgstr ""
384
 
385
+ #: ../ure-lib.php:491
386
  msgid "Edit pages"
387
  msgstr ""
388
 
389
+ #: ../ure-lib.php:492
390
  msgid "Read"
391
  msgstr ""
392
 
393
+ #: ../ure-lib.php:493
394
  msgid "Level 10"
395
  msgstr ""
396
 
397
+ #: ../ure-lib.php:494
398
  msgid "Level 9"
399
  msgstr ""
400
 
401
+ #: ../ure-lib.php:495
402
  msgid "Level 8"
403
  msgstr ""
404
 
405
+ #: ../ure-lib.php:496
406
  msgid "Level 7"
407
  msgstr ""
408
 
409
+ #: ../ure-lib.php:497
410
  msgid "Level 6"
411
  msgstr ""
412
 
413
+ #: ../ure-lib.php:498
414
  msgid "Level 5"
415
  msgstr ""
416
 
417
+ #: ../ure-lib.php:499
418
  msgid "Level 4"
419
  msgstr ""
420
 
421
+ #: ../ure-lib.php:500
422
  msgid "Level 3"
423
  msgstr ""
424
 
425
+ #: ../ure-lib.php:501
426
  msgid "Level 2"
427
  msgstr ""
428
 
429
+ #: ../ure-lib.php:502
430
  msgid "Level 1"
431
  msgstr ""
432
 
433
+ #: ../ure-lib.php:503
434
  msgid "Level 0"
435
  msgstr ""
436
 
437
+ #: ../ure-lib.php:504
438
  msgid "Edit others pages"
439
  msgstr ""
440
 
441
+ #: ../ure-lib.php:505
442
  msgid "Edit published pages"
443
  msgstr ""
444
 
445
+ #: ../ure-lib.php:506
446
  msgid "Publish pages"
447
  msgstr ""
448
 
449
+ #: ../ure-lib.php:507
450
  msgid "Delete pages"
451
  msgstr ""
452
 
453
+ #: ../ure-lib.php:508
454
  msgid "Delete others pages"
455
  msgstr ""
456
 
457
+ #: ../ure-lib.php:509
458
  msgid "Delete published pages"
459
  msgstr ""
460
 
461
+ #: ../ure-lib.php:510
462
  msgid "Delete posts"
463
  msgstr ""
464
 
465
+ #: ../ure-lib.php:511
466
  msgid "Delete others posts"
467
  msgstr ""
468
 
469
+ #: ../ure-lib.php:512
470
  msgid "Delete published posts"
471
  msgstr ""
472
 
473
+ #: ../ure-lib.php:513
474
  msgid "Delete private posts"
475
  msgstr ""
476
 
477
+ #: ../ure-lib.php:514
478
  msgid "Edit private posts"
479
  msgstr ""
480
 
481
+ #: ../ure-lib.php:515
482
  msgid "Read private posts"
483
  msgstr ""
484
 
485
+ #: ../ure-lib.php:516
486
  msgid "Delete private pages"
487
  msgstr ""
488
 
489
+ #: ../ure-lib.php:517
490
  msgid "Edit private pages"
491
  msgstr ""
492
 
493
+ #: ../ure-lib.php:518
494
  msgid "Read private pages"
495
  msgstr ""
496
 
497
+ #: ../ure-lib.php:519
498
  msgid "Delete users"
499
  msgstr ""
500
 
501
+ #: ../ure-lib.php:520
502
  msgid "Create users"
503
  msgstr ""
504
 
505
+ #: ../ure-lib.php:521
506
  msgid "Unfiltered upload"
507
  msgstr ""
508
 
509
+ #: ../ure-lib.php:522
510
  msgid "Edit dashboard"
511
  msgstr ""
512
 
513
+ #: ../ure-lib.php:523
514
  msgid "Update plugins"
515
  msgstr ""
516
 
517
+ #: ../ure-lib.php:524
518
  msgid "Delete plugins"
519
  msgstr ""
520
 
521
+ #: ../ure-lib.php:525
522
  msgid "Install plugins"
523
  msgstr ""
524
 
525
+ #: ../ure-lib.php:526
526
  msgid "Update themes"
527
  msgstr ""
528
 
529
+ #: ../ure-lib.php:527
530
  msgid "Install themes"
531
  msgstr ""
532
 
533
+ #: ../ure-lib.php:528
534
  msgid "Update core"
535
  msgstr ""
536
 
537
+ #: ../ure-lib.php:529
538
  msgid "List users"
539
  msgstr ""
540
 
541
+ #: ../ure-lib.php:530
542
  msgid "Remove users"
543
  msgstr ""
544
 
545
+ #: ../ure-lib.php:531
546
  msgid "Add users"
547
  msgstr ""
548
 
549
+ #: ../ure-lib.php:532
550
  msgid "Promote users"
551
  msgstr ""
552
 
553
+ #: ../ure-lib.php:533
554
  msgid "Edit theme options"
555
  msgstr ""
556
 
557
+ #: ../ure-lib.php:534
558
  msgid "Delete themes"
559
  msgstr ""
560
 
561
+ #: ../ure-lib.php:535
562
  msgid "Export"
563
  msgstr ""
564
 
565
+ #: ../ure-lib.php:556
566
+ #: ../ure-lib.php:571
567
  msgid "No items found."
568
  msgstr ""
569
 
570
+ #: ../ure-lib.php:559
571
  msgid "Recent Posts:"
572
  msgstr ""
573
 
readme.txt CHANGED
@@ -3,8 +3,8 @@ Contributors: shinephp
3
  Donate link: http://www.shinephp.com/donate/
4
  Tags: user, role, editor, security, access, permission, capability
5
  Requires at least: 3.0
6
- Tested up to: 3.0.1
7
- Stable tag: 2.2.2
8
 
9
  User Role Editor WordPress plugin makes the role capabilities changing easy. You can change any standard WordPress user role (except administrator).
10
 
@@ -28,30 +28,19 @@ Attention! Starting from version 2.2 plugin works with WordPress 3.0 and higher
28
  4. Go to the "Settings"-"User Role Editor" menu item and change your WordPress standard roles capabilities according to your needs.
29
 
30
  == Frequently Asked Questions ==
31
- - Does it work with WordPress 3.0 in multi-site environment?
32
- Yes, it works with WordPress 3.0 multi-site. Current version works for every blog from your multi-site network as for locally installed blog.
33
- Network feature, something like super-admin global role editor will be added in the nearest release.
34
 
35
 
36
  == Screenshots ==
37
  1. screenshot-1.png User Role Editor main form
 
38
 
39
 
40
  == Special Thanks to ==
41
- * [Whiler](http://blogs.wittwer.fr/whiler/) for the help with French translation and useful ideas.
42
- * [Peter](http://www.red-socks-reinbek.de) - for the help with German translation.
43
- * [Dario Ferrer](http://www.darioferrer.com) - for the help with the Spanish translation.
44
- * [Talksina](http://www.iadkiller.org), [Alessandro Mariani](http://technodin.org) - for the help with Italian translation.
45
- * [Technolog.jp](http://technolog.jp/) - for the help with Japanese translation.
46
- * [Marsis G.](http://pc.de/) for the help with Belorussian translation.
47
- * [TagSite](http://www.tagsite.eu) for the help with Polish translation.
48
- * [István](http://www.blacksnail.hu) for the help with Hungarian translation.
49
- * [Rémi Bruggeman](http://www.remisan.be) for the help with Dutch translation.
50
- * [Yackytsu](http://www.jackytsu.com) for the help with Chinese translation.
51
- * [Rafael Galdencio](http://www.arquiteturailustrada.com.br/) for the help with Brasilian Portuguese translation.
52
- * [Good Life](http://good-life.ir) for the help with Persian translation.
53
- * [Sadri Ercan](http://www.faydaliweb.com) for the help with Turkish translation.
54
  * [FullThrottle](http://fullthrottledevelopment.com/how-to-hide-the-adminstrator-on-the-wordpress-users-screen) - For the code to hide administrator role at admin backend.
 
55
 
56
  = Translations =
57
  * Belorussian: [Marsis G.](http://pc.de)
@@ -67,7 +56,7 @@ Network feature, something like super-admin global role editor will be added in
67
  * Polish: [TagSite](http://www.tagsite.eu)
68
  * Russian: [Vladimir Garagulya](http://shinephp.com)
69
  * Spanish: [Dario Ferrer](http://www.darioferrer.com)
70
- * Turkish: [Sadri Ercan](http://www.faydaliweb.com)
71
 
72
  Dear plugin User!
73
  If you wish to help me with this plugin translation I very appreciate it. Please send your language .po and .mo files to vladimir[at-sign]shinephp.com email. Do not forget include you site link in order I can show it with greetings for the translation help at shinephp.com, plugin settings page and in this readme.txt file.
@@ -76,6 +65,20 @@ Share with me new ideas about plugin further development and link to your site w
76
 
77
 
78
  == Changelog ==
 
 
 
 
 
 
 
 
 
 
 
 
 
 
79
  = 2.2.2 =
80
  * 07.11.2010
81
  * URE plugin Settings page was unavailable for some installations in multi-site environment. It is fixed by changing 'add_users' capability for administrator access to the 'edit_users'.
3
  Donate link: http://www.shinephp.com/donate/
4
  Tags: user, role, editor, security, access, permission, capability
5
  Requires at least: 3.0
6
+ Tested up to: 3.1
7
+ Stable tag: 3.0
8
 
9
  User Role Editor WordPress plugin makes the role capabilities changing easy. You can change any standard WordPress user role (except administrator).
10
 
28
  4. Go to the "Settings"-"User Role Editor" menu item and change your WordPress standard roles capabilities according to your needs.
29
 
30
  == Frequently Asked Questions ==
31
+ - Does it work with WordPress 3.1 in multi-site environment?
32
+ Yes, it works with WordPress 3.1 multi-site. By default plugin works for every blog from your multi-site network as for locally installed blog.
33
+ To update selected role globally for the Network you should turn on the "Apply to All Sites" checkbox.
34
 
35
 
36
  == Screenshots ==
37
  1. screenshot-1.png User Role Editor main form
38
+ 1. screenshot-2.png User Role Editor main form under multi-site environment
39
 
40
 
41
  == Special Thanks to ==
 
 
 
 
 
 
 
 
 
 
 
 
 
42
  * [FullThrottle](http://fullthrottledevelopment.com/how-to-hide-the-adminstrator-on-the-wordpress-users-screen) - For the code to hide administrator role at admin backend.
43
+ * Marcin - For the code enhancement. This contribution allows to not lose new custom capability if it is added to other than 'Administrator' role.
44
 
45
  = Translations =
46
  * Belorussian: [Marsis G.](http://pc.de)
56
  * Polish: [TagSite](http://www.tagsite.eu)
57
  * Russian: [Vladimir Garagulya](http://shinephp.com)
58
  * Spanish: [Dario Ferrer](http://www.darioferrer.com)
59
+ * Turkish: [Sadri Ercan](http://www.faydaliweb.com), [Can KAYA](http://www.kartaca.com)
60
 
61
  Dear plugin User!
62
  If you wish to help me with this plugin translation I very appreciate it. Please send your language .po and .mo files to vladimir[at-sign]shinephp.com email. Do not forget include you site link in order I can show it with greetings for the translation help at shinephp.com, plugin settings page and in this readme.txt file.
65
 
66
 
67
  == Changelog ==
68
+ = 3.0 =
69
+ * 06.02.2011
70
+ * Compatibility with WordPress 3.1 Release Candidate 3 and real multi-site feature are provided.
71
+ * Role capabilities list are sorted now in the alphabetical order. Easier to find - easier to manage.
72
+ * Code fix: allows to not lose new custom capability if it is added to other than 'Administrator' role. Thanks to Marcin for the contribution to the code of this plugin.
73
+ * Under multi-site environment:
74
+ * 1) URE has additional option 'Apply to All Sites' which allows you to apply updates to the selected role at all sites of your network. If some site has not such role, it will be added. You should know, that this option works for the role update only. All other actions as 'Add' or 'Delete' role still works for the currently selected blog/site only.
75
+ * 2) URE plugin settings page is available only to user with network superadministrator rights.
76
+
77
+ = 2.2.3 =
78
+ * 08.11.2010
79
+ * It is the security update. Old problem returned after 2.2.2 update and was discovered by saharusa. You can read this [thread](http://wordpress.org/support/topic/plugin-user-role-editor-editor-can-edit-admin).
80
+ Only user with Administrator role and superadmin user under multi-site environment have access to the User Role Editor Settings page now.
81
+
82
  = 2.2.2 =
83
  * 07.11.2010
84
  * URE plugin Settings page was unavailable for some installations in multi-site environment. It is fixed by changing 'add_users' capability for administrator access to the 'edit_users'.
screenshot-2.png ADDED
Binary file
ure-lib.php CHANGED
@@ -31,10 +31,12 @@ define('URE_PLUGIN_DIR', WP_PLUGIN_DIR.'/'.$urePluginDirName);
31
  define('URE_WP_ADMIN_URL', $ure_siteURL.'/wp-admin');
32
  define('URE_ERROR', 'Error is encountered');
33
  define('URE_SPACE_REPLACER', '_URE-SR_');
 
34
 
35
- global $wpdb, $ure_OptionsTable;
 
 
36
 
37
- $ure_OptionsTable = $wpdb->prefix .'options';
38
  // this array will be used to cash users checked for Administrator role
39
  $ure_userToEdit = array();
40
 
@@ -56,6 +58,63 @@ function ure_logEvent($message, $showMessage = false) {
56
  }
57
  // end of ure_logEvent()
58
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
59
  function ure_optionSelected($value, $etalon) {
60
  $selected = '';
61
  if ($value==$etalon) {
@@ -83,8 +142,9 @@ function ure_showMessage($message) {
83
 
84
 
85
  function ure_getUserRoles() {
86
- global $wpdb, $ure_OptionsTable;
87
-
 
88
  $option_name = $wpdb->prefix.'user_roles';
89
  $getRolesQuery = "select option_id, option_value
90
  from $ure_OptionsTable
@@ -95,9 +155,9 @@ function ure_getUserRoles() {
95
  ure_logEvent($wpdb->last_error);
96
  return;
97
  }
98
- $roles = unserialize($record[0]->option_value);
99
 
100
- return $roles;
101
  }
102
  // end of getUserRoles()
103
 
@@ -105,9 +165,10 @@ function ure_getUserRoles() {
105
  // restores User Roles from the backup record
106
  function restoreUserRoles() {
107
 
108
- global $wpdb, $ure_OptionsTable;
109
 
110
  $errorMessage = 'Error! '.__('Database operation error. Check log file.', 'ure');
 
111
  $option_name = $wpdb->prefix.'user_roles';
112
  $backup_option_name = $wpdb->prefix.'backup_user_roles';
113
  $query = "select option_value
@@ -142,12 +203,54 @@ function restoreUserRoles() {
142
  // end of restorUserRoles()
143
 
144
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
145
  // Save Roles to database
146
- function ure_saveRolesToDb($roles) {
147
- global $wpdb, $ure_OptionsTable;
148
 
 
 
 
 
 
149
  $option_name = $wpdb->prefix.'user_roles';
150
- $serialized_roles = serialize($roles);
151
  $query = "update $ure_OptionsTable
152
  set option_value='$serialized_roles'
153
  where option_name='$option_name'
@@ -163,11 +266,48 @@ function ure_saveRolesToDb($roles) {
163
  // end of saveRolesToDb()
164
 
165
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
166
  // process new role create request
167
- function ure_newRoleCreate(&$currentRole) {
168
 
169
  $mess = '';
170
- $currentRole = '';
171
  if (isset($_GET['user_role']) && $_GET['user_role']) {
172
  $user_role = utf8_decode(urldecode($_GET['user_role']));
173
  // sanitize user input for security
@@ -178,13 +318,13 @@ function ure_newRoleCreate(&$currentRole) {
178
  if ($user_role) {
179
  $user_role = esc_html($user_role);
180
  $user_role = mysql_real_escape_string($user_role);
181
- $roles = ure_getUserRoles();
182
- if (!$roles) {
183
  return 'Error! '.__('Roles list reading error is encountered', 'ure');;
184
  }
185
  // add new role to the roles array
186
- $currentRole = strtolower($user_role);
187
- $result = add_role($currentRole, $user_role, array('read'=>1, 'level_0'=>1));
188
  if (!isset($result) || !$result) {
189
  $mess = 'Error! '.__('Error is encountered during new role create operation', 'ure');
190
  } else {
@@ -198,15 +338,15 @@ function ure_newRoleCreate(&$currentRole) {
198
 
199
 
200
  // define roles which we could delete, e.g self-created and not used with any blog user
201
- function getRolesCanDelete($roles) {
202
  global $wpdb;
203
 
204
  $tableName = $wpdb->prefix.'usermeta';
205
  $metaKey = $wpdb->prefix.'capabilities';
206
  $defaultRole = get_option('default_role');
207
  $standardRoles = array('administrator', 'editor', 'author', 'contributor', 'subscriber');
208
- $rolesCanDelete = array();
209
- foreach ($roles as $key=>$role) {
210
  $canDelete = true;
211
  // check if it is default role for new users
212
  if ($key==$defaultRole) {
@@ -227,9 +367,9 @@ function getRolesCanDelete($roles) {
227
  $query = "SELECT meta_value
228
  FROM $tableName
229
  WHERE meta_key='$metaKey' AND meta_value like '%$key%'";
230
- $rolesUsed = $wpdb->get_results($query);
231
- if ($rolesUsed && count($rolesUsed>0)) {
232
- foreach ($rolesUsed as $roleUsed) {
233
  $roleName = unserialize($roleUsed->meta_value);
234
  foreach ($roleName as $key1=>$value1) {
235
  if ($key==$key1) {
@@ -243,11 +383,11 @@ function getRolesCanDelete($roles) {
243
  }
244
  }
245
  if ($canDelete) {
246
- $rolesCanDelete[$key] = $role['name'];
247
  }
248
  }
249
 
250
- return $rolesCanDelete;
251
  }
252
  // end of getRolesCanDelete()
253
 
@@ -311,32 +451,6 @@ function ure_changeDefaultRole() {
311
  // end of ure_changeDefaultRole()
312
 
313
 
314
- // returns true is user has Role "Administrator"
315
- function ure_is_admin($user_id) {
316
- global $wpdb, $ure_userToEdit;
317
-
318
- if (!isset($user_id) || !$user_id) {
319
- return false;
320
- }
321
-
322
- $tableName = $wpdb->prefix.'usermeta';
323
- $metaKey = $wpdb->prefix.'capabilities';
324
- $query = "SELECT count(*)
325
- FROM $tableName
326
- WHERE user_id=$user_id AND meta_key='$metaKey' AND meta_value like '%administrator%'";
327
- $hasAdminRole = $wpdb->get_var($query);
328
- if ($hasAdminRole>0) {
329
- $result = true;
330
- } else {
331
- $result = false;
332
- }
333
- $ure_userToEdit[$user_id] = $result;
334
-
335
- return $result;
336
- }
337
- // end of ure_is_admin()
338
-
339
-
340
  function ure_ConvertCapsToReadable($capsName) {
341
 
342
  $capsName = str_replace('_', ' ', $capsName);
31
  define('URE_WP_ADMIN_URL', $ure_siteURL.'/wp-admin');
32
  define('URE_ERROR', 'Error is encountered');
33
  define('URE_SPACE_REPLACER', '_URE-SR_');
34
+ define('URE_PARENT', 'users.php');
35
 
36
+ global $wpdb, $ure_roles, $ure_capabilitiesToSave, $ure_currentRole, $ure_toldAboutBackup, $ure_apply_to_all;
37
+
38
+ $ure_roles = false; $ure_capabilitiesToSave = false; $ure_toldAboutBackup = false; $ure_apply_to_all = false;
39
 
 
40
  // this array will be used to cash users checked for Administrator role
41
  $ure_userToEdit = array();
42
 
58
  }
59
  // end of ure_logEvent()
60
 
61
+
62
+ // returns true is user has Role "Administrator"
63
+ function ure_has_administrator_role($user_id) {
64
+ global $wpdb, $ure_userToEdit;
65
+
66
+ if (!isset($user_id) || !$user_id) {
67
+ return false;
68
+ }
69
+
70
+ $tableName = $wpdb->prefix.'usermeta';
71
+ $metaKey = $wpdb->prefix.'capabilities';
72
+ $query = "SELECT count(*)
73
+ FROM $tableName
74
+ WHERE user_id=$user_id AND meta_key='$metaKey' AND meta_value like '%administrator%'";
75
+ $hasAdminRole = $wpdb->get_var($query);
76
+ if ($hasAdminRole>0) {
77
+ $result = true;
78
+ } else {
79
+ $result = false;
80
+ }
81
+ $ure_userToEdit[$user_id] = $result;
82
+
83
+ return $result;
84
+ }
85
+ // end of ure_has_administrator_role()
86
+
87
+
88
+ // true if user is superadmin under multi-site environment or has administrator role
89
+ function ure_is_admin( $user_id = false ) {
90
+ global $current_user;
91
+
92
+ if ( ! $user_id ) {
93
+ if (empty($current_user) && function_exists('get_currentuserinfo')) {
94
+ get_currentuserinfo();
95
+ }
96
+ $user_id = ! empty($current_user) ? $current_user->id : 0;
97
+ }
98
+
99
+ if ( ! $user_id )
100
+ return false;
101
+
102
+ $user = new WP_User($user_id);
103
+
104
+ $simpleAdmin = ure_has_administrator_role($user_id);
105
+
106
+ if ( is_multisite() ) {
107
+ $super_admins = get_super_admins();
108
+ $superAdmin = is_array( $super_admins ) && in_array( $user->user_login, $super_admins );
109
+ } else {
110
+ $superAdmin = false;
111
+ }
112
+
113
+ return $simpleAdmin || $superAdmin;
114
+ }
115
+ // end of ure_is_super_admin()
116
+
117
+
118
  function ure_optionSelected($value, $etalon) {
119
  $selected = '';
120
  if ($value==$etalon) {
142
 
143
 
144
  function ure_getUserRoles() {
145
+ global $wpdb;
146
+
147
+ $ure_OptionsTable = $wpdb->prefix .'options';
148
  $option_name = $wpdb->prefix.'user_roles';
149
  $getRolesQuery = "select option_id, option_value
150
  from $ure_OptionsTable
155
  ure_logEvent($wpdb->last_error);
156
  return;
157
  }
158
+ $ure_roles = unserialize($record[0]->option_value);
159
 
160
+ return $ure_roles;
161
  }
162
  // end of getUserRoles()
163
 
165
  // restores User Roles from the backup record
166
  function restoreUserRoles() {
167
 
168
+ global $wpdb;
169
 
170
  $errorMessage = 'Error! '.__('Database operation error. Check log file.', 'ure');
171
+ $ure_OptionsTable = $wpdb->prefix .'options';
172
  $option_name = $wpdb->prefix.'user_roles';
173
  $backup_option_name = $wpdb->prefix.'backup_user_roles';
174
  $query = "select option_value
203
  // end of restorUserRoles()
204
 
205
 
206
+ function ure_makeRolesBackup() {
207
+ global $wpdb, $mess, $ure_roles, $ure_capabilitiesToSave, $ure_toldAboutBackup;
208
+
209
+ $ure_OptionsTable = $wpdb->prefix .'options';
210
+ // check if backup user roles record exists already
211
+ $backup_option_name = $wpdb->prefix.'backup_user_roles';
212
+ $query = "select option_id
213
+ from $ure_OptionsTable
214
+ where option_name='$backup_option_name'
215
+ limit 0, 1";
216
+ $option_id = $wpdb->get_var($query);
217
+ if ($wpdb->last_error) {
218
+ ure_logEvent($wpdb->last_error, true);
219
+ return false;
220
+ }
221
+ if (!$option_id) {
222
+ // create user roles record backup
223
+ $serialized_roles = mysql_real_escape_string(serialize($ure_roles));
224
+ $query = "insert into $ure_OptionsTable
225
+ (option_name, option_value, autoload)
226
+ values ('$backup_option_name', '$serialized_roles', 'yes')";
227
+ $record = $wpdb->query($query);
228
+ if ($wpdb->last_error) {
229
+ ure_logEvent($wpdb->last_error, true);
230
+ return false;
231
+ }
232
+ if (!$ure_toldAboutBackup) {
233
+ $ure_toldAboutBackup = true;
234
+ $mess .= __('Backup record is created for the current role capabilities', 'ure');
235
+ }
236
+ }
237
+
238
+ return true;
239
+ }
240
+ // end of ure_makeRolesBackup()
241
+
242
+
243
  // Save Roles to database
244
+ function ure_saveRolesToDb() {
245
+ global $wpdb, $ure_roles, $ure_capabilitiesToSave, $ure_currentRole;
246
 
247
+ $ure_OptionsTable = $wpdb->prefix .'options';
248
+ if (!isset($ure_roles[$ure_currentRole])) {
249
+ $ure_roles[$ure_currentRole]['name'] = $ure_currentRole;
250
+ }
251
+ $ure_roles[$ure_currentRole]['capabilities'] = $ure_capabilitiesToSave;
252
  $option_name = $wpdb->prefix.'user_roles';
253
+ $serialized_roles = serialize($ure_roles);
254
  $query = "update $ure_OptionsTable
255
  set option_value='$serialized_roles'
256
  where option_name='$option_name'
266
  // end of saveRolesToDb()
267
 
268
 
269
+ function ure_updateRoles() {
270
+ global $wpdb, $ure_apply_to_all, $ure_roles;
271
+
272
+ $ure_toldAboutBackup = false;
273
+ if (is_multisite() && $ure_apply_to_all) { // update Role for the all blogs/sites in the network
274
+ $old_blog = $wpdb->blogid;
275
+ // Get all blog ids
276
+ $blogIds = $wpdb->get_col($wpdb->prepare("SELECT blog_id FROM $wpdb->blogs"));
277
+ foreach ($blogIds as $blog_id) {
278
+ switch_to_blog($blog_id);
279
+ $ure_roles = ure_getUserRoles();
280
+ if (!$ure_roles) {
281
+ return false;
282
+ }
283
+ if (!ure_makeRolesBackup()) {
284
+ return false;
285
+ }
286
+ if (!ure_saveRolesToDb()) {
287
+ return false;
288
+ }
289
+ }
290
+ switch_to_blog($old_blog);
291
+ $ure_roles = ure_getUserRoles();
292
+ } else {
293
+ if (!ure_makeRolesBackup()) {
294
+ return false;
295
+ }
296
+ if (!ure_saveRolesToDb()) {
297
+ return false;
298
+ }
299
+ }
300
+
301
+ return true;
302
+ }
303
+ // end of ure_updateRoles()
304
+
305
+
306
  // process new role create request
307
+ function ure_newRoleCreate(&$ure_currentRole) {
308
 
309
  $mess = '';
310
+ $ure_currentRole = '';
311
  if (isset($_GET['user_role']) && $_GET['user_role']) {
312
  $user_role = utf8_decode(urldecode($_GET['user_role']));
313
  // sanitize user input for security
318
  if ($user_role) {
319
  $user_role = esc_html($user_role);
320
  $user_role = mysql_real_escape_string($user_role);
321
+ $ure_roles = ure_getUserRoles();
322
+ if (!$ure_roles) {
323
  return 'Error! '.__('Roles list reading error is encountered', 'ure');;
324
  }
325
  // add new role to the roles array
326
+ $ure_currentRole = strtolower($user_role);
327
+ $result = add_role($ure_currentRole, $user_role, array('read'=>1, 'level_0'=>1));
328
  if (!isset($result) || !$result) {
329
  $mess = 'Error! '.__('Error is encountered during new role create operation', 'ure');
330
  } else {
338
 
339
 
340
  // define roles which we could delete, e.g self-created and not used with any blog user
341
+ function getRolesCanDelete($ure_roles) {
342
  global $wpdb;
343
 
344
  $tableName = $wpdb->prefix.'usermeta';
345
  $metaKey = $wpdb->prefix.'capabilities';
346
  $defaultRole = get_option('default_role');
347
  $standardRoles = array('administrator', 'editor', 'author', 'contributor', 'subscriber');
348
+ $ure_rolesCanDelete = array();
349
+ foreach ($ure_roles as $key=>$role) {
350
  $canDelete = true;
351
  // check if it is default role for new users
352
  if ($key==$defaultRole) {
367
  $query = "SELECT meta_value
368
  FROM $tableName
369
  WHERE meta_key='$metaKey' AND meta_value like '%$key%'";
370
+ $ure_rolesUsed = $wpdb->get_results($query);
371
+ if ($ure_rolesUsed && count($ure_rolesUsed>0)) {
372
+ foreach ($ure_rolesUsed as $roleUsed) {
373
  $roleName = unserialize($roleUsed->meta_value);
374
  foreach ($roleName as $key1=>$value1) {
375
  if ($key==$key1) {
383
  }
384
  }
385
  if ($canDelete) {
386
+ $ure_rolesCanDelete[$key] = $role['name'];
387
  }
388
  }
389
 
390
+ return $ure_rolesCanDelete;
391
  }
392
  // end of getRolesCanDelete()
393
 
451
  // end of ure_changeDefaultRole()
452
 
453
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
454
  function ure_ConvertCapsToReadable($capsName) {
455
 
456
  $capsName = str_replace('_', ' ', $capsName);
ure-options.php CHANGED
@@ -10,6 +10,7 @@ if (!defined('URE_PLUGIN_URL')) {
10
 
11
  $shinephpFavIcon = URE_PLUGIN_URL.'/images/vladimir.png';
12
  $mess = '';
 
13
  $ure_caps_readable = get_option('ure_caps_readable');
14
  $option_name = $wpdb->prefix.'user_roles';
15
 
@@ -20,7 +21,7 @@ if (isset($_GET['action'])) {
20
  $mess = restoreUserRoles();
21
  } else if ($action=='addnewrole') {
22
  // process new role create request
23
- $mess = ure_newRoleCreate($currentRole);
24
  } else if ($action=='delete') {
25
  $mess = ure_deleteRole();
26
  } else if ($action=='default') {
@@ -37,30 +38,36 @@ if (isset($_GET['action'])) {
37
 
38
  $defaultRole = get_option('default_role');
39
 
40
- if (!isset($roles) || !$roles) {
 
 
 
 
 
 
41
  // get roles data from database
42
- $roles = ure_getUserRoles();
43
- if (!$roles) {
44
  return;
45
  }
46
  }
47
 
48
- $rolesId = array();
49
- foreach ($roles as $key=>$value) {
50
- $rolesId[] = $key;
51
  }
52
 
53
- if (!isset($currentRole) || !$currentRole) {
54
- $currentRole = $rolesId[count($rolesId) - 1];
55
  if (isset($_REQUEST['user_role']) && $_REQUEST['user_role']) {
56
- $currentRole = $_REQUEST['user_role'];
57
  }
58
  }
59
 
60
  $roleDefaultHTML = '<select id="default_user_role" name="default_user_role" width="200" style="width: 200px">';
61
  $roleSelectHTML = '<select id="user_role" name="user_role" onchange="ure_Actions(\'role-change\', this.value);">';
62
- foreach ($roles as $key=>$value) {
63
- $selected1 = ure_optionSelected($key, $currentRole);
64
  $selected2 = ure_optionSelected($key, $defaultRole);
65
  if ($key!='administrator') {
66
  $roleSelectHTML .= '<option value="'.$key.'" '.$selected1.'>'.__($value['name'], 'ure').'</option>';
@@ -71,61 +78,39 @@ $roleSelectHTML .= '</select>';
71
  $roleDefaultHTML .= '</select>';
72
 
73
  $fullCapabilities = array();
74
- $role = $roles['administrator'];
75
- foreach ($role['capabilities'] as $key=>$value) {
76
- $fullCapabilities[] = $key;
 
77
  }
 
 
78
 
79
  // save role changes to database block
80
  if (isset($_POST['action']) && $_POST['action']=='update' && isset($_POST['user_role'])) {
81
- $currentRole = $_POST['user_role'];
82
- $capabilityToSave = array();
83
- foreach($roles['administrator']['capabilities'] as $availableCapability=>$value) {
84
  $cap_id = str_replace(' ', URE_SPACE_REPLACER, $availableCapability);
85
  if (isset($_POST[$cap_id])) {
86
- $capabilityToSave[$availableCapability] = 1;
87
  }
88
  }
89
- if (count($capabilityToSave)>0) {
90
- // check if backup user roles record exists already
91
- $backup_option_name = $wpdb->prefix.'backup_user_roles';
92
- $query = "select option_id
93
- from $ure_OptionsTable
94
- where option_name='$backup_option_name'
95
- limit 0, 1";
96
- $option_id = $wpdb->get_var($query);
97
- if ($wpdb->last_error) {
98
- ure_logEvent($wpdb->last_error, true);
99
- return;
100
- }
101
- if (!$option_id) {
102
- // create user roles record backup
103
- $serialized_roles = mysql_real_escape_string(serialize($roles));
104
- $query = "insert into $ure_OptionsTable
105
- (option_name, option_value, autoload)
106
- values ('$backup_option_name', '$serialized_roles', 'yes')";
107
- $record = $wpdb->query($query);
108
- if ($wpdb->last_error) {
109
- ure_logEvent($wpdb->last_error, true);
110
- return;
111
- }
112
- $mess .= __('Backup record is created for the current role capabilities', 'ure');
113
- }
114
- $roles[$currentRole]['capabilities'] = $capabilityToSave;
115
- if (!ure_saveRolesToDb($roles)) {
116
  return;
117
  }
118
  if ($mess) {
119
  $mess .= '<br/>';
120
  }
121
- $mess = __('Role', 'ure').' <em>'.__($roles[$currentRole]['name'], 'ure').'</em> '.__('is updated successfully', 'ure');
122
  }
123
  }
124
 
125
- $rolesCanDelete = getRolesCanDelete($roles);
126
- if ($rolesCanDelete && count($rolesCanDelete)>0) {
127
  $roleDeleteHTML = '<select id="del_user_role" name="del_user_role" width="200" style="width: 200px">';
128
- foreach ($rolesCanDelete as $key=>$value) {
129
  $roleDeleteHTML .= '<option value="'.$key.'">'.__($value, 'ure').'</option>';
130
  }
131
  $roleDeleteHTML .= '</select>';
@@ -155,7 +140,7 @@ function ure_displayBoxEnd() {
155
  ure_showMessage($mess);
156
 
157
  ?>
158
- <form method="post" action="users.php?page=user-role-editor.php" onsubmit="return ure_onSubmit();">
159
  <?php
160
  settings_fields('ure-options');
161
  ?>
@@ -188,6 +173,7 @@ ure_showMessage($mess);
188
  <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/tagsite.png'; ?>)" target="_blank" title="<?php _e("For the help with Polish translation", 'ure'); ?>" href="http://www.tagsite.eu">TagSite</a>
189
  <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/dario.png'; ?>)" target="_blank" title="<?php _e("For the help with Spanish translation", 'ure'); ?>" href="http://www.darioferrer.com">Dario Ferrer</a>
190
  <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/sadri.png'; ?>)" target="_blank" title="<?php _e("For the help with Turkish translation", 'ure'); ?>" href="http://www.faydaliweb.com">Sadri Ercan</a>
 
191
  <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/fullthrottle.png'; ?>)" target="_blank" title="<?php _e("For the code to hide administrator role", 'ure'); ?>" href="http://fullthrottledevelopment.com/how-to-hide-the-adminstrator-on-the-wordpress-users-screen">FullThrottle</a>
192
  <?php _e('Do you wish to see your name with link to your site here? You are welcome! Your help with translation and new ideas are very appreciated.', 'ure'); ?>
193
  <?php ure_displayBoxEnd(); ?>
@@ -196,9 +182,25 @@ ure_showMessage($mess);
196
  <div class="has-sidebar" >
197
  <div id="post-body-content" class="has-sidebar-content">
198
  <script language="javascript" type="text/javascript">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
199
  function ure_Actions(action, value) {
200
  if (action=='cancel') {
201
- document.location = '<?php echo URE_WP_ADMIN_URL; ?>/users.php?page=user-role-editor.php';
202
  return;
203
  }
204
  if (action=='addnewrole') {
@@ -225,7 +227,7 @@ ure_showMessage($mess);
225
  }
226
  }
227
  if (action!='update') {
228
- url = '<?php echo URE_WP_ADMIN_URL; ?>/users.php?page=user-role-editor.php&action='+ action;
229
  if (action=='delete') {
230
  el = document.getElementById('del_user_role');
231
  value = el.options[el.selectedIndex].value;
@@ -245,7 +247,7 @@ ure_showMessage($mess);
245
 
246
 
247
  function ure_onSubmit() {
248
- if (!confirm('<?php echo sprintf(__('Role "%s" update: please confirm to continue', 'ure'), __($roles[$currentRole]['name'], 'ure')); ?>')) {
249
  return false;
250
  }
251
  }
@@ -253,38 +255,63 @@ ure_showMessage($mess);
253
 
254
  </script>
255
  <?php
256
- ure_displayBoxStart(__('Select Role and change its capabilities list', 'ure')); ?>
257
- <table class="form-table" style="clear:none;" cellpadding="0" cellspacing="0">
258
- <tr>
259
- <td style="vertical-align:top;width:200px;" colspan="3">
260
- <?php echo __('Select Role:', 'ure').' '.$roleSelectHTML; ?>
261
- </td>
262
- </tr>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
263
  <tr>
264
  <td style="vertical-align:top;">
265
  <?php
266
  $quant = count($fullCapabilities);
267
  $quantInColumn = (int) $quant/3;
268
- $i = 0; $quantInCell = 0;
269
- while($i<$quant) {
270
  $checked = '';
271
- if (isset($roles[$currentRole]['capabilities'][$fullCapabilities[$i]])) {
272
  $checked = 'checked="checked"';
273
  }
274
- $cap_id = str_replace(' ', URE_SPACE_REPLACER, $fullCapabilities[$i]);
275
  ?>
276
- <input type="checkbox" name="<?php echo $cap_id; ?>" id="<?php echo $cap_id; ?>" value="<?php echo $fullCapabilities[$i]; ?>" <?php echo $checked; ?>/>
277
  <?php
278
  if ($ure_caps_readable) {
279
  ?>
280
- <label for="<?php echo $cap_id; ?>" title="<?php echo $fullCapabilities[$i]; ?>" ><?php _e(ure_ConvertCapsToReadable($fullCapabilities[$i]),'ure'); ?></label><br/>
281
  <?php
282
  } else {
283
  ?>
284
- <label for="<?php echo $cap_id; ?>" title="<?php _e(ure_ConvertCapsToReadable($fullCapabilities[$i]),'ure'); ?>" ><?php echo $fullCapabilities[$i]; ?></label><br/>
285
  <?php
286
  }
287
- $i++; $quantInCell++;
288
  if ($quantInCell>=$quantInColumn) {
289
  $quantInCell = 0;
290
  echo '</td>
@@ -300,19 +327,10 @@ ure_showMessage($mess);
300
  <div class="submit" style="padding-top: 0px;">
301
  <div style="float:left; padding-bottom: 10px;">
302
  <input type="submit" name="submit" value="<?php _e('Update', 'ure'); ?>" title="<?php _e('Save Changes', 'ure'); ?>" />
303
- <input type="button" name="cancel" value="<?php _e('Cancel', 'ure') ?>" title="<?php _e('Cancel not saved changes','ure');?>" onclick="ure_Actions('cancel');"/>
304
- <input type="button" name="default" value="<?php _e('Reset', 'ure') ?>" title="<?php _e('Restore Roles from backup copy','ure');?>" onclick="ure_Actions('reset');"/>
305
  </div>
306
- <div style="float: right; margin-right: 10px;">
307
- <?php
308
- if ($ure_caps_readable) {
309
- $checked = 'checked="checked"';
310
- } else {
311
- $checked = '';
312
- }
313
- ?>
314
- <input type="checkbox" name="ure_caps_readable" id="ure_caps_readable" value="1" <?php echo $checked; ?> onclick="ure_Actions('capsreadable');"/>
315
- <label for="ure_caps_readable"><?php _e('Show capabilities in human readable form', 'ure');?></label>
316
  </div>
317
  </div>
318
  <?php
10
 
11
  $shinephpFavIcon = URE_PLUGIN_URL.'/images/vladimir.png';
12
  $mess = '';
13
+
14
  $ure_caps_readable = get_option('ure_caps_readable');
15
  $option_name = $wpdb->prefix.'user_roles';
16
 
21
  $mess = restoreUserRoles();
22
  } else if ($action=='addnewrole') {
23
  // process new role create request
24
+ $mess = ure_newRoleCreate($ure_currentRole);
25
  } else if ($action=='delete') {
26
  $mess = ure_deleteRole();
27
  } else if ($action=='default') {
38
 
39
  $defaultRole = get_option('default_role');
40
 
41
+ if (isset($_POST['ure_apply_to_all'])) {
42
+ $ure_apply_to_all = 1;
43
+ } else {
44
+ $ure_apply_to_all = 0;
45
+ }
46
+
47
+ if (!isset($ure_roles) || !$ure_roles) {
48
  // get roles data from database
49
+ $ure_roles = ure_getUserRoles();
50
+ if (!$ure_roles) {
51
  return;
52
  }
53
  }
54
 
55
+ $ure_rolesId = array();
56
+ foreach ($ure_roles as $key=>$value) {
57
+ $ure_rolesId[] = $key;
58
  }
59
 
60
+ if (!isset($ure_currentRole) || !$ure_currentRole) {
61
+ $ure_currentRole = $ure_rolesId[count($ure_rolesId) - 1];
62
  if (isset($_REQUEST['user_role']) && $_REQUEST['user_role']) {
63
+ $ure_currentRole = $_REQUEST['user_role'];
64
  }
65
  }
66
 
67
  $roleDefaultHTML = '<select id="default_user_role" name="default_user_role" width="200" style="width: 200px">';
68
  $roleSelectHTML = '<select id="user_role" name="user_role" onchange="ure_Actions(\'role-change\', this.value);">';
69
+ foreach ($ure_roles as $key=>$value) {
70
+ $selected1 = ure_optionSelected($key, $ure_currentRole);
71
  $selected2 = ure_optionSelected($key, $defaultRole);
72
  if ($key!='administrator') {
73
  $roleSelectHTML .= '<option value="'.$key.'" '.$selected1.'>'.__($value['name'], 'ure').'</option>';
78
  $roleDefaultHTML .= '</select>';
79
 
80
  $fullCapabilities = array();
81
+ foreach($ure_roles as $role) {
82
+ foreach ($role['capabilities'] as $key=>$value) {
83
+ $fullCapabilities[] = $key;
84
+ }
85
  }
86
+ $fullCapabilities = array_unique($fullCapabilities);
87
+ asort($fullCapabilities);
88
 
89
  // save role changes to database block
90
  if (isset($_POST['action']) && $_POST['action']=='update' && isset($_POST['user_role'])) {
91
+ $ure_currentRole = $_POST['user_role'];
92
+ $ure_capabilitiesToSave = array();
93
+ foreach($fullCapabilities as $availableCapability) {
94
  $cap_id = str_replace(' ', URE_SPACE_REPLACER, $availableCapability);
95
  if (isset($_POST[$cap_id])) {
96
+ $ure_capabilitiesToSave[$availableCapability] = 1;
97
  }
98
  }
99
+ if (count($ure_capabilitiesToSave)>0) {
100
+ if (!ure_updateRoles()) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
101
  return;
102
  }
103
  if ($mess) {
104
  $mess .= '<br/>';
105
  }
106
+ $mess = __('Role', 'ure').' <em>'.__($ure_roles[$ure_currentRole]['name'], 'ure').'</em> '.__('is updated successfully', 'ure');
107
  }
108
  }
109
 
110
+ $ure_rolesCanDelete = getRolesCanDelete($ure_roles);
111
+ if ($ure_rolesCanDelete && count($ure_rolesCanDelete)>0) {
112
  $roleDeleteHTML = '<select id="del_user_role" name="del_user_role" width="200" style="width: 200px">';
113
+ foreach ($ure_rolesCanDelete as $key=>$value) {
114
  $roleDeleteHTML .= '<option value="'.$key.'">'.__($value, 'ure').'</option>';
115
  }
116
  $roleDeleteHTML .= '</select>';
140
  ure_showMessage($mess);
141
 
142
  ?>
143
+ <form method="post" action="<?php echo URE_PARENT; ?>?page=user-role-editor.php" onsubmit="return ure_onSubmit();">
144
  <?php
145
  settings_fields('ure-options');
146
  ?>
173
  <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/tagsite.png'; ?>)" target="_blank" title="<?php _e("For the help with Polish translation", 'ure'); ?>" href="http://www.tagsite.eu">TagSite</a>
174
  <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/dario.png'; ?>)" target="_blank" title="<?php _e("For the help with Spanish translation", 'ure'); ?>" href="http://www.darioferrer.com">Dario Ferrer</a>
175
  <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/sadri.png'; ?>)" target="_blank" title="<?php _e("For the help with Turkish translation", 'ure'); ?>" href="http://www.faydaliweb.com">Sadri Ercan</a>
176
+ <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/cartaca.png'; ?>)" target="_blank" title="<?php _e("For the help with Turkish translation", 'ure'); ?>" href="http://www.kartaca.com">Can KAYA</a>
177
  <a class="ure_rsb_link" style="background-image:url(<?php echo URE_PLUGIN_URL.'/images/fullthrottle.png'; ?>)" target="_blank" title="<?php _e("For the code to hide administrator role", 'ure'); ?>" href="http://fullthrottledevelopment.com/how-to-hide-the-adminstrator-on-the-wordpress-users-screen">FullThrottle</a>
178
  <?php _e('Do you wish to see your name with link to your site here? You are welcome! Your help with translation and new ideas are very appreciated.', 'ure'); ?>
179
  <?php ure_displayBoxEnd(); ?>
182
  <div class="has-sidebar" >
183
  <div id="post-body-content" class="has-sidebar-content">
184
  <script language="javascript" type="text/javascript">
185
+ <?php
186
+ if (is_multisite()) {
187
+ ?>
188
+
189
+ function ure_applyToAllOnClick(cb) {
190
+ el = document.getElementById('ure_apply_to_all_div');
191
+ if (cb.checked) {
192
+ el.style.color = '#FF0000';
193
+ } else {
194
+ el.style.color = '#000000';
195
+ }
196
+ }
197
+ <?php
198
+ }
199
+ ?>
200
+
201
  function ure_Actions(action, value) {
202
  if (action=='cancel') {
203
+ document.location = '<?php echo URE_WP_ADMIN_URL.'/'.URE_PARENT; ?>?page=user-role-editor.php';
204
  return;
205
  }
206
  if (action=='addnewrole') {
227
  }
228
  }
229
  if (action!='update') {
230
+ url = '<?php echo URE_WP_ADMIN_URL.'/'.URE_PARENT; ?>?page=user-role-editor.php&action='+ action;
231
  if (action=='delete') {
232
  el = document.getElementById('del_user_role');
233
  value = el.options[el.selectedIndex].value;
247
 
248
 
249
  function ure_onSubmit() {
250
+ if (!confirm('<?php echo sprintf(__('Role "%s" update: please confirm to continue', 'ure'), __($ure_roles[$ure_currentRole]['name'], 'ure')); ?>')) {
251
  return false;
252
  }
253
  }
255
 
256
  </script>
257
  <?php
258
+ ure_displayBoxStart(__('Select Role and change its capabilities list', 'ure'));
259
+ ?>
260
+ <div style="float: left;"><?php echo __('Select Role:', 'ure').' '.$roleSelectHTML; ?></div>
261
+ <?php
262
+ if ($ure_caps_readable) {
263
+ $checked = 'checked="checked"';
264
+ } else {
265
+ $checked = '';
266
+ }
267
+ ?>
268
+ <div style="display:inline;float: right;"><input type="checkbox" name="ure_caps_readable" id="ure_caps_readable" value="1" <?php echo $checked; ?> onclick="ure_Actions('capsreadable');"/>
269
+ <label for="ure_caps_readable"><?php _e('Show capabilities in human readable form', 'ure');?></label>
270
+ </div>
271
+ <?php
272
+ if (is_multisite()) {
273
+ $hint = __('If checked, then apply action to ALL sites of this Network');
274
+ if ($ure_apply_to_all) {
275
+ $checked = 'checked="checked"';
276
+ $fontColor = 'color:#FF0000;';
277
+ } else {
278
+ $checked = '';
279
+ $fontColor = '';
280
+ }
281
+ ?>
282
+ <div style="float: right; margin-right: 20px; <?php echo $fontColor;?>" id="ure_apply_to_all_div"><input type="checkbox" name="ure_apply_to_all" id="ure_apply_to_all" value="1" <?php echo $checked; ?> title="<?php echo $hint;?>" onclick="ure_applyToAllOnClick(this)"/>
283
+ <label for="ure_apply_to_all" title="<?php echo $hint;?>"><?php _e('Apply to All Sites', 'ure');?></label>
284
+ </div>
285
+ <?php
286
+ }
287
+ ?>
288
+ <br/><br/><hr/>
289
+ <table class="form-table" style="clear:none;" cellpadding="0" cellspacing="0">
290
  <tr>
291
  <td style="vertical-align:top;">
292
  <?php
293
  $quant = count($fullCapabilities);
294
  $quantInColumn = (int) $quant/3;
295
+ $quantInCell = 0;
296
+ foreach( $fullCapabilities as $capability) {
297
  $checked = '';
298
+ if (isset($ure_roles[$ure_currentRole]['capabilities'][$capability])) {
299
  $checked = 'checked="checked"';
300
  }
301
+ $cap_id = str_replace(' ', URE_SPACE_REPLACER, $capability);
302
  ?>
303
+ <input type="checkbox" name="<?php echo $cap_id; ?>" id="<?php echo $cap_id; ?>" value="<?php echo $capability; ?>" <?php echo $checked; ?>/>
304
  <?php
305
  if ($ure_caps_readable) {
306
  ?>
307
+ <label for="<?php echo $cap_id; ?>" title="<?php echo $capability; ?>" ><?php _e(ure_ConvertCapsToReadable($capability),'ure'); ?></label><br/>
308
  <?php
309
  } else {
310
  ?>
311
+ <label for="<?php echo $cap_id; ?>" title="<?php _e(ure_ConvertCapsToReadable($capability),'ure'); ?>" ><?php echo $capability; ?></label><br/>
312
  <?php
313
  }
314
+ $quantInCell++;
315
  if ($quantInCell>=$quantInColumn) {
316
  $quantInCell = 0;
317
  echo '</td>
327
  <div class="submit" style="padding-top: 0px;">
328
  <div style="float:left; padding-bottom: 10px;">
329
  <input type="submit" name="submit" value="<?php _e('Update', 'ure'); ?>" title="<?php _e('Save Changes', 'ure'); ?>" />
330
+ <input type="button" name="cancel" value="<?php _e('Cancel', 'ure') ?>" title="<?php _e('Cancel not saved changes','ure');?>" onclick="ure_Actions('cancel');"/>
 
331
  </div>
332
+ <div style="float:right; padding-bottom: 10px;">
333
+ <input type="button" name="default" value="<?php _e('Reset', 'ure') ?>" title="<?php _e('Restore Roles from backup copy','ure');?>" onclick="ure_Actions('reset');"/>
 
 
 
 
 
 
 
 
334
  </div>
335
  </div>
336
  <?php
user-role-editor.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: User Role Editor
4
  Plugin URI: http://www.shinephp.com/user-role-editor-wordpress-plugin/
5
  Description: It allows you to change any standard WordPress user roles (except administrator) capabilities list with a few clicks.
6
- Version: 2.2.2
7
  Author: Vladimir Garagulya
8
  Author URI: http://www.shinephp.com
9
  Text Domain: ure
@@ -11,7 +11,7 @@ Domain Path: /lang/
11
  */
12
 
13
  /*
14
- Copyright 2010 Vladimir Garagulya (email: vladimir@shinephp.com)
15
 
16
  This program is free software; you can redistribute it and/or modify
17
  it under the terms of the GNU General Public License as published by
@@ -28,12 +28,11 @@ along with this program; if not, write to the Free Software
28
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
29
  */
30
 
31
-
32
  if (!function_exists("get_option")) {
33
  die; // Silence is golden, direct call is prohibited
34
  }
35
 
36
- global $wp_version;
37
 
38
  $exit_msg = __('User Role Editor requires WordPress 3.0 or newer.', 'ure').'<a href="http://codex.wordpress.org/Upgrading_WordPress">'.__('Please update!', 'ure').'</a>';
39
 
@@ -50,10 +49,20 @@ load_plugin_textdomain('ure','', $urePluginDirName.'/lang');
50
 
51
  function ure_optionsPage() {
52
 
53
- global $wpdb, $ure_OptionsTable;
54
 
55
- if (!current_user_can('edit_users')) {
56
- die('action is forbidden');
 
 
 
 
 
 
 
 
 
 
57
  }
58
 
59
  ?>
@@ -71,7 +80,7 @@ function ure_optionsPage() {
71
 
72
  // Install plugin
73
  function ure_install() {
74
- delete_option('ure_auto_monitor');
75
  add_option('ure_caps_readable', 0);
76
 
77
  }
@@ -92,7 +101,7 @@ function ure_excludeAdminRole($roles) {
92
 
93
  function ure_admin_jquery(){
94
  global $pagenow;
95
- if ('users.php'==$pagenow){
96
  wp_enqueue_script('jquery');
97
  }
98
  }
@@ -100,7 +109,16 @@ function ure_admin_jquery(){
100
 
101
 
102
  function ure_admin_user_hide(){
103
- if (!current_user_can('edit_users')) {
 
 
 
 
 
 
 
 
 
104
  ?>
105
  <script type='text/javascript' >
106
  jQuery(document).ready(function(){
@@ -154,7 +172,7 @@ function ure_not_edit_admin($allcaps, $caps, $name) {
154
  } else {
155
  if (!isset($ure_userToEdit[$ure_UserId])) {
156
  // check if user_id has Administrator role
157
- $accessDeny = ure_is_admin($ure_UserId);
158
  } else {
159
  // user_id was checked already, get result from cash
160
  $accessDeny = $ure_userToEdit[$ure_UserId];
@@ -173,10 +191,18 @@ function ure_not_edit_admin($allcaps, $caps, $name) {
173
 
174
 
175
  function ure_init() {
176
-
 
 
 
 
 
 
 
 
177
  // these filters and actions should prevent editing users with administrator role
178
  // by other users with 'edit_users' capabilities
179
- if (!current_user_can('edit_users')) {
180
  // Exclude administrator role from edit list.
181
  add_filter('editable_roles', 'ure_excludeAdminRole');
182
  // Enqueue jQuery
@@ -193,7 +219,7 @@ function ure_init() {
193
 
194
  function ure_plugin_action_links($links, $file) {
195
  if ($file == plugin_basename(dirname(__FILE__).'/user-role-editor.php')){
196
- $settings_link = "<a href='users.php?page=user-role-editor.php'>".__('Settings','ure')."</a>";
197
  array_unshift( $links, $settings_link );
198
  }
199
  return $links;
@@ -210,8 +236,14 @@ function ure_plugin_row_meta($links, $file) {
210
 
211
 
212
  function ure_settings_menu() {
213
- if ( function_exists('add_users_page') ) {
214
- $ure_page = add_users_page('User Role Editor', 'User Role Editor', 'edit_users', basename(__FILE__), 'ure_optionsPage');
 
 
 
 
 
 
215
  add_action( "admin_print_styles-$ure_page", 'ure_adminCssAction' );
216
  }
217
  }
@@ -225,7 +257,6 @@ function ure_adminCssAction() {
225
  // end of ure_adminCssAction()
226
 
227
 
228
-
229
  if (is_admin()) {
230
  // activation action
231
  register_activation_hook(__FILE__, "ure_install");
@@ -235,10 +266,6 @@ if (is_admin()) {
235
  add_filter('plugin_action_links', 'ure_plugin_action_links', 10, 2);
236
  add_filter('plugin_row_meta', 'ure_plugin_row_meta', 10, 2);
237
  add_action('admin_menu', 'ure_settings_menu');
238
-
239
  }
240
-
241
-
242
-
243
-
244
- ?>
3
  Plugin Name: User Role Editor
4
  Plugin URI: http://www.shinephp.com/user-role-editor-wordpress-plugin/
5
  Description: It allows you to change any standard WordPress user roles (except administrator) capabilities list with a few clicks.
6
+ Version: 3.0
7
  Author: Vladimir Garagulya
8
  Author URI: http://www.shinephp.com
9
  Text Domain: ure
11
  */
12
 
13
  /*
14
+ Copyright 2010-2011 Vladimir Garagulya (email: vladimir@shinephp.com)
15
 
16
  This program is free software; you can redistribute it and/or modify
17
  it under the terms of the GNU General Public License as published by
28
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
29
  */
30
 
 
31
  if (!function_exists("get_option")) {
32
  die; // Silence is golden, direct call is prohibited
33
  }
34
 
35
+ global $wp_version, $current_user;
36
 
37
  $exit_msg = __('User Role Editor requires WordPress 3.0 or newer.', 'ure').'<a href="http://codex.wordpress.org/Upgrading_WordPress">'.__('Please update!', 'ure').'</a>';
38
 
49
 
50
  function ure_optionsPage() {
51
 
52
+ global $wpdb, $current_user, $ure_OptionsTable, $ure_roles, $ure_capabilitiesToSave, $ure_toldAboutBackup, $ure_currentRole, $ure_apply_to_all;
53
 
54
+ if (!empty($current_user)) {
55
+ $user_id = $current_user->ID;
56
+ } else {
57
+ $user_id = false;
58
+ }
59
+ if (!ure_is_admin($user_id)) {
60
+ if (is_multisite()) {
61
+ $admin = 'SuperAdministrator';
62
+ } else {
63
+ $admin = 'Administrator';
64
+ }
65
+ die('Only '.$admin.' is allowed to use this plugin');
66
  }
67
 
68
  ?>
80
 
81
  // Install plugin
82
  function ure_install() {
83
+
84
  add_option('ure_caps_readable', 0);
85
 
86
  }
101
 
102
  function ure_admin_jquery(){
103
  global $pagenow;
104
+ if (URE_PARENT==$pagenow){
105
  wp_enqueue_script('jquery');
106
  }
107
  }
109
 
110
 
111
  function ure_admin_user_hide(){
112
+
113
+ global $current_user;
114
+
115
+ if (!empty($current_user->ID)) {
116
+ $user_id = $current_user->ID;
117
+ } else {
118
+ $user_id = 0;
119
+ }
120
+
121
+ if (!ure_is_admin($user_id)) {
122
  ?>
123
  <script type='text/javascript' >
124
  jQuery(document).ready(function(){
172
  } else {
173
  if (!isset($ure_userToEdit[$ure_UserId])) {
174
  // check if user_id has Administrator role
175
+ $accessDeny = ure_has_administrator_role($ure_UserId);
176
  } else {
177
  // user_id was checked already, get result from cash
178
  $accessDeny = $ure_userToEdit[$ure_UserId];
191
 
192
 
193
  function ure_init() {
194
+
195
+ global $current_user;
196
+
197
+ if (!empty($current_user->ID)) {
198
+ $user_id = $current_user->ID;
199
+ } else {
200
+ $user_id = 0;
201
+ }
202
+
203
  // these filters and actions should prevent editing users with administrator role
204
  // by other users with 'edit_users' capabilities
205
+ if (!ure_is_admin($user_id)) {
206
  // Exclude administrator role from edit list.
207
  add_filter('editable_roles', 'ure_excludeAdminRole');
208
  // Enqueue jQuery
219
 
220
  function ure_plugin_action_links($links, $file) {
221
  if ($file == plugin_basename(dirname(__FILE__).'/user-role-editor.php')){
222
+ $settings_link = "<a href='".URE_PARENT."?page=user-role-editor.php'>".__('Settings','ure')."</a>";
223
  array_unshift( $links, $settings_link );
224
  }
225
  return $links;
236
 
237
 
238
  function ure_settings_menu() {
239
+
240
+ if ( function_exists('add_submenu_page')) {
241
+ if (!is_multisite()) {
242
+ $keyCapability = 'edit_users';
243
+ } else {
244
+ $keyCapability = 'manage_network_users';
245
+ }
246
+ $ure_page = add_submenu_page('users.php', __('User Role Editor'), __('User Role Editor'), $keyCapability, basename(__FILE__), 'ure_optionsPage');
247
  add_action( "admin_print_styles-$ure_page", 'ure_adminCssAction' );
248
  }
249
  }
257
  // end of ure_adminCssAction()
258
 
259
 
 
260
  if (is_admin()) {
261
  // activation action
262
  register_activation_hook(__FILE__, "ure_install");
266
  add_filter('plugin_action_links', 'ure_plugin_action_links', 10, 2);
267
  add_filter('plugin_row_meta', 'ure_plugin_row_meta', 10, 2);
268
  add_action('admin_menu', 'ure_settings_menu');
 
269
  }
270
+
271
+ ?>