Peter’s Login Redirect - Version 3.0.0.0

Version Description

  • Rebranded to LoginWP.
  • UI revamp.
  • Pro plugin now available.

See the changelog file for full changelog information.

Download this release

Release Info

Developer Collizo4sky
Plugin Icon 128x128 Peter’s Login Redirect
Version 3.0.0.0
Comparing to
See all releases

Code changes from version 2.9.9 to 3.0.0.0

Files changed (201) hide show
  1. changelog.txt +134 -0
  2. languages/peters-login-redirect-cs_CZ.mo +0 -0
  3. languages/peters-login-redirect-cs_CZ.po +0 -346
  4. languages/peters-login-redirect-da_DK.mo +0 -0
  5. languages/peters-login-redirect-da_DK.po +0 -351
  6. languages/peters-login-redirect-de_DE.mo +0 -0
  7. languages/peters-login-redirect-de_DE.po +0 -346
  8. languages/peters-login-redirect-es_ES.mo +0 -0
  9. languages/peters-login-redirect-es_ES.po +0 -354
  10. languages/peters-login-redirect-fr_FR.mo +0 -0
  11. languages/peters-login-redirect-fr_FR.po +0 -360
  12. languages/peters-login-redirect-id_ID.mo +0 -0
  13. languages/peters-login-redirect-id_ID.po +0 -378
  14. languages/peters-login-redirect-lt_LT.mo +0 -0
  15. languages/peters-login-redirect-lt_LT.po +0 -363
  16. languages/peters-login-redirect-nl_NL.mo +0 -0
  17. languages/peters-login-redirect-nl_NL.po +0 -359
  18. languages/peters-login-redirect-pt_BR.mo +0 -0
  19. languages/peters-login-redirect-pt_BR.po +0 -382
  20. languages/peters-login-redirect-ro_RO.mo +0 -0
  21. languages/peters-login-redirect-ro_RO.po +0 -354
  22. languages/peters-login-redirect-ru_RU.mo +0 -0
  23. languages/peters-login-redirect-ru_RU.po +0 -345
  24. languages/peters-login-redirect-sk_SK.mo +0 -0
  25. languages/peters-login-redirect-sk_SK.po +0 -346
  26. languages/peters-login-redirect-sr_RS.mo +0 -0
  27. languages/peters-login-redirect-sr_RS.po +0 -368
  28. languages/peters-login-redirect-uk.mo +0 -0
  29. languages/peters-login-redirect-uk.po +0 -369
  30. languages/peters-login-redirect.mo +0 -0
  31. languages/peters-login-redirect.po +0 -293
  32. languages/peters-login-redirect.pot +642 -0
  33. readme.txt +48 -259
  34. screenshot-1.png +0 -0
  35. src/core/.gitignore +5 -0
  36. src/core/assets/css/admin.css +287 -0
  37. src/core/assets/css/index.php +0 -0
  38. src/core/assets/images/index.php +0 -0
  39. src/core/assets/images/loginwp.png +0 -0
  40. src/core/assets/images/loginwpXprofilepress.png +0 -0
  41. src/core/assets/images/ppress-login-form.png +0 -0
  42. src/core/assets/images/step-1.svg +1 -0
  43. src/core/assets/images/step-2.svg +1 -0
  44. src/core/assets/images/step-complete.svg +1 -0
  45. src/core/assets/index.php +0 -0
  46. src/core/assets/js/admin.js +26 -0
  47. src/core/assets/js/index.php +0 -0
  48. src/core/assets/js/profilepress.js +178 -0
  49. src/core/composer.json +23 -0
  50. src/core/src/Admin/AbstractSettingsPage.php +178 -0
  51. src/core/src/Admin/Admin.php +245 -0
  52. src/core/src/Admin/Installer/LoginWP_Install_Skin.php +26 -0
  53. src/core/src/Admin/Installer/PluginSilentUpgrader.php +592 -0
  54. src/core/src/Admin/Installer/PluginSilentUpgraderSkin.php +47 -0
  55. src/core/src/Admin/Installer/index.php +2 -0
  56. src/core/src/Admin/ProfilePress.php +701 -0
  57. src/core/src/Admin/RedirectWPList.php +334 -0
  58. src/core/src/Admin/RedirectionsPage.php +468 -0
  59. src/core/src/Admin/SettingsPage.php +90 -0
  60. src/core/src/Admin/SettingsPageApi.php +1239 -0
  61. src/core/src/Admin/index.php +0 -0
  62. src/core/src/Admin/views/include.view.php +63 -0
  63. src/core/src/Admin/views/view.bottom-settings.php +119 -0
  64. src/core/src/Admin/views/view.condition-rule.php +43 -0
  65. src/core/src/Admin/views/view.redirect-urls.php +34 -0
  66. src/core/src/Core.php +179 -0
  67. src/core/src/Functions.php +122 -0
  68. src/core/src/Helpers.php +363 -0
  69. mo-admin-notice-featured.php → src/core/src/MoAdminNotice.php +42 -33
  70. src/core/src/Redirections/Redirections.php +106 -0
  71. src/core/src/Redirections/index.php +0 -0
  72. src/core/src/index.php +0 -0
  73. uninstall.php +55 -0
  74. vendor/autoload.php +7 -0
  75. vendor/collizo4sky/persist-admin-notices-dismissal/CHANGES.md +21 -0
  76. vendor/collizo4sky/persist-admin-notices-dismissal/README.md +128 -0
  77. vendor/collizo4sky/persist-admin-notices-dismissal/composer.json +27 -0
  78. vendor/collizo4sky/persist-admin-notices-dismissal/dismiss-notice.js +34 -0
  79. vendor/collizo4sky/persist-admin-notices-dismissal/persist-admin-notices-dismissal.php +189 -0
  80. vendor/composer/ClassLoader.php +481 -0
  81. vendor/composer/InstalledVersions.php +337 -0
  82. vendor/composer/LICENSE +21 -0
  83. vendor/composer/autoload_classmap.php +125 -0
  84. vendor/composer/autoload_files.php +11 -0
  85. vendor/composer/autoload_namespaces.php +9 -0
  86. vendor/composer/autoload_psr4.php +11 -0
  87. vendor/composer/autoload_real.php +75 -0
  88. vendor/composer/autoload_static.php +164 -0
  89. vendor/composer/installed.json +242 -0
  90. vendor/composer/installed.php +62 -0
  91. vendor/composer/installers/.github/workflows/continuous-integration.yml +70 -0
  92. vendor/composer/installers/.github/workflows/lint.yml +30 -0
  93. vendor/composer/installers/.github/workflows/phpstan.yml +51 -0
  94. vendor/composer/installers/LICENSE +19 -0
  95. vendor/composer/installers/composer.json +121 -0
  96. vendor/composer/installers/phpstan.neon.dist +10 -0
  97. vendor/composer/installers/src/Composer/Installers/AglInstaller.php +21 -0
  98. vendor/composer/installers/src/Composer/Installers/AimeosInstaller.php +9 -0
  99. vendor/composer/installers/src/Composer/Installers/AnnotateCmsInstaller.php +11 -0
  100. vendor/composer/installers/src/Composer/Installers/AsgardInstaller.php +49 -0
  101. vendor/composer/installers/src/Composer/Installers/AttogramInstaller.php +9 -0
  102. vendor/composer/installers/src/Composer/Installers/BaseInstaller.php +137 -0
  103. vendor/composer/installers/src/Composer/Installers/BitrixInstaller.php +126 -0
  104. vendor/composer/installers/src/Composer/Installers/BonefishInstaller.php +9 -0
  105. vendor/composer/installers/src/Composer/Installers/CakePHPInstaller.php +65 -0
  106. vendor/composer/installers/src/Composer/Installers/ChefInstaller.php +11 -0
  107. vendor/composer/installers/src/Composer/Installers/CiviCrmInstaller.php +9 -0
  108. vendor/composer/installers/src/Composer/Installers/ClanCatsFrameworkInstaller.php +10 -0
  109. vendor/composer/installers/src/Composer/Installers/CockpitInstaller.php +32 -0
  110. vendor/composer/installers/src/Composer/Installers/CodeIgniterInstaller.php +11 -0
  111. vendor/composer/installers/src/Composer/Installers/Concrete5Installer.php +13 -0
  112. vendor/composer/installers/src/Composer/Installers/CraftInstaller.php +35 -0
  113. vendor/composer/installers/src/Composer/Installers/CroogoInstaller.php +21 -0
  114. vendor/composer/installers/src/Composer/Installers/DecibelInstaller.php +10 -0
  115. vendor/composer/installers/src/Composer/Installers/DframeInstaller.php +10 -0
  116. vendor/composer/installers/src/Composer/Installers/DokuWikiInstaller.php +50 -0
  117. vendor/composer/installers/src/Composer/Installers/DolibarrInstaller.php +16 -0
  118. vendor/composer/installers/src/Composer/Installers/DrupalInstaller.php +22 -0
  119. vendor/composer/installers/src/Composer/Installers/ElggInstaller.php +9 -0
  120. vendor/composer/installers/src/Composer/Installers/EliasisInstaller.php +12 -0
  121. vendor/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php +29 -0
  122. vendor/composer/installers/src/Composer/Installers/EzPlatformInstaller.php +10 -0
  123. vendor/composer/installers/src/Composer/Installers/FuelInstaller.php +11 -0
  124. vendor/composer/installers/src/Composer/Installers/FuelphpInstaller.php +9 -0
  125. vendor/composer/installers/src/Composer/Installers/GravInstaller.php +30 -0
  126. vendor/composer/installers/src/Composer/Installers/HuradInstaller.php +25 -0
  127. vendor/composer/installers/src/Composer/Installers/ImageCMSInstaller.php +11 -0
  128. vendor/composer/installers/src/Composer/Installers/Installer.php +297 -0
  129. vendor/composer/installers/src/Composer/Installers/ItopInstaller.php +9 -0
  130. vendor/composer/installers/src/Composer/Installers/JoomlaInstaller.php +15 -0
  131. vendor/composer/installers/src/Composer/Installers/KanboardInstaller.php +18 -0
  132. vendor/composer/installers/src/Composer/Installers/KirbyInstaller.php +11 -0
  133. vendor/composer/installers/src/Composer/Installers/KnownInstaller.php +11 -0
  134. vendor/composer/installers/src/Composer/Installers/KodiCMSInstaller.php +10 -0
  135. vendor/composer/installers/src/Composer/Installers/KohanaInstaller.php +9 -0
  136. vendor/composer/installers/src/Composer/Installers/LanManagementSystemInstaller.php +27 -0
  137. vendor/composer/installers/src/Composer/Installers/LaravelInstaller.php +9 -0
  138. vendor/composer/installers/src/Composer/Installers/LavaLiteInstaller.php +10 -0
  139. vendor/composer/installers/src/Composer/Installers/LithiumInstaller.php +10 -0
  140. vendor/composer/installers/src/Composer/Installers/MODULEWorkInstaller.php +9 -0
  141. vendor/composer/installers/src/Composer/Installers/MODXEvoInstaller.php +16 -0
  142. vendor/composer/installers/src/Composer/Installers/MagentoInstaller.php +11 -0
  143. vendor/composer/installers/src/Composer/Installers/MajimaInstaller.php +37 -0
  144. vendor/composer/installers/src/Composer/Installers/MakoInstaller.php +9 -0
  145. vendor/composer/installers/src/Composer/Installers/MantisBTInstaller.php +23 -0
  146. vendor/composer/installers/src/Composer/Installers/MauticInstaller.php +48 -0
  147. vendor/composer/installers/src/Composer/Installers/MayaInstaller.php +33 -0
  148. vendor/composer/installers/src/Composer/Installers/MediaWikiInstaller.php +51 -0
  149. vendor/composer/installers/src/Composer/Installers/MiaoxingInstaller.php +10 -0
  150. vendor/composer/installers/src/Composer/Installers/MicroweberInstaller.php +119 -0
  151. vendor/composer/installers/src/Composer/Installers/ModxInstaller.php +12 -0
  152. vendor/composer/installers/src/Composer/Installers/MoodleInstaller.php +59 -0
  153. vendor/composer/installers/src/Composer/Installers/OctoberInstaller.php +48 -0
  154. vendor/composer/installers/src/Composer/Installers/OntoWikiInstaller.php +24 -0
  155. vendor/composer/installers/src/Composer/Installers/OsclassInstaller.php +14 -0
  156. vendor/composer/installers/src/Composer/Installers/OxidInstaller.php +59 -0
  157. vendor/composer/installers/src/Composer/Installers/PPIInstaller.php +9 -0
  158. vendor/composer/installers/src/Composer/Installers/PhiftyInstaller.php +11 -0
  159. vendor/composer/installers/src/Composer/Installers/PhpBBInstaller.php +11 -0
  160. vendor/composer/installers/src/Composer/Installers/PimcoreInstaller.php +21 -0
  161. vendor/composer/installers/src/Composer/Installers/PiwikInstaller.php +32 -0
  162. vendor/composer/installers/src/Composer/Installers/PlentymarketsInstaller.php +29 -0
  163. vendor/composer/installers/src/Composer/Installers/Plugin.php +27 -0
  164. vendor/composer/installers/src/Composer/Installers/PortoInstaller.php +9 -0
  165. vendor/composer/installers/src/Composer/Installers/PrestashopInstaller.php +10 -0
  166. vendor/composer/installers/src/Composer/Installers/ProcessWireInstaller.php +22 -0
  167. vendor/composer/installers/src/Composer/Installers/PuppetInstaller.php +11 -0
  168. vendor/composer/installers/src/Composer/Installers/PxcmsInstaller.php +63 -0
  169. vendor/composer/installers/src/Composer/Installers/RadPHPInstaller.php +24 -0
  170. vendor/composer/installers/src/Composer/Installers/ReIndexInstaller.php +10 -0
  171. vendor/composer/installers/src/Composer/Installers/Redaxo5Installer.php +10 -0
  172. vendor/composer/installers/src/Composer/Installers/RedaxoInstaller.php +10 -0
  173. vendor/composer/installers/src/Composer/Installers/RoundcubeInstaller.php +22 -0
  174. vendor/composer/installers/src/Composer/Installers/SMFInstaller.php +10 -0
  175. vendor/composer/installers/src/Composer/Installers/ShopwareInstaller.php +60 -0
  176. vendor/composer/installers/src/Composer/Installers/SilverStripeInstaller.php +35 -0
  177. vendor/composer/installers/src/Composer/Installers/SiteDirectInstaller.php +25 -0
  178. vendor/composer/installers/src/Composer/Installers/StarbugInstaller.php +12 -0
  179. vendor/composer/installers/src/Composer/Installers/SyDESInstaller.php +47 -0
  180. vendor/composer/installers/src/Composer/Installers/SyliusInstaller.php +9 -0
  181. vendor/composer/installers/src/Composer/Installers/Symfony1Installer.php +26 -0
  182. vendor/composer/installers/src/Composer/Installers/TYPO3CmsInstaller.php +16 -0
  183. vendor/composer/installers/src/Composer/Installers/TYPO3FlowInstaller.php +38 -0
  184. vendor/composer/installers/src/Composer/Installers/TaoInstaller.php +30 -0
  185. vendor/composer/installers/src/Composer/Installers/TastyIgniterInstaller.php +32 -0
  186. vendor/composer/installers/src/Composer/Installers/TheliaInstaller.php +12 -0
  187. vendor/composer/installers/src/Composer/Installers/TuskInstaller.php +14 -0
  188. vendor/composer/installers/src/Composer/Installers/UserFrostingInstaller.php +9 -0
  189. vendor/composer/installers/src/Composer/Installers/VanillaInstaller.php +10 -0
  190. vendor/composer/installers/src/Composer/Installers/VgmcpInstaller.php +49 -0
  191. vendor/composer/installers/src/Composer/Installers/WHMCSInstaller.php +21 -0
  192. vendor/composer/installers/src/Composer/Installers/WinterInstaller.php +58 -0
  193. vendor/composer/installers/src/Composer/Installers/WolfCMSInstaller.php +9 -0
  194. vendor/composer/installers/src/Composer/Installers/WordPressInstaller.php +12 -0
  195. vendor/composer/installers/src/Composer/Installers/YawikInstaller.php +32 -0
  196. vendor/composer/installers/src/Composer/Installers/ZendInstaller.php +11 -0
  197. vendor/composer/installers/src/Composer/Installers/ZikulaInstaller.php +10 -0
  198. vendor/composer/installers/src/bootstrap.php +13 -0
  199. vendor/composer/platform_check.php +26 -0
  200. wplogin_redirect.php +16 -1382
  201. wplogin_redirect_control.php +8 -15
changelog.txt ADDED
@@ -0,0 +1,134 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ == Changelog ==
2
+
3
+ = 3.0.0.0 =
4
+ * Rebranded to LoginWP name
5
+ * UI revamp
6
+ * [Pro plugin](https://loginwp.com/pricing/?utm_source=wprepo&utm_medium=changelog&utm_campaign=3-release) now available
7
+
8
+ = 2.9.9 =
9
+ * Fixed bug in multisite activation support.
10
+
11
+ = 2.9.8 =
12
+ * Added multisite support.
13
+
14
+ = 2.9.7 =
15
+ * Added option to redirect to any url specified.
16
+
17
+ = 2.9.6 =
18
+ * Added back php file url base redirect.
19
+
20
+ = 2.9.5 =
21
+ * Fixed: logout redirect not working.
22
+ * Remove php file redirect option. No longer used by many or used at all.
23
+ * Plugin redirection is only manageable by manage_categories capability. Removed option to change this.
24
+
25
+ = 2.9.4 =
26
+ * Fixed: Warning: is_readable(): open_basedir restriction.
27
+
28
+ = 2.9.3 =
29
+ * Move languages po/mo files into languages folder.
30
+
31
+ = 2.9.2 =
32
+ * 2019-02-23: Add CSRF protection (thanks RIPS!). Fixed translations for "username" variable instruction (thanks Jaime!).
33
+
34
+ = 2.9.1 =
35
+ * 2016-08-10: Support utf8mb4 encoding and prevent cross-site scripting when editing redirect URLs.
36
+
37
+ = 2.9.0 =
38
+ * 2015-09-25: Update translation text domain in order to support translate.wordpress.org translation system
39
+
40
+ = 2.8.3 =
41
+ * 2015-08-03: Add new URL variable "userslug" to match author URLs.
42
+
43
+ = 2.8.2 =
44
+ * 2014-09-06: Translation string fix.
45
+
46
+ = 2.8.1 =
47
+ * 2014-08-03: Support the deletion of rules referencing deleted user, roles, or levels.
48
+
49
+ = 2.8.0 =
50
+ * 2014-07-06: Improved management interface to add specific Edit and Delete buttons per rule, and removed limit around number of rules.
51
+
52
+ = 2.7.2 =
53
+ * 2013-10-07: Support PHP 5 static function calls, bumping WordPress requirement to 3.2+.
54
+
55
+ = 2.7.1 =
56
+ * 2013-07-05: Bug fix: Role-based login URLs weren't saving correctly.
57
+
58
+ = 2.7.0 =
59
+ * 2013-07-04: Add logout redirect URL control per-user, per-role, and per-level
60
+
61
+ = 2.6.1 =
62
+ * 2012-12-22: Allow editors to manage redirects in WordPress 3.5+ (required capability is now "manage_categories" instead of "manage_links").
63
+
64
+ = 2.6.0 =
65
+ * 2012-09-22: Added support for URL variable "http_referer" (note the single "r") to redirect the user back to the page that hosted the login form, as long as the login page isn't the standard wp-login.php. There are several caveats to this, such as: If you want to redirect only on certain forms and/or specify a redirect on the standard wp-login.php page, you should modify the form itself to use a "redirect_to" form variable instead.
66
+
67
+ = 2.5.3 =
68
+ * 2012-06-15: Bug fix: Fallback redirect rule wouldn't update properly if logout URL was blank on MySQL installs with strict mode enabled (thanks kvandekrol!)
69
+
70
+ = 2.5.2 =
71
+ * 2012-02-06: Bug fix: Fallback redirect rule updates were broken for non-English installs.
72
+
73
+ = 2.5.1 =
74
+ * 2012-01-17: Bug fix: Redirect after registration back-end code was missed in 2.5.0, and thus that feature wasn't actually working.
75
+
76
+ = 2.5.0 =
77
+ * 2012-01-15: Added redirect after registration option. Also made plugin settings editable in the WordPress admin panel.
78
+
79
+ = 2.4.0 =
80
+ * 2012-01-05: Added support for URL variable "postid-23". Also added documentation on how to set up redirect on first login.
81
+
82
+ = 2.3.0 =
83
+ * 2011-11-06: Added support for URL variable "siteurl" and "homeurl". Also added filter to support custom replacement variables in the URL. See Other Notes / How to Extend for documentation.
84
+
85
+ = 2.2.0 =
86
+ * 2011-09-21: Support basic custom logout redirect URL for all users only. Future versions will have the same framework for logout redirects as for login redirects.
87
+
88
+ = 2.1.1 =
89
+ * 2011-08-13: Minor code cleanup. Note: users now need "manage_links" permissions to edit redirect settings by default.
90
+
91
+ = 2.1.0 =
92
+ * 2011-06-06: Added hooks to facilitate adding your own extensions to the plugin. See Other Notes / How to Extend for documentation.
93
+
94
+ = 2.0.0 =
95
+ * 2011-03-03: Added option to allow a redirect_to POST or GET variable to take precedence over this plugin's rules.
96
+
97
+ = 1.9.3 =
98
+ * 2010-12-15: Made plugin translatable. (Thanks Anja!)
99
+
100
+ = 1.9.2 =
101
+ * 2010-08-20: Bug fix in code syntax.
102
+
103
+ = 1.9.1 =
104
+ * 2010-08-03: Bug fix for putting the username in the redirect URL.
105
+
106
+ = 1.9.0 =
107
+ * 2010-08-02: Added support for a separate redirect controller URL for compatibility with Gigya and similar plugins that bypass the regular WordPress login redirect mechanism. See the $rul_use_redirect_controller setting within this plugin.
108
+
109
+ = 1.8.1 =
110
+ * 2010-05-13: Added proper encoding of username in the redirect URL if the username has spaces.
111
+
112
+ = 1.8.0 =
113
+ * 2010-03-18: Added the ability to specify a username in the redirect URL for more dynamic URL generation.
114
+
115
+ = 1.7.3 =
116
+ * 2010-03-04: Minor tweak on settings page for better compatibility with different WordPress URL setups.
117
+
118
+ = 1.7.2 =
119
+ * 2010-01-11: Plugin now removes its database tables when it is uninstalled, instead of when it is deactivated. This prevents the redirect rules from being deleted when upgrading WordPress automatically.
120
+
121
+ = 1.7.1 =
122
+ * 2009-10-07: Minor database compatibility tweak. (Thanks KCP!)
123
+
124
+ = 1.7.0 =
125
+ * 2009-05-31: Added option $rul_local_only (in the plugin file itself) to bypass the WordPress default limitation of only redirecting to local URLs.
126
+
127
+ = 1.6.1 =
128
+ * 2009-02-06: Minor database table tweak for better compatibility with different setups. (Thanks David!)
129
+
130
+ = 1.6.0 =
131
+ * 2008-11-26: Added a function rul_register that acts the same as the wp_register function you see in templates, except that it will return the custom defined admin address
132
+
133
+ = 1.5.1 =
134
+ * 2008-09-17: Fixed compatibility for sites with a different table prefix setting in wp-config.php. (Thanks Eric!)
languages/peters-login-redirect-cs_CZ.mo DELETED
Binary file
languages/peters-login-redirect-cs_CZ.po DELETED
@@ -1,346 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: peterloginrd\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:11-0800\n"
6
- "PO-Revision-Date: 2019-02-23 14:11-0800\n"
7
- "Last-Translator: Michal Kuk <michal.kuk@gmail.com>\n"
8
- "Language-Team: Moonpixel.com <info@moonpixel.com>\n"
9
- "Language: sk_SK\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "X-Poedit-KeywordsList: __;gettext;gettext_noop;_e\n"
14
- "X-Poedit-Basepath: .\n"
15
- "X-Generator: Poedit 2.2.1\n"
16
- "X-Poedit-SearchPath-0: .\n"
17
-
18
- #: wplogin_redirect.php:580
19
- msgid "Register"
20
- msgstr "Registrovat"
21
-
22
- #: wplogin_redirect.php:584
23
- msgid "Site Admin"
24
- msgstr "Administrátor"
25
-
26
- #: wplogin_redirect.php:706
27
- msgid "ERROR: Non-existent username submitted "
28
- msgstr "CHYBA: Zadané neplatné jméno uživatele"
29
-
30
- #: wplogin_redirect.php:716
31
- msgid "ERROR: Non-existent role submitted "
32
- msgstr "CHYBA: Zadaná neplatná role uživatele"
33
-
34
- #: wplogin_redirect.php:727
35
- msgid "ERROR: Non-existent level submitted "
36
- msgstr "CHYBA: Zadaná neexistující úroveň"
37
-
38
- #: wplogin_redirect.php:744
39
- #, fuzzy, php-format
40
- msgid "ERROR: Empty %s submitted "
41
- msgstr "CHYBA: Zadaná neplatná role uživatele"
42
-
43
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
44
- #, fuzzy, php-format
45
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
46
- msgstr "CHYBA: Zadané nelokální nebo neplatné URL uživatele"
47
-
48
- #: wplogin_redirect.php:802
49
- #, fuzzy, php-format
50
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
51
- msgstr "CHYBA: Nezjištěná chyba aktualizace URL pro daného uživatele"
52
-
53
- #: wplogin_redirect.php:809
54
- #, fuzzy, php-format
55
- msgid "Successfully added %s-specific redirect rule for %s"
56
- msgstr "URL pro daného uživatele bylo úspěšně aktualizované"
57
-
58
- #: wplogin_redirect.php:870
59
- #, fuzzy, php-format
60
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
61
- msgstr "CHYBA: Nezjištěná chyba aktualizace URL pro daného uživatele"
62
-
63
- #: wplogin_redirect.php:877
64
- #, fuzzy, php-format
65
- msgid "Successfully edited %s-specific redirect rule for %s"
66
- msgstr "URL pro daného uživatele bylo úspěšně aktualizované"
67
-
68
- #: wplogin_redirect.php:908
69
- #, fuzzy, php-format
70
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
71
- msgstr "CHYBA: Nezjištěná chyba aktualizace URL pro daného uživatele"
72
-
73
- #: wplogin_redirect.php:914
74
- #, fuzzy, php-format
75
- msgid "Successfully deleted %s-specific redirect rule for %s"
76
- msgstr "URL pro daného uživatele bylo úspěšně aktualizované"
77
-
78
- #: wplogin_redirect.php:952
79
- msgid ""
80
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
81
- msgstr ""
82
- "CHYBA: Nezjištěná chyba databáze odstranění URL pro &#34;všechny ostatní "
83
- "uživatele&#34;"
84
-
85
- #: wplogin_redirect.php:956
86
- msgid "Successfully removed URL for &#34;all other users&#34; "
87
- msgstr "Úspěšně odstraněné URL pro &#34;všechny ostatní uživatele&#34;"
88
-
89
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
90
- msgid "ERROR: Non-local or invalid URL submitted "
91
- msgstr "CHYBA: Zadané nelokální nebo neplatné URL"
92
-
93
- #: wplogin_redirect.php:980
94
- msgid ""
95
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
96
- msgstr ""
97
- "CHYBA: Nezjištěná chyba databáze aktualizace URL pro &#34;všechny ostatní "
98
- "uživatele&#34;"
99
-
100
- #: wplogin_redirect.php:984
101
- msgid "Successfully updated URL for &#34;all other users&#34;"
102
- msgstr "Úspěšně aktualizované URL pro &#34;všechny ostatní uživatele&#34;"
103
-
104
- #: wplogin_redirect.php:1026
105
- msgid ""
106
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
107
- msgstr ""
108
- "CHYBA: Nezjištěná chyba databáze odstranění URL pro &#34;Registrační "
109
- "příspěvek&#34;"
110
-
111
- #: wplogin_redirect.php:1029
112
- msgid "Successfully removed URL for &#34;post-registration&#34; "
113
- msgstr "Úspěšně odstraněné URL pro &#34;registrační příspěvek&#34;"
114
-
115
- #: wplogin_redirect.php:1052
116
- msgid ""
117
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
118
- msgstr ""
119
- "CHYBA: Nezjištěná chyba databáze aktualizace URL pro &#34;registrační "
120
- "příspěvek&#34;"
121
-
122
- #: wplogin_redirect.php:1056
123
- msgid "Successfully updated URL for &#34;post-registration&#34;"
124
- msgstr "Úspěšně aktualizované URL pro &#34;registrační příspěvek&#34;"
125
-
126
- #: wplogin_redirect.php:1085
127
- msgid "Successfully updated plugin settings"
128
- msgstr "Nastavená pluginu bylo úspěšně aktualizováno"
129
-
130
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
131
- #: wplogin_redirect.php:1275
132
- #, fuzzy
133
- msgid "Login URL"
134
- msgstr "URL odhlášení"
135
-
136
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
137
- #: wplogin_redirect.php:1276
138
- msgid "Logout URL"
139
- msgstr "URL odhlášení"
140
-
141
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
142
- #: wplogin_redirect.php:1280
143
- msgid "Edit"
144
- msgstr ""
145
-
146
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
147
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
148
- #: wplogin_redirect.php:1411
149
- msgid "Delete"
150
- msgstr "Odstranit"
151
-
152
- #: wplogin_redirect.php:1305
153
- msgid "Manage redirect rules"
154
- msgstr "Správa pravidel pro přesměrování"
155
-
156
- #: wplogin_redirect.php:1307
157
- msgid ""
158
- "Define custom URLs to which different users, users with specific roles, "
159
- "users with specific levels, and all other users will be redirected upon "
160
- "login."
161
- msgstr ""
162
- "Definovat různé URL, na kterou budou různí uživatelé, uživatelé s "
163
- "konkrétními rolemi, uživatelé s konkrétními úrovněmi a všichni ostatní "
164
- "uživatelé přesměrováni."
165
-
166
- #: wplogin_redirect.php:1308
167
- msgid "Define a custom URL to which all users will be redirected upon logout"
168
- msgstr ""
169
- "Definujte vlastní URL na kterou budou přesměrování všichni uživatele po "
170
- "odhlášení"
171
-
172
- #: wplogin_redirect.php:1309
173
- msgid ""
174
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
175
- "strong> in your URLs so that the system will build a dynamic URL upon each "
176
- "login, replacing that text with the users username."
177
- msgstr ""
178
- "Poznámka: je možné používat syntaxi <strong>[variable]username[/variable]</"
179
- "strong> v URL. Systém vytvoří dynamické URL po každém přihlášení, "
180
- "nahrazujíce tento text uživatelským jménem."
181
-
182
- #: wplogin_redirect.php:1311
183
- msgid "Specific users"
184
- msgstr "Konkrétní uživatelé"
185
-
186
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
187
- #: wplogin_redirect.php:1380
188
- msgid "Add:"
189
- msgstr "Přidat:"
190
-
191
- #: wplogin_redirect.php:1324
192
- msgid "Select a username"
193
- msgstr "Vybrat uživatelské jméno"
194
-
195
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
196
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
197
- #: wplogin_redirect.php:1409
198
- msgid "URL:"
199
- msgstr "URL:"
200
-
201
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
202
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
203
- msgid "Logout URL:"
204
- msgstr "URL odhlášení:"
205
-
206
- #: wplogin_redirect.php:1331
207
- msgid "Add username rule"
208
- msgstr ""
209
-
210
- #: wplogin_redirect.php:1336
211
- msgid "Specific roles"
212
- msgstr "Konkrétní role"
213
-
214
- #: wplogin_redirect.php:1349
215
- msgid "Select a role"
216
- msgstr "Vybrat roli"
217
-
218
- #: wplogin_redirect.php:1356
219
- msgid "Add role rule"
220
- msgstr ""
221
-
222
- #: wplogin_redirect.php:1361
223
- msgid "Specific levels"
224
- msgstr "Konkrétní úrovně"
225
-
226
- #: wplogin_redirect.php:1370
227
- msgid "Order"
228
- msgstr "Příkaz"
229
-
230
- #: wplogin_redirect.php:1382
231
- msgid "Select a level"
232
- msgstr "Vybrat úroveň"
233
-
234
- #: wplogin_redirect.php:1385
235
- msgid "Order:"
236
- msgstr "Příkaz:"
237
-
238
- #: wplogin_redirect.php:1390
239
- msgid "Add level rule"
240
- msgstr ""
241
-
242
- #: wplogin_redirect.php:1395
243
- msgid "All other users"
244
- msgstr "Všichni ostatní uživatelé"
245
-
246
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
247
- #: wplogin_redirect.php:1491
248
- msgid "Update"
249
- msgstr "Aktualizovat"
250
-
251
- #: wplogin_redirect.php:1407
252
- msgid "Post-registration"
253
- msgstr "Registrační příspěvek"
254
-
255
- #: wplogin_redirect.php:1418
256
- msgid "Customize plugin settings"
257
- msgstr "Vlastní nastavení pluginu"
258
-
259
- #: wplogin_redirect.php:1423
260
- msgid "Redirect restrictions"
261
- msgstr "Omezení přesměrování"
262
-
263
- #: wplogin_redirect.php:1427
264
- msgid "Any http or https URL"
265
- msgstr "Libovolné http nebo https URL"
266
-
267
- #: wplogin_redirect.php:1428
268
- msgid "Any URL"
269
- msgstr "Libovolná URL"
270
-
271
- #: wplogin_redirect.php:1429
272
- msgid "Any URL on the same domain"
273
- msgstr "Libovolné URL na stejné doméně"
274
-
275
- #: wplogin_redirect.php:1435
276
- msgid ""
277
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
278
- "precedence"
279
- msgstr ""
280
- "Povolit POST nebo GET &#34;redirect_to&#34; promněnou pro přednostní "
281
- "přesměrování"
282
-
283
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
284
- #: wplogin_redirect.php:1462
285
- msgid "Yes"
286
- msgstr "Ano"
287
-
288
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
289
- #: wplogin_redirect.php:1463
290
- msgid "No"
291
- msgstr "Ne"
292
-
293
- #: wplogin_redirect.php:1446
294
- msgid ""
295
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
296
- "precedence"
297
- msgstr ""
298
- "Povolit POST nebo GET &#34;redirect_to&#34; ohlašovací promněnou pro "
299
- "přednostní přesměrování"
300
-
301
- #: wplogin_redirect.php:1458
302
- #, fuzzy, php-format
303
- msgid ""
304
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
305
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
306
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
307
- "other plugin to %s"
308
- msgstr ""
309
- "Použít externí přesměrovací soubor. Nastevto na &#34;Ano&#34; pokud "
310
- "používáte pluginy jako Gigya, který přepisuje běžný přesměrovací proce "
311
- "WordPressu (a umožňuje pouze jednu fixní přesměrovací URL). Poté nastavetu "
312
- "toto URL na %s"
313
-
314
- #: wplogin_redirect.php:1469
315
- msgid "Permission level required to edit redirect URLs"
316
- msgstr "Úroveň oprávnění potřebná pro úpravu přesměrovacích URL."
317
-
318
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
319
- #~ msgstr "CHYBA: Zadané nelokální nebo neplatné URL pro danou roli"
320
-
321
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
322
- #~ msgstr "CHYBA: Nezjištěná chyba aktualizace URL pro danou roli"
323
-
324
- #~ msgid "Successfully updated role-specific URLs"
325
- #~ msgstr "URL pro danou roli bylo úspěšně aktualizováno"
326
-
327
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
328
- #~ msgstr "CHYBA: Zadané nelokální nebo neplatné URL pro danou úroveň"
329
-
330
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
331
- #~ msgstr "CHYBA: Nezjištěná chyba aktualizace URL pro danou úroveň"
332
-
333
- #~ msgid "Successfully updated level-specific URLs"
334
- #~ msgstr "URL pro dané úrovně úspěšně aktualizováno"
335
-
336
- #~ msgid "Username"
337
- #~ msgstr "Uživatelské jméno"
338
-
339
- #~ msgid "URL"
340
- #~ msgstr "URL"
341
-
342
- #~ msgid "Role"
343
- #~ msgstr "Role"
344
-
345
- #~ msgid "Level"
346
- #~ msgstr "Úroveň"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-da_DK.mo DELETED
Binary file
languages/peters-login-redirect-da_DK.po DELETED
@@ -1,351 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peter's Login Redirect\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:11-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Peter <peter@keung.biz>\n"
8
- "Language-Team: theblog.ca\n"
9
- "Language: da_DK\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Generator: Poedit 2.2.1\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
-
21
- #: wplogin_redirect.php:580
22
- msgid "Register"
23
- msgstr "Registere"
24
-
25
- #: wplogin_redirect.php:584
26
- msgid "Site Admin"
27
- msgstr "Side administrator"
28
-
29
- #: wplogin_redirect.php:706
30
- msgid "ERROR: Non-existent username submitted "
31
- msgstr "FEJL: Ikke eksisterne bruger navn indsendt"
32
-
33
- #: wplogin_redirect.php:716
34
- msgid "ERROR: Non-existent role submitted "
35
- msgstr "FEJL: Ikke eksisterne rolle indsendt"
36
-
37
- #: wplogin_redirect.php:727
38
- msgid "ERROR: Non-existent level submitted "
39
- msgstr "FEJL: Ikke eksisterne niveau indsendt"
40
-
41
- #: wplogin_redirect.php:744
42
- #, fuzzy, php-format
43
- msgid "ERROR: Empty %s submitted "
44
- msgstr "FEJL: Ikke eksisterne rolle indsendt"
45
-
46
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
47
- #, fuzzy, php-format
48
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
49
- msgstr "FEJL: Ikke lokal eller ugyldig URL indsendt for bruger"
50
-
51
- #: wplogin_redirect.php:802
52
- #, fuzzy, php-format
53
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
54
- msgstr "FEJL: Ukendt fejl under opdatering af bruger specifik URL for bruger"
55
-
56
- #: wplogin_redirect.php:809
57
- #, fuzzy, php-format
58
- msgid "Successfully added %s-specific redirect rule for %s"
59
- msgstr "Bruger specifikke URL's opdateret succesfuldt"
60
-
61
- #: wplogin_redirect.php:870
62
- #, fuzzy, php-format
63
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
64
- msgstr "FEJL: Ukendt fejl under opdatering af bruger specifik URL for bruger"
65
-
66
- #: wplogin_redirect.php:877
67
- #, fuzzy, php-format
68
- msgid "Successfully edited %s-specific redirect rule for %s"
69
- msgstr "Bruger specifikke URL's opdateret succesfuldt"
70
-
71
- #: wplogin_redirect.php:908
72
- #, fuzzy, php-format
73
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
74
- msgstr "FEJL: Ukendt fejl under opdatering af bruger specifik URL for bruger"
75
-
76
- #: wplogin_redirect.php:914
77
- #, fuzzy, php-format
78
- msgid "Successfully deleted %s-specific redirect rule for %s"
79
- msgstr "Bruger specifikke URL's opdateret succesfuldt"
80
-
81
- #: wplogin_redirect.php:952
82
- msgid ""
83
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
84
- msgstr ""
85
- "FEJL: Ukendt database problem under fjernelse af URL for &#34;Alle andre "
86
- "bruger&#34;"
87
-
88
- #: wplogin_redirect.php:956
89
- msgid "Successfully removed URL for &#34;all other users&#34; "
90
- msgstr "URL for &#34;Alle andre bruger&#34; fjernet succesfuldt"
91
-
92
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
93
- msgid "ERROR: Non-local or invalid URL submitted "
94
- msgstr "FEJL: Ikke lokal eller ugyldig URL indsendt"
95
-
96
- #: wplogin_redirect.php:980
97
- msgid ""
98
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
99
- msgstr ""
100
- "FEJL: Ukendt databse problem under opdatering af URL for &#34;Alle andre "
101
- "bruger&#34;"
102
-
103
- #: wplogin_redirect.php:984
104
- msgid "Successfully updated URL for &#34;all other users&#34;"
105
- msgstr "URL"
106
-
107
- #: wplogin_redirect.php:1026
108
- msgid ""
109
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
110
- msgstr ""
111
- "FEJL: Ukendt database problem under fjernelse af URL for &#34;Indlæg "
112
- "registering&#34;"
113
-
114
- #: wplogin_redirect.php:1029
115
- msgid "Successfully removed URL for &#34;post-registration&#34; "
116
- msgstr "URL for &#34;Indlæg registering&#34; fjernet succesfuldt"
117
-
118
- #: wplogin_redirect.php:1052
119
- msgid ""
120
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
121
- msgstr ""
122
- "FEJL: Ukendt database problem under opdatering af URL for &#34;Indlæg "
123
- "registering&#34;"
124
-
125
- #: wplogin_redirect.php:1056
126
- msgid "Successfully updated URL for &#34;post-registration&#34;"
127
- msgstr "URL for &#34;Indlæg registering&#34; opdateret succesfuldt"
128
-
129
- #: wplogin_redirect.php:1085
130
- msgid "Successfully updated plugin settings"
131
- msgstr "Plugin indstillinger opdateret succesfuldt"
132
-
133
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
134
- #: wplogin_redirect.php:1275
135
- #, fuzzy
136
- msgid "Login URL"
137
- msgstr "Log ud URL:"
138
-
139
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
140
- #: wplogin_redirect.php:1276
141
- #, fuzzy
142
- msgid "Logout URL"
143
- msgstr "Log ud URL:"
144
-
145
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
146
- #: wplogin_redirect.php:1280
147
- msgid "Edit"
148
- msgstr ""
149
-
150
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
151
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
152
- #: wplogin_redirect.php:1411
153
- msgid "Delete"
154
- msgstr "Slet"
155
-
156
- #: wplogin_redirect.php:1305
157
- msgid "Manage redirect rules"
158
- msgstr "Administrer omdirigerings regler"
159
-
160
- #: wplogin_redirect.php:1307
161
- msgid ""
162
- "Define custom URLs to which different users, users with specific roles, "
163
- "users with specific levels, and all other users will be redirected upon "
164
- "login."
165
- msgstr ""
166
- "Definere URL's til hvilken forskellige bruger, brugere med specifikke "
167
- "roller, bruger med et specifikt niveau og alle andre bruger vil blive "
168
- "omdirigeret til når de logger ind."
169
-
170
- #: wplogin_redirect.php:1308
171
- msgid "Define a custom URL to which all users will be redirected upon logout"
172
- msgstr ""
173
- "Definere en URL til hvilken alle bruger vil blive omdirigeret til når de "
174
- "logger ud"
175
-
176
- #: wplogin_redirect.php:1309
177
- msgid ""
178
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
179
- "strong> in your URLs so that the system will build a dynamic URL upon each "
180
- "login, replacing that text with the users username."
181
- msgstr ""
182
- "Info: Du kan bruge syntaxen <strong>[variable]username[/variable]</strong> i "
183
- "dine URL's så vil systemet lave en dynamisk URL ved hvert log ind, hvor "
184
- "teksten erstattes af brugerens brugernavn."
185
-
186
- #: wplogin_redirect.php:1311
187
- msgid "Specific users"
188
- msgstr "Specifikke brugere"
189
-
190
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
191
- #: wplogin_redirect.php:1380
192
- msgid "Add:"
193
- msgstr "Tilføj:"
194
-
195
- #: wplogin_redirect.php:1324
196
- msgid "Select a username"
197
- msgstr "Vælg et bruger navn"
198
-
199
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
200
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
201
- #: wplogin_redirect.php:1409
202
- msgid "URL:"
203
- msgstr "URL:"
204
-
205
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
206
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
207
- msgid "Logout URL:"
208
- msgstr "Log ud URL:"
209
-
210
- #: wplogin_redirect.php:1331
211
- msgid "Add username rule"
212
- msgstr ""
213
-
214
- #: wplogin_redirect.php:1336
215
- msgid "Specific roles"
216
- msgstr "Specifikke roller"
217
-
218
- #: wplogin_redirect.php:1349
219
- msgid "Select a role"
220
- msgstr "Vælg en rolle"
221
-
222
- #: wplogin_redirect.php:1356
223
- msgid "Add role rule"
224
- msgstr ""
225
-
226
- #: wplogin_redirect.php:1361
227
- msgid "Specific levels"
228
- msgstr "Specifikke niveauer"
229
-
230
- #: wplogin_redirect.php:1370
231
- msgid "Order"
232
- msgstr "Rækkefølge"
233
-
234
- #: wplogin_redirect.php:1382
235
- msgid "Select a level"
236
- msgstr "Vælg et niveau"
237
-
238
- #: wplogin_redirect.php:1385
239
- msgid "Order:"
240
- msgstr "Rækkefølge:"
241
-
242
- #: wplogin_redirect.php:1390
243
- msgid "Add level rule"
244
- msgstr ""
245
-
246
- #: wplogin_redirect.php:1395
247
- msgid "All other users"
248
- msgstr "Alle andre bruger"
249
-
250
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
251
- #: wplogin_redirect.php:1491
252
- msgid "Update"
253
- msgstr "Opdatere"
254
-
255
- #: wplogin_redirect.php:1407
256
- msgid "Post-registration"
257
- msgstr "Indlæg registering"
258
-
259
- #: wplogin_redirect.php:1418
260
- msgid "Customize plugin settings"
261
- msgstr "Tilpas plugin indstillinger"
262
-
263
- #: wplogin_redirect.php:1423
264
- msgid "Redirect restrictions"
265
- msgstr "Omdirigere restriktioner"
266
-
267
- #: wplogin_redirect.php:1427
268
- msgid "Any http or https URL"
269
- msgstr "Enhver http eller https URL"
270
-
271
- #: wplogin_redirect.php:1428
272
- msgid "Any URL"
273
- msgstr "Enhver URL"
274
-
275
- #: wplogin_redirect.php:1429
276
- msgid "Any URL on the same domain"
277
- msgstr "Enhver URL på det samme domæne"
278
-
279
- #: wplogin_redirect.php:1435
280
- msgid ""
281
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
282
- "precedence"
283
- msgstr ""
284
- "Tillad et indlæg eller GET &#34;redirect_to&#34; variabel at tage "
285
- "omdirigerings præcedens"
286
-
287
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
288
- #: wplogin_redirect.php:1462
289
- msgid "Yes"
290
- msgstr "Ja"
291
-
292
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
293
- #: wplogin_redirect.php:1463
294
- msgid "No"
295
- msgstr "Nej"
296
-
297
- #: wplogin_redirect.php:1446
298
- msgid ""
299
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
300
- "precedence"
301
- msgstr ""
302
- "Tillad et indlæg eller GET &#34;redirect_to&#34; log ud variabel at tage "
303
- "omdirigerings præcedens"
304
-
305
- #: wplogin_redirect.php:1458
306
- #, fuzzy, php-format
307
- msgid ""
308
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
309
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
310
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
311
- "other plugin to %s"
312
- msgstr ""
313
- "Brug ekstern omdirigerings fil. Indstil denne til &#34;Ja&#34; hvis du "
314
- "bruger et plugin så som Gigya, der overskriver den almindelige WordPress "
315
- "omdirigerings process (og tillad kun en fast omdirigerings URL). Så indstil "
316
- "omdirigerings URL til %s"
317
-
318
- #: wplogin_redirect.php:1469
319
- msgid "Permission level required to edit redirect URLs"
320
- msgstr "Tilladelse niveau, der kræves for at ændre omdirigerings URL's"
321
-
322
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
323
- #~ msgstr "FEJL: Ikke lokal eller ugyldig URL indsendt for rolle"
324
-
325
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
326
- #~ msgstr "FEJL: Ukendt fejl under opdatering af rolle specifik URL for rolle"
327
-
328
- #~ msgid "Successfully updated role-specific URLs"
329
- #~ msgstr "Rolle specifikke URL's opdateret succesfuldt"
330
-
331
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
332
- #~ msgstr "FEJL: Ikke lokal eller ikke gyldig URL indsendt for niveau"
333
-
334
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
335
- #~ msgstr ""
336
- #~ "FEJL: Ukendt fejl under opdatering af niveau specifik URL for niveau"
337
-
338
- #~ msgid "Successfully updated level-specific URLs"
339
- #~ msgstr "Neveau specifikke URL's opdateret succesfuldt"
340
-
341
- #~ msgid "Username"
342
- #~ msgstr "Bruger navn"
343
-
344
- #~ msgid "URL"
345
- #~ msgstr "URL"
346
-
347
- #~ msgid "Role"
348
- #~ msgstr "Rolle"
349
-
350
- #~ msgid "Level"
351
- #~ msgstr "Niveau"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-de_DE.mo DELETED
Binary file
languages/peters-login-redirect-de_DE.po DELETED
@@ -1,346 +0,0 @@
1
- # Translation of Development (trunk) in German
2
- # This file is distributed under the same license as the Development (trunk) package.
3
- msgid ""
4
- msgstr ""
5
- "Project-Id-Version: Peter's Login Redirect\n"
6
- "POT-Creation-Date: 2019-02-23 14:10-0800\n"
7
- "PO-Revision-Date: 2019-02-23 14:10-0800\n"
8
- "Last-Translator: \n"
9
- "Language-Team: theblog.ca\n"
10
- "Language: de_DE\n"
11
- "MIME-Version: 1.0\n"
12
- "Content-Type: text/plain; charset=UTF-8\n"
13
- "Content-Transfer-Encoding: 8bit\n"
14
- "Plural-Forms: nplurals=2; plural=n != 1;\n"
15
- "X-Generator: Poedit 2.2.1\n"
16
- "X-Poedit-KeywordsList: __;_e\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Poedit-SearchPath-0: .\n"
19
-
20
- #: wplogin_redirect.php:580
21
- msgid "Register"
22
- msgstr "Registrieren"
23
-
24
- #: wplogin_redirect.php:584
25
- msgid "Site Admin"
26
- msgstr "Website-Administrator"
27
-
28
- #: wplogin_redirect.php:706
29
- msgid "ERROR: Non-existent username submitted "
30
- msgstr "FEHLER: Eingegebener Benutzername existiert nicht"
31
-
32
- #: wplogin_redirect.php:716
33
- msgid "ERROR: Non-existent role submitted "
34
- msgstr "FEHLER: Eingegebene Rolle existiert nicht"
35
-
36
- #: wplogin_redirect.php:727
37
- msgid "ERROR: Non-existent level submitted "
38
- msgstr "FEHLER: Eingegebene Ebene existiert nicht"
39
-
40
- #: wplogin_redirect.php:744
41
- #, php-format
42
- msgid "ERROR: Empty %s submitted "
43
- msgstr "FEHLER: Leere %s eingegeben"
44
-
45
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
46
- #, php-format
47
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
48
- msgstr "FEHLER: Nicht-lokale oder ungültige URL für %s %s eingegeben"
49
-
50
- #: wplogin_redirect.php:802
51
- #, php-format
52
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
53
- msgstr ""
54
- "FEHLER: Unbekannter Fehler beim Aktualisieren der %s-spezifischen Umleitung "
55
- "für %s %s"
56
-
57
- #: wplogin_redirect.php:809
58
- #, php-format
59
- msgid "Successfully added %s-specific redirect rule for %s"
60
- msgstr ""
61
- "Die %s-spezifische Umleitungs-Regel für %s wurde erfolgreich hinzugefügt"
62
-
63
- #: wplogin_redirect.php:870
64
- #, php-format
65
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
66
- msgstr ""
67
- "FEHLER: Unbekannter Fehler beim Ändern der %s-spezifischen Umleitung für %s "
68
- "%s"
69
-
70
- #: wplogin_redirect.php:877
71
- #, php-format
72
- msgid "Successfully edited %s-specific redirect rule for %s"
73
- msgstr "Die %s-spezifische Umleitungs-Regel für %s wurde erfolgreich geändert"
74
-
75
- #: wplogin_redirect.php:908
76
- #, php-format
77
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
78
- msgstr ""
79
- "FEHLER: Unbekannter Fehler beim Löschen der %s-spezifischen Umleitung für %s "
80
- "%s"
81
-
82
- #: wplogin_redirect.php:914
83
- #, php-format
84
- msgid "Successfully deleted %s-specific redirect rule for %s"
85
- msgstr "Die %s-spezifische Umleitungs-Regel für %s wurde erfolgreich gelöscht"
86
-
87
- #: wplogin_redirect.php:952
88
- msgid ""
89
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
90
- msgstr ""
91
- "FEHLER: Unbekanntes Datenbank-Problem beim Löschen der URL für „alle anderen "
92
- "Benutzer“"
93
-
94
- #: wplogin_redirect.php:956
95
- msgid "Successfully removed URL for &#34;all other users&#34; "
96
- msgstr "URL für „alle anderen Benutzer“ erfolgreich gelöscht"
97
-
98
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
99
- msgid "ERROR: Non-local or invalid URL submitted "
100
- msgstr "FEHLER: Nicht-lokale oder ungültige URL eingegeben"
101
-
102
- #: wplogin_redirect.php:980
103
- msgid ""
104
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
105
- msgstr ""
106
- "FEHLER: Unbekanntes Datenbank-Problem beim Aktualisieren der URL für „alle "
107
- "anderen Benutzer“"
108
-
109
- #: wplogin_redirect.php:984
110
- msgid "Successfully updated URL for &#34;all other users&#34;"
111
- msgstr "URL für „alle anderen Benutzer“ erfolgreich aktualisiert"
112
-
113
- #: wplogin_redirect.php:1026
114
- msgid ""
115
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
116
- msgstr ""
117
- "FEHLER: Unbekanntes Datenbank-Problem beim Löschen der URL für „Nach-"
118
- "Registrierung“"
119
-
120
- #: wplogin_redirect.php:1029
121
- msgid "Successfully removed URL for &#34;post-registration&#34; "
122
- msgstr "URL für „Nach-Registrierung“ erfolgreich gelöscht"
123
-
124
- #: wplogin_redirect.php:1052
125
- msgid ""
126
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
127
- msgstr ""
128
- "FEHLER: Unbekanntes Datenbank-Problem beim Aktualisieren der URL für „Nach-"
129
- "Registrierung“"
130
-
131
- #: wplogin_redirect.php:1056
132
- msgid "Successfully updated URL for &#34;post-registration&#34;"
133
- msgstr "Die URL für „Nach-Registrierung“ wurde erfolgreich aktualisiert"
134
-
135
- #: wplogin_redirect.php:1085
136
- msgid "Successfully updated plugin settings"
137
- msgstr "Die Plugin-Einstellungen wurden erfolgreich aktualisiert"
138
-
139
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
140
- #: wplogin_redirect.php:1275
141
- msgid "Login URL"
142
- msgstr "Anmelden-URL"
143
-
144
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
145
- #: wplogin_redirect.php:1276
146
- msgid "Logout URL"
147
- msgstr "Abmelden-URL"
148
-
149
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
150
- #: wplogin_redirect.php:1280
151
- msgid "Edit"
152
- msgstr "Ändern"
153
-
154
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
155
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
156
- #: wplogin_redirect.php:1411
157
- msgid "Delete"
158
- msgstr "Löschen"
159
-
160
- #: wplogin_redirect.php:1305
161
- msgid "Manage redirect rules"
162
- msgstr "Umleitungs-Regeln verwalten"
163
-
164
- #: wplogin_redirect.php:1307
165
- msgid ""
166
- "Define custom URLs to which different users, users with specific roles, "
167
- "users with specific levels, and all other users will be redirected upon "
168
- "login."
169
- msgstr ""
170
- "Definiere individuelle URLs, zu denen verschiedene Benutzer, Benutzer mit "
171
- "spezifischen Rollen, Benutzer mit spezifischen Ebenen und alle anderen "
172
- "Benutzer umgeleitet werden."
173
-
174
- #: wplogin_redirect.php:1308
175
- msgid "Define a custom URL to which all users will be redirected upon logout"
176
- msgstr ""
177
- "Definiere eine individuelle URL, auf die alle Benutzer nach der Abmeldung "
178
- "umgeleitet werden."
179
-
180
- #: wplogin_redirect.php:1309
181
- msgid ""
182
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
183
- "strong> in your URLs so that the system will build a dynamic URL upon each "
184
- "login, replacing that text with the users username."
185
- msgstr ""
186
- "Hinweis: Du kannst die Syntax <strong>[variable]username[/variable]</strong> "
187
- "in deinen URLs verwenden, so dass das System eine dynamische URL bei jeder "
188
- "Anmeldung erstellt, wobei dieser Text mit dem Benutzernamen des Benutzers "
189
- "ersetzt wird."
190
-
191
- #: wplogin_redirect.php:1311
192
- msgid "Specific users"
193
- msgstr "Spezifische Benutzer"
194
-
195
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
196
- #: wplogin_redirect.php:1380
197
- msgid "Add:"
198
- msgstr "Hinzufügen:"
199
-
200
- #: wplogin_redirect.php:1324
201
- msgid "Select a username"
202
- msgstr "Wähle einen Benutzernamen"
203
-
204
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
205
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
206
- #: wplogin_redirect.php:1409
207
- msgid "URL:"
208
- msgstr "URL:"
209
-
210
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
211
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
212
- msgid "Logout URL:"
213
- msgstr "Abmelden-URL:"
214
-
215
- #: wplogin_redirect.php:1331
216
- msgid "Add username rule"
217
- msgstr "Füge eine Rolle für den Benutzer hinzu"
218
-
219
- #: wplogin_redirect.php:1336
220
- msgid "Specific roles"
221
- msgstr "Spezifische Rollen"
222
-
223
- #: wplogin_redirect.php:1349
224
- msgid "Select a role"
225
- msgstr "Wähle eine Rolle"
226
-
227
- #: wplogin_redirect.php:1356
228
- msgid "Add role rule"
229
- msgstr "Füge eine Regel für die Rolle hinzu"
230
-
231
- #: wplogin_redirect.php:1361
232
- msgid "Specific levels"
233
- msgstr "Spezifische Ebenen"
234
-
235
- #: wplogin_redirect.php:1370
236
- msgid "Order"
237
- msgstr "Reihenfolge"
238
-
239
- #: wplogin_redirect.php:1382
240
- msgid "Select a level"
241
- msgstr "Wähle eine Ebene"
242
-
243
- #: wplogin_redirect.php:1385
244
- msgid "Order:"
245
- msgstr "Reihenfolge:"
246
-
247
- #: wplogin_redirect.php:1390
248
- msgid "Add level rule"
249
- msgstr "Füge eine Ebenen-Regel hinzu"
250
-
251
- #: wplogin_redirect.php:1395
252
- msgid "All other users"
253
- msgstr "Alle anderen Benutzer"
254
-
255
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
256
- #: wplogin_redirect.php:1491
257
- msgid "Update"
258
- msgstr "Aktualisieren"
259
-
260
- #: wplogin_redirect.php:1407
261
- msgid "Post-registration"
262
- msgstr "Nach-Registrierung"
263
-
264
- #: wplogin_redirect.php:1418
265
- msgid "Customize plugin settings"
266
- msgstr "Individuelle Plugin-Einstellungen"
267
-
268
- #: wplogin_redirect.php:1423
269
- msgid "Redirect restrictions"
270
- msgstr "Umleitungs-Einschränkungen"
271
-
272
- #: wplogin_redirect.php:1427
273
- msgid "Any http or https URL"
274
- msgstr "Jede HTTP- oder HTTPS-URL"
275
-
276
- #: wplogin_redirect.php:1428
277
- msgid "Any URL"
278
- msgstr "Jede URL"
279
-
280
- #: wplogin_redirect.php:1429
281
- msgid "Any URL on the same domain"
282
- msgstr "Jede URL in derselben Domain"
283
-
284
- #: wplogin_redirect.php:1435
285
- msgid ""
286
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
287
- "precedence"
288
- msgstr ""
289
- "Erlaube eine POST oder GET „redirect_to“-Variable für die Umleitungs-"
290
- "Reihenfolge"
291
-
292
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
293
- #: wplogin_redirect.php:1462
294
- msgid "Yes"
295
- msgstr "Ja"
296
-
297
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
298
- #: wplogin_redirect.php:1463
299
- msgid "No"
300
- msgstr "Nein"
301
-
302
- #: wplogin_redirect.php:1446
303
- msgid ""
304
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
305
- "precedence"
306
- msgstr ""
307
- "Erlaube eine POST oder GET „redirect_to“-Abmelde-Variable für die Umleitungs-"
308
- "Reihenfolge"
309
-
310
- #: wplogin_redirect.php:1458
311
- #, php-format
312
- msgid ""
313
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
314
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
315
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
316
- "other plugin to %s"
317
- msgstr ""
318
- "Benutze eine externe Umleitungs-Datei. Setze diese auf „Ja“, wenn du ein "
319
- "Plugin wie Gigya benutzt, das den regulären WordPress-Umleitungs-Prozess "
320
- "umgeht (und nur eine feste Umleitungs-URL erlaubt). In diesem Fall setze die "
321
- "Umleitungs-URL im anderen Plugin auf %s."
322
-
323
- #: wplogin_redirect.php:1469
324
- msgid "Permission level required to edit redirect URLs"
325
- msgstr "Für das Ändern der Umleitungs-URLs sind Zugriffsrechte erforderlich."
326
-
327
- #~ msgid "Peter's Login Redirect"
328
- #~ msgstr "Peter's Login Redirect"
329
-
330
- #~ msgid "http://www.theblog.ca/wplogin-redirect"
331
- #~ msgstr "http://www.theblog.ca/wplogin-redirect"
332
-
333
- #~ msgid ""
334
- #~ "Redirect users to different locations after logging in. Define a set of "
335
- #~ "rules for specific users, user with specific roles, users with specific "
336
- #~ "capabilities, and a blanket rule for all other users. This is all managed "
337
- #~ "in Settings > Login/logout redirects."
338
- #~ msgstr ""
339
- #~ "Leitet Benutzer nach dem Anmelden zu unterschiedlichen Stellen um. "
340
- #~ "Definiere einen Satz von Regeln für spezifische Benutzer, Benutzer mit "
341
- #~ "spezifischen Rollen, Benutzer mit speziellen Ebenen und einer Pauschal-"
342
- #~ "Regel für alle anderen Benutzer. Das wird alles in „Einstellungen > Login/"
343
- #~ "logout redirects“ verwaltet."
344
-
345
- #~ msgid "Peter Keung"
346
- #~ msgstr "Peter Keung"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-es_ES.mo DELETED
Binary file
languages/peters-login-redirect-es_ES.po DELETED
@@ -1,354 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peter's Login Redirect\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:10-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Peter <peter@keung.biz>\n"
8
- "Language-Team: theblog.ca\n"
9
- "Language: es_ES\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Generator: Poedit 2.2.1\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
-
21
- #: wplogin_redirect.php:580
22
- msgid "Register"
23
- msgstr "Registro"
24
-
25
- #: wplogin_redirect.php:584
26
- msgid "Site Admin"
27
- msgstr "Web Administración"
28
-
29
- #: wplogin_redirect.php:706
30
- msgid "ERROR: Non-existent username submitted "
31
- msgstr "ERROR: Usuario no existente enviado"
32
-
33
- #: wplogin_redirect.php:716
34
- msgid "ERROR: Non-existent role submitted "
35
- msgstr "ERROR: Rol no existente enviado"
36
-
37
- #: wplogin_redirect.php:727
38
- msgid "ERROR: Non-existent level submitted "
39
- msgstr "ERROR: Nivel no existente enviado"
40
-
41
- #: wplogin_redirect.php:744
42
- #, fuzzy, php-format
43
- msgid "ERROR: Empty %s submitted "
44
- msgstr "ERROR: Rol no existente enviado"
45
-
46
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
47
- #, fuzzy, php-format
48
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
49
- msgstr "ERROR: URL no local o inválida enviada por el usuario"
50
-
51
- #: wplogin_redirect.php:802
52
- #, fuzzy, php-format
53
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
54
- msgstr "ERROR: Error desconocido actualizando la URL para usuario específca"
55
-
56
- #: wplogin_redirect.php:809
57
- #, fuzzy, php-format
58
- msgid "Successfully added %s-specific redirect rule for %s"
59
- msgstr "Actualizado satisfactoriamente los usuarios específicos por URL"
60
-
61
- #: wplogin_redirect.php:870
62
- #, fuzzy, php-format
63
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
64
- msgstr "ERROR: Error desconocido actualizando la URL para usuario específca"
65
-
66
- #: wplogin_redirect.php:877
67
- #, fuzzy, php-format
68
- msgid "Successfully edited %s-specific redirect rule for %s"
69
- msgstr "Actualizado satisfactoriamente los usuarios específicos por URL"
70
-
71
- #: wplogin_redirect.php:908
72
- #, fuzzy, php-format
73
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
74
- msgstr "ERROR: Error desconocido actualizando la URL para usuario específca"
75
-
76
- #: wplogin_redirect.php:914
77
- #, fuzzy, php-format
78
- msgid "Successfully deleted %s-specific redirect rule for %s"
79
- msgstr "Actualizado satisfactoriamente los usuarios específicos por URL"
80
-
81
- #: wplogin_redirect.php:952
82
- msgid ""
83
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
84
- msgstr ""
85
- "ERROR: Problema en la base de datos borrando URL para &#34;todos los "
86
- "usuarios&#34; "
87
-
88
- #: wplogin_redirect.php:956
89
- msgid "Successfully removed URL for &#34;all other users&#34; "
90
- msgstr ""
91
- "Borradaa URL satisfactoriamente para &#34;todos los demás usuarios&#34;"
92
-
93
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
94
- msgid "ERROR: Non-local or invalid URL submitted "
95
- msgstr "ERROR: URL no local o inválida enviada"
96
-
97
- #: wplogin_redirect.php:980
98
- msgid ""
99
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
100
- msgstr ""
101
- "ERROR: Problema en la base de datos actualizando URL para &#34;todos los "
102
- "usuarios&#34; "
103
-
104
- #: wplogin_redirect.php:984
105
- msgid "Successfully updated URL for &#34;all other users&#34;"
106
- msgstr ""
107
- "Actualizada URL satisfactoriamente para &#34;todos los demás usuarios&#34;"
108
-
109
- #: wplogin_redirect.php:1026
110
- #, fuzzy
111
- msgid ""
112
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
113
- msgstr ""
114
- "ERROR: Problema en la base de datos borrando URL para &#34;todos los "
115
- "usuarios&#34; "
116
-
117
- #: wplogin_redirect.php:1029
118
- #, fuzzy
119
- msgid "Successfully removed URL for &#34;post-registration&#34; "
120
- msgstr ""
121
- "Borradaa URL satisfactoriamente para &#34;todos los demás usuarios&#34;"
122
-
123
- #: wplogin_redirect.php:1052
124
- #, fuzzy
125
- msgid ""
126
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
127
- msgstr ""
128
- "ERROR: Problema en la base de datos actualizando URL para &#34;todos los "
129
- "usuarios&#34; "
130
-
131
- #: wplogin_redirect.php:1056
132
- #, fuzzy
133
- msgid "Successfully updated URL for &#34;post-registration&#34;"
134
- msgstr ""
135
- "Actualizada URL satisfactoriamente para &#34;todos los demás usuarios&#34;"
136
-
137
- #: wplogin_redirect.php:1085
138
- #, fuzzy
139
- msgid "Successfully updated plugin settings"
140
- msgstr "Actualizado satisfactoriamente los usuarios específicos por URL"
141
-
142
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
143
- #: wplogin_redirect.php:1275
144
- #, fuzzy
145
- msgid "Login URL"
146
- msgstr "Logout URL:"
147
-
148
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
149
- #: wplogin_redirect.php:1276
150
- #, fuzzy
151
- msgid "Logout URL"
152
- msgstr "Logout URL:"
153
-
154
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
155
- #: wplogin_redirect.php:1280
156
- msgid "Edit"
157
- msgstr ""
158
-
159
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
160
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
161
- #: wplogin_redirect.php:1411
162
- msgid "Delete"
163
- msgstr "Borrar"
164
-
165
- #: wplogin_redirect.php:1305
166
- msgid "Manage redirect rules"
167
- msgstr "Gestionar reglas redireccionamiento"
168
-
169
- #: wplogin_redirect.php:1307
170
- msgid ""
171
- "Define custom URLs to which different users, users with specific roles, "
172
- "users with specific levels, and all other users will be redirected upon "
173
- "login."
174
- msgstr ""
175
- "Define URL personalizadas para diferentes usuarios, usuarios con roles "
176
- "específicos, usuarios con niveles específicos, y otros usuarios que serán "
177
- "redirigidos sobre el login."
178
-
179
- #: wplogin_redirect.php:1308
180
- msgid "Define a custom URL to which all users will be redirected upon logout"
181
- msgstr ""
182
- "Defiene una URL personalizada para todos aquellos usuarios que al salir de "
183
- "la cuenta se redirijan."
184
-
185
- #: wplogin_redirect.php:1309
186
- msgid ""
187
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
188
- "strong> in your URLs so that the system will build a dynamic URL upon each "
189
- "login, replacing that text with the users username."
190
- msgstr ""
191
- "Ten en cuenta que usando la sintaxis <strong>[variable]username[/variable]</"
192
- "strong> en la url, el sistema creará una URL dináimca sobre cada registro, "
193
- "reemplazando ese texto en el nombre de usuario."
194
-
195
- #: wplogin_redirect.php:1311
196
- msgid "Specific users"
197
- msgstr "Usuarios específicos"
198
-
199
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
200
- #: wplogin_redirect.php:1380
201
- msgid "Add:"
202
- msgstr "Añadir:"
203
-
204
- #: wplogin_redirect.php:1324
205
- msgid "Select a username"
206
- msgstr "Seleccionar usuario"
207
-
208
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
209
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
210
- #: wplogin_redirect.php:1409
211
- msgid "URL:"
212
- msgstr "URL:"
213
-
214
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
215
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
216
- msgid "Logout URL:"
217
- msgstr "Logout URL:"
218
-
219
- #: wplogin_redirect.php:1331
220
- msgid "Add username rule"
221
- msgstr ""
222
-
223
- #: wplogin_redirect.php:1336
224
- msgid "Specific roles"
225
- msgstr "Rol Específico"
226
-
227
- #: wplogin_redirect.php:1349
228
- msgid "Select a role"
229
- msgstr "Seleccionar rol"
230
-
231
- #: wplogin_redirect.php:1356
232
- msgid "Add role rule"
233
- msgstr ""
234
-
235
- #: wplogin_redirect.php:1361
236
- msgid "Specific levels"
237
- msgstr "Nivel Específico"
238
-
239
- #: wplogin_redirect.php:1370
240
- msgid "Order"
241
- msgstr "Orden"
242
-
243
- #: wplogin_redirect.php:1382
244
- msgid "Select a level"
245
- msgstr "Seleccionar Nivel"
246
-
247
- #: wplogin_redirect.php:1385
248
- msgid "Order:"
249
- msgstr "Orden:"
250
-
251
- #: wplogin_redirect.php:1390
252
- msgid "Add level rule"
253
- msgstr ""
254
-
255
- #: wplogin_redirect.php:1395
256
- msgid "All other users"
257
- msgstr "Resto de usuarios"
258
-
259
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
260
- #: wplogin_redirect.php:1491
261
- msgid "Update"
262
- msgstr "Actualizar"
263
-
264
- #: wplogin_redirect.php:1407
265
- msgid "Post-registration"
266
- msgstr ""
267
-
268
- #: wplogin_redirect.php:1418
269
- msgid "Customize plugin settings"
270
- msgstr ""
271
-
272
- #: wplogin_redirect.php:1423
273
- msgid "Redirect restrictions"
274
- msgstr ""
275
-
276
- #: wplogin_redirect.php:1427
277
- msgid "Any http or https URL"
278
- msgstr ""
279
-
280
- #: wplogin_redirect.php:1428
281
- #, fuzzy
282
- msgid "Any URL"
283
- msgstr "URL"
284
-
285
- #: wplogin_redirect.php:1429
286
- msgid "Any URL on the same domain"
287
- msgstr ""
288
-
289
- #: wplogin_redirect.php:1435
290
- msgid ""
291
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
292
- "precedence"
293
- msgstr ""
294
-
295
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
296
- #: wplogin_redirect.php:1462
297
- msgid "Yes"
298
- msgstr ""
299
-
300
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
301
- #: wplogin_redirect.php:1463
302
- msgid "No"
303
- msgstr ""
304
-
305
- #: wplogin_redirect.php:1446
306
- msgid ""
307
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
308
- "precedence"
309
- msgstr ""
310
-
311
- #: wplogin_redirect.php:1458
312
- #, php-format
313
- msgid ""
314
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
315
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
316
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
317
- "other plugin to %s"
318
- msgstr ""
319
-
320
- #: wplogin_redirect.php:1469
321
- msgid "Permission level required to edit redirect URLs"
322
- msgstr ""
323
-
324
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
325
- #~ msgstr "ERROR: URL no local o inválida enviada para el rol"
326
-
327
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
328
- #~ msgstr "ERROR: Error desconocido actualizando la URL para el rol específco"
329
-
330
- #~ msgid "Successfully updated role-specific URLs"
331
- #~ msgstr "Actualizado satisfactoriamente los roles específicos por URL"
332
-
333
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
334
- #~ msgstr ""
335
- #~ "ERROR: Error desconocido actualizando la URL para el nivel específco"
336
-
337
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
338
- #~ msgstr ""
339
- #~ "ERROR: Error desconocido actualizando la URL para el nivel específco"
340
-
341
- #~ msgid "Successfully updated level-specific URLs"
342
- #~ msgstr "Actualizado satisfactoriamente los niveles específicos por URL"
343
-
344
- #~ msgid "Username"
345
- #~ msgstr "Usuario"
346
-
347
- #~ msgid "URL"
348
- #~ msgstr "URL"
349
-
350
- #~ msgid "Role"
351
- #~ msgstr "Rol"
352
-
353
- #~ msgid "Level"
354
- #~ msgstr "Nivel"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-fr_FR.mo DELETED
Binary file
languages/peters-login-redirect-fr_FR.po DELETED
@@ -1,360 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peter's Login Redirect v2.8.2\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:10-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: DomBonj <dombonj@gmail.com>\n"
8
- "Language-Team: DomBonj <http://www.addfi.fr>\n"
9
- "Language: fr_FR\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n > 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Generator: Poedit 2.2.1\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
-
21
- #: wplogin_redirect.php:580
22
- msgid "Register"
23
- msgstr "S'inscrire"
24
-
25
- #: wplogin_redirect.php:584
26
- msgid "Site Admin"
27
- msgstr "Administrateur du site"
28
-
29
- #: wplogin_redirect.php:706
30
- msgid "ERROR: Non-existent username submitted "
31
- msgstr "ERREUR : identifiant inexistant"
32
-
33
- #: wplogin_redirect.php:716
34
- msgid "ERROR: Non-existent role submitted "
35
- msgstr "ERREUR : rôle inexistant"
36
-
37
- #: wplogin_redirect.php:727
38
- msgid "ERROR: Non-existent level submitted "
39
- msgstr "ERREUR : permission inexistante"
40
-
41
- #: wplogin_redirect.php:744
42
- #, php-format
43
- msgid "ERROR: Empty %s submitted "
44
- msgstr "ERREUR : %s vide fourni(e)"
45
-
46
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
47
- #, php-format
48
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
49
- msgstr "ERREUR : URL non locale ou invalide fournie pour %s %s"
50
-
51
- #: wplogin_redirect.php:802
52
- #, php-format
53
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
54
- msgstr ""
55
- "ERREUR : erreur inconnue en ajoutant une redirection spécifique à %s pour %s "
56
- "%s"
57
-
58
- #: wplogin_redirect.php:809
59
- #, php-format
60
- msgid "Successfully added %s-specific redirect rule for %s"
61
- msgstr "La règle de redirection spécifique à %s pour %s a été ajoutée"
62
-
63
- #: wplogin_redirect.php:870
64
- #, php-format
65
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
66
- msgstr ""
67
- "ERREUR : erreur inconnue en éditant la redirection spécifique à %s pour %s %s"
68
-
69
- #: wplogin_redirect.php:877
70
- #, php-format
71
- msgid "Successfully edited %s-specific redirect rule for %s"
72
- msgstr "La règle de redirection spécifique à %s pour %s a été éditée"
73
-
74
- #: wplogin_redirect.php:908
75
- #, php-format
76
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
77
- msgstr ""
78
- "ERREUR : erreur inconnue en tentant de supprimer la redirection spécifique à "
79
- "%s pour %s %s"
80
-
81
- #: wplogin_redirect.php:914
82
- #, php-format
83
- msgid "Successfully deleted %s-specific redirect rule for %s"
84
- msgstr "La règle de redirection spécifique à %s pour %s a été supprimée"
85
-
86
- #: wplogin_redirect.php:952
87
- msgid ""
88
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
89
- msgstr ""
90
- "ERREUR : problème de base de données en tentant de supprimer l'URL pour &#34;"
91
- "tous les autres utilisateurs&#34; "
92
-
93
- #: wplogin_redirect.php:956
94
- msgid "Successfully removed URL for &#34;all other users&#34; "
95
- msgstr "L'URL pour &#34;tous les autres utilisateurs&#34; a été supprimée"
96
-
97
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
98
- msgid "ERROR: Non-local or invalid URL submitted "
99
- msgstr "ERREUR : URL non locale ou invalide fournie"
100
-
101
- #: wplogin_redirect.php:980
102
- msgid ""
103
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
104
- msgstr ""
105
- "ERREUR : problème de base de données en tentant de mettre à jour l'URL pour "
106
- "&#34;tous les autres utilisateurs&#34; "
107
-
108
- #: wplogin_redirect.php:984
109
- msgid "Successfully updated URL for &#34;all other users&#34;"
110
- msgstr "L'URL pour &#34;tous les autres utilisateurs&#34; a été mise à jour"
111
-
112
- #: wplogin_redirect.php:1026
113
- msgid ""
114
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
115
- msgstr ""
116
- "ERREUR : problème de base de données en tentant de supprimer l'URL d'&#34;"
117
- "après-inscription&#34; "
118
-
119
- #: wplogin_redirect.php:1029
120
- msgid "Successfully removed URL for &#34;post-registration&#34; "
121
- msgstr "L'URL d'&#34;après-inscription&#34; a été supprimée"
122
-
123
- #: wplogin_redirect.php:1052
124
- msgid ""
125
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
126
- msgstr ""
127
- "ERREUR : problème de base de données en tentant de mettre à jour l'URL "
128
- "d'&#34;après-inscription&#34; "
129
-
130
- #: wplogin_redirect.php:1056
131
- msgid "Successfully updated URL for &#34;post-registration&#34;"
132
- msgstr "L'URL d'&#34;après-inscription&#34; a été mise à jour"
133
-
134
- #: wplogin_redirect.php:1085
135
- msgid "Successfully updated plugin settings"
136
- msgstr "Les réglages de l'extension ont été mis à jour"
137
-
138
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
139
- #: wplogin_redirect.php:1275
140
- msgid "Login URL"
141
- msgstr "URL de connexion"
142
-
143
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
144
- #: wplogin_redirect.php:1276
145
- msgid "Logout URL"
146
- msgstr "URL à la déconnexion"
147
-
148
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
149
- #: wplogin_redirect.php:1280
150
- msgid "Edit"
151
- msgstr "Editer"
152
-
153
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
154
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
155
- #: wplogin_redirect.php:1411
156
- msgid "Delete"
157
- msgstr "Supprimer"
158
-
159
- #: wplogin_redirect.php:1305
160
- msgid "Manage redirect rules"
161
- msgstr "Gestion des règles de redirection d'URL"
162
-
163
- #: wplogin_redirect.php:1307
164
- msgid ""
165
- "Define custom URLs to which different users, users with specific roles, "
166
- "users with specific levels, and all other users will be redirected upon "
167
- "login."
168
- msgstr ""
169
- "Définissez des URL personnalisées vers lesquelles les différents "
170
- "utilisateurs, les utilisateurs ayant des rôles spécifiés, les utilisateurs "
171
- "avec des permissions spécifiées, et tous les autres utilisateurs seront "
172
- "redirigés après s'être connectés."
173
-
174
- #: wplogin_redirect.php:1308
175
- msgid "Define a custom URL to which all users will be redirected upon logout"
176
- msgstr ""
177
- "Définissez une URL personnalisée vers laquelle tous les utilisateurs seront "
178
- "redirigés à la déconnexion."
179
-
180
- #: wplogin_redirect.php:1309
181
- msgid ""
182
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
183
- "strong> in your URLs so that the system will build a dynamic URL upon each "
184
- "login, replacing that text with the users username."
185
- msgstr ""
186
- "Notez que vous pouvez utiliser la syntaxe <strong>[variable]username[/"
187
- "variable]</strong> dans vos URL pour que le système produise au vol une URL "
188
- "à chaque connexion, en remplaçant ce texte par l'identifiant de "
189
- "l'utilisateur."
190
-
191
- #: wplogin_redirect.php:1311
192
- msgid "Specific users"
193
- msgstr "Utilisateurs spécifiés"
194
-
195
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
196
- #: wplogin_redirect.php:1380
197
- msgid "Add:"
198
- msgstr "Ajouter :"
199
-
200
- #: wplogin_redirect.php:1324
201
- msgid "Select a username"
202
- msgstr "choisissez un identifiant"
203
-
204
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
205
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
206
- #: wplogin_redirect.php:1409
207
- msgid "URL:"
208
- msgstr "URL :"
209
-
210
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
211
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
212
- msgid "Logout URL:"
213
- msgstr "URL à la déconnexion :"
214
-
215
- #: wplogin_redirect.php:1331
216
- msgid "Add username rule"
217
- msgstr "Ajouter une règle sur utilisateur"
218
-
219
- #: wplogin_redirect.php:1336
220
- msgid "Specific roles"
221
- msgstr "Rôles spécifiés"
222
-
223
- #: wplogin_redirect.php:1349
224
- msgid "Select a role"
225
- msgstr "choisissez un rôle"
226
-
227
- #: wplogin_redirect.php:1356
228
- msgid "Add role rule"
229
- msgstr "Ajouter une règle sur rôle"
230
-
231
- #: wplogin_redirect.php:1361
232
- msgid "Specific levels"
233
- msgstr "Permissions spécifiées"
234
-
235
- #: wplogin_redirect.php:1370
236
- msgid "Order"
237
- msgstr "Ordre"
238
-
239
- #: wplogin_redirect.php:1382
240
- msgid "Select a level"
241
- msgstr "choisissez une permission"
242
-
243
- #: wplogin_redirect.php:1385
244
- msgid "Order:"
245
- msgstr "Ordre :"
246
-
247
- #: wplogin_redirect.php:1390
248
- msgid "Add level rule"
249
- msgstr "Ajouter une règle sur permission"
250
-
251
- #: wplogin_redirect.php:1395
252
- msgid "All other users"
253
- msgstr "Tous les autres utilisateurs"
254
-
255
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
256
- #: wplogin_redirect.php:1491
257
- msgid "Update"
258
- msgstr "Mettre à jour"
259
-
260
- #: wplogin_redirect.php:1407
261
- msgid "Post-registration"
262
- msgstr "Après l'inscription"
263
-
264
- #: wplogin_redirect.php:1418
265
- msgid "Customize plugin settings"
266
- msgstr "Personnalisez les réglages de l'extension"
267
-
268
- #: wplogin_redirect.php:1423
269
- msgid "Redirect restrictions"
270
- msgstr "Restrictions sur les URL de redirection"
271
-
272
- #: wplogin_redirect.php:1427
273
- msgid "Any http or https URL"
274
- msgstr "Toute URL http ou https"
275
-
276
- #: wplogin_redirect.php:1428
277
- msgid "Any URL"
278
- msgstr "Toute URL"
279
-
280
- #: wplogin_redirect.php:1429
281
- msgid "Any URL on the same domain"
282
- msgstr "Toute URL du même domaine"
283
-
284
- #: wplogin_redirect.php:1435
285
- msgid ""
286
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
287
- "precedence"
288
- msgstr ""
289
- "Permettre à une variable &#34;redirect_to&#34; dans le POST ou le GET &#34;"
290
- "redirect_to&#34; d'imposer la redirection"
291
-
292
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
293
- #: wplogin_redirect.php:1462
294
- msgid "Yes"
295
- msgstr "Oui"
296
-
297
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
298
- #: wplogin_redirect.php:1463
299
- msgid "No"
300
- msgstr "Non"
301
-
302
- #: wplogin_redirect.php:1446
303
- msgid ""
304
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
305
- "precedence"
306
- msgstr ""
307
- "Permettre à une variable de déconnexion &#34;redirect_to&#34; dans le POST "
308
- "ou le GET &#34;redirect_to&#34; d'imposer la redirection"
309
-
310
- #: wplogin_redirect.php:1458
311
- #, php-format
312
- msgid ""
313
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
314
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
315
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
316
- "other plugin to %s"
317
- msgstr ""
318
- "Utiliser un fichier de redirection externe. Choisissez &#34;Oui&#34; si vous "
319
- "utilisez une extension comme Gigya qui court-circuite la procédure de "
320
- "redirection standard de WordPress (et ne permet qu'une seule URL de "
321
- "redirection). Ensuite, saisissez %s comme URL de redirection dans l'autre "
322
- "extension."
323
-
324
- #: wplogin_redirect.php:1469
325
- msgid "Permission level required to edit redirect URLs"
326
- msgstr "Permission nécessaire pour modifier les URL de redirection "
327
-
328
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
329
- #~ msgstr "ERREUR : URL non locale ou invalide fournie pour ce rôle"
330
-
331
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
332
- #~ msgstr ""
333
- #~ "ERREUR : erreur inconnue en tentant de mettre à jour l'URL spécifiée pour "
334
- #~ "ce rôle"
335
-
336
- #~ msgid "Successfully updated role-specific URLs"
337
- #~ msgstr "Les URL spécifiées pour ce rôle ont été mises à jour"
338
-
339
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
340
- #~ msgstr "ERREUR : URL non locale ou invalide fournie pour cette permission"
341
-
342
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
343
- #~ msgstr ""
344
- #~ "ERREUR : erreur inconnue en tentant de mettre à jour l'URL spécifiée pour "
345
- #~ "cette permission"
346
-
347
- #~ msgid "Successfully updated level-specific URLs"
348
- #~ msgstr "Les URL spécifiées pour cette permission ont été mise à jour"
349
-
350
- #~ msgid "Username"
351
- #~ msgstr "Identifiant"
352
-
353
- #~ msgid "URL"
354
- #~ msgstr "URL de redirection"
355
-
356
- #~ msgid "Role"
357
- #~ msgstr "Rôle"
358
-
359
- #~ msgid "Level"
360
- #~ msgstr "Permission"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-id_ID.mo DELETED
Binary file
languages/peters-login-redirect-id_ID.po DELETED
@@ -1,378 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peter's Login Redirect v2.6.1\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2016-08-10 21:12-0800\n"
6
- "PO-Revision-Date: 2016-08-10 21:12-0800\n"
7
- "Last-Translator: Syamsul Alam <admin@alampintar.org>\n"
8
- "Language-Team: \n"
9
- "Language: id_ID\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=n != 1;\n"
14
- "X-Poedit-SourceCharset: utf-8\n"
15
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
16
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n"
17
- "X-Textdomain-Support: yes\n"
18
- "X-Generator: Poedit 1.5.4\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
-
21
- # @ peterloginrd
22
- #: wplogin_redirect.php:579
23
- msgid "Register"
24
- msgstr "Daftar"
25
-
26
- # @ peterloginrd
27
- #: wplogin_redirect.php:583
28
- msgid "Site Admin"
29
- msgstr "Site Admin"
30
-
31
- # @ peterloginrd
32
- #: wplogin_redirect.php:705
33
- msgid "ERROR: Non-existent username submitted "
34
- msgstr "ERROR: Tidak ada nama pengguna untuk diproses "
35
-
36
- # @ peterloginrd
37
- #: wplogin_redirect.php:715
38
- msgid "ERROR: Non-existent role submitted "
39
- msgstr "ERROR: peran yang tidak ada terproses "
40
-
41
- # @ peterloginrd
42
- #: wplogin_redirect.php:726
43
- msgid "ERROR: Non-existent level submitted "
44
- msgstr "ERROR: tingkatan yang tidak ada terproses "
45
-
46
- # @ peterloginrd
47
- #: wplogin_redirect.php:743
48
- #, fuzzy, php-format
49
- msgid "ERROR: Empty %s submitted "
50
- msgstr "ERROR: peran yang tidak ada terproses "
51
-
52
- # @ peterloginrd
53
- #: wplogin_redirect.php:772 wplogin_redirect.php:834
54
- #, fuzzy, php-format
55
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
56
- msgstr "ERROR: Non-lokal atau proses URL salah oleh pemakai "
57
-
58
- # @ peterloginrd
59
- #: wplogin_redirect.php:798
60
- #, fuzzy, php-format
61
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
62
- msgstr ""
63
- "ERROR: error tidak diketahui memperbarui pengguna-URL tertentu oleh pengguna "
64
-
65
- # @ peterloginrd
66
- #: wplogin_redirect.php:805
67
- #, fuzzy, php-format
68
- msgid "Successfully added %s-specific redirect rule for %s"
69
- msgstr "berhasil update URL tertentu pemakai "
70
-
71
- # @ peterloginrd
72
- #: wplogin_redirect.php:863
73
- #, fuzzy, php-format
74
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
75
- msgstr ""
76
- "ERROR: error tidak diketahui memperbarui pengguna-URL tertentu oleh pengguna "
77
-
78
- # @ peterloginrd
79
- #: wplogin_redirect.php:870
80
- #, fuzzy, php-format
81
- msgid "Successfully edited %s-specific redirect rule for %s"
82
- msgstr "berhasil update URL tertentu pemakai "
83
-
84
- # @ peterloginrd
85
- #: wplogin_redirect.php:898
86
- #, fuzzy, php-format
87
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
88
- msgstr ""
89
- "ERROR: error tidak diketahui memperbarui pengguna-URL tertentu oleh pengguna "
90
-
91
- # @ peterloginrd
92
- #: wplogin_redirect.php:904
93
- #, fuzzy, php-format
94
- msgid "Successfully deleted %s-specific redirect rule for %s"
95
- msgstr "berhasil update URL tertentu pemakai "
96
-
97
- # @ peterloginrd
98
- #: wplogin_redirect.php:939
99
- msgid ""
100
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
101
- msgstr ""
102
- "ERROR: Masalah database tidak diketahui untuk menghapus URL untuk &#34;all "
103
- "other users&#34; "
104
-
105
- # @ peterloginrd
106
- #: wplogin_redirect.php:943
107
- msgid "Successfully removed URL for &#34;all other users&#34; "
108
- msgstr "Berhasil menghapus URL untuk &#34;all other users&#34; "
109
-
110
- # @ peterloginrd
111
- #: wplogin_redirect.php:954 wplogin_redirect.php:1023
112
- msgid "ERROR: Non-local or invalid URL submitted "
113
- msgstr "ERROR: Non-lokal atau URL yang salah terproses "
114
-
115
- # @ peterloginrd
116
- #: wplogin_redirect.php:967
117
- msgid ""
118
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
119
- msgstr ""
120
- "ERROR: Masalah database tidak diketahui update URL untuk &#34;all other "
121
- "users&#34; "
122
-
123
- # @ peterloginrd
124
- #: wplogin_redirect.php:971
125
- msgid "Successfully updated URL for &#34;all other users&#34;"
126
- msgstr "Berhasil update URL untuk &#34;all other users&#34; "
127
-
128
- # @ peterloginrd
129
- #: wplogin_redirect.php:1010
130
- msgid ""
131
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
132
- msgstr ""
133
- "ERROR: masalah database tidak diketahui menghapus URL untuk &#34;post-"
134
- "registration&#34; "
135
-
136
- # @ peterloginrd
137
- #: wplogin_redirect.php:1013
138
- msgid "Successfully removed URL for &#34;post-registration&#34; "
139
- msgstr "Berhasil menghapus URL untuk &#34;post-registration&#34; "
140
-
141
- # @ peterloginrd
142
- #: wplogin_redirect.php:1036
143
- msgid ""
144
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
145
- msgstr ""
146
- "ERROR: Masalah database tidak diketahui memperbarui URL untuk &#34;post-"
147
- "registration&#34; "
148
-
149
- # @ peterloginrd
150
- #: wplogin_redirect.php:1040
151
- msgid "Successfully updated URL for &#34;post-registration&#34;"
152
- msgstr "Berhasil memperbarui URL untuk &#34;post-registration&#34;"
153
-
154
- # @ peterloginrd
155
- #: wplogin_redirect.php:1066
156
- msgid "Successfully updated plugin settings"
157
- msgstr "Berhasil memperbarui pengaturan plugin"
158
-
159
- # @ peterloginrd
160
- #: wplogin_redirect.php:1215 wplogin_redirect.php:1233
161
- #: wplogin_redirect.php:1250
162
- #, fuzzy
163
- msgid "Login URL"
164
- msgstr "Keluar URL:"
165
-
166
- # @ peterloginrd
167
- #: wplogin_redirect.php:1216 wplogin_redirect.php:1234
168
- #: wplogin_redirect.php:1251
169
- #, fuzzy
170
- msgid "Logout URL"
171
- msgstr "Keluar URL:"
172
-
173
- #: wplogin_redirect.php:1218 wplogin_redirect.php:1236
174
- #: wplogin_redirect.php:1254
175
- msgid "Edit"
176
- msgstr ""
177
-
178
- # @ peterloginrd
179
- #: wplogin_redirect.php:1218 wplogin_redirect.php:1236
180
- #: wplogin_redirect.php:1254 wplogin_redirect.php:1362
181
- #: wplogin_redirect.php:1370
182
- msgid "Delete"
183
- msgstr "Hapus"
184
-
185
- # @ peterloginrd
186
- #: wplogin_redirect.php:1277
187
- msgid "Manage redirect rules"
188
- msgstr "Atur aturan pengalihan"
189
-
190
- # @ peterloginrd
191
- #: wplogin_redirect.php:1279
192
- msgid ""
193
- "Define custom URLs to which different users, users with specific roles, "
194
- "users with specific levels, and all other users will be redirected upon "
195
- "login."
196
- msgstr ""
197
- "Tetapkan aturan URL untuk pengguna lain, pengguna dengan peran tertentu, "
198
- "pengguna dengan tingkat tertentu, dan pengguna lain akan diarahkan ketika "
199
- "masuk."
200
-
201
- # @ peterloginrd
202
- #: wplogin_redirect.php:1280
203
- msgid "Define a custom URL to which all users will be redirected upon logout"
204
- msgstr ""
205
- "Tentukan sebuah URL kustom dimana semua pengguna akan diarahkan ketika "
206
- "keluar."
207
-
208
- # @ peterloginrd
209
- #: wplogin_redirect.php:1281
210
- msgid ""
211
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
212
- "strong> in your URLs so that the system will build a dynamic URL upon each "
213
- "login, replacing that text with the users username."
214
- msgstr ""
215
- "Untuk catatan bahwa anda menggunakan syntax <strong>[variable]username[/"
216
- "variable]</strong> di URL anda sehingga system akan mebuat URL dinamis "
217
- "setiap masuk, mengganti kata dengan nama pengguna"
218
-
219
- # @ peterloginrd
220
- #: wplogin_redirect.php:1283
221
- msgid "Specific users"
222
- msgstr "Pengguna tertentu"
223
-
224
- # @ peterloginrd
225
- #: wplogin_redirect.php:1294 wplogin_redirect.php:1316
226
- #: wplogin_redirect.php:1346
227
- msgid "Add:"
228
- msgstr "Tambahkan:"
229
-
230
- # @ peterloginrd
231
- #: wplogin_redirect.php:1296
232
- msgid "Select a username"
233
- msgstr "Pilih nama pengguna"
234
-
235
- # @ peterloginrd
236
- #: wplogin_redirect.php:1299 wplogin_redirect.php:1321
237
- #: wplogin_redirect.php:1352 wplogin_redirect.php:1360
238
- #: wplogin_redirect.php:1369
239
- msgid "URL:"
240
- msgstr "URL:"
241
-
242
- # @ peterloginrd
243
- #: wplogin_redirect.php:1300 wplogin_redirect.php:1322
244
- #: wplogin_redirect.php:1353 wplogin_redirect.php:1361
245
- msgid "Logout URL:"
246
- msgstr "Keluar URL:"
247
-
248
- #: wplogin_redirect.php:1302
249
- msgid "Add username rule"
250
- msgstr ""
251
-
252
- # @ peterloginrd
253
- #: wplogin_redirect.php:1305
254
- msgid "Specific roles"
255
- msgstr "Peran tertentu"
256
-
257
- # @ peterloginrd
258
- #: wplogin_redirect.php:1318
259
- msgid "Select a role"
260
- msgstr "Pilih sebuah peran"
261
-
262
- #: wplogin_redirect.php:1324
263
- msgid "Add role rule"
264
- msgstr ""
265
-
266
- # @ peterloginrd
267
- #: wplogin_redirect.php:1327
268
- msgid "Specific levels"
269
- msgstr "Tingkat tertentu"
270
-
271
- # @ peterloginrd
272
- #: wplogin_redirect.php:1336
273
- msgid "Order"
274
- msgstr "Urutan"
275
-
276
- # @ peterloginrd
277
- #: wplogin_redirect.php:1348
278
- msgid "Select a level"
279
- msgstr "Pilih sebuah tingkat"
280
-
281
- # @ peterloginrd
282
- #: wplogin_redirect.php:1351
283
- msgid "Order:"
284
- msgstr "urutan:"
285
-
286
- #: wplogin_redirect.php:1355
287
- msgid "Add level rule"
288
- msgstr ""
289
-
290
- # @ peterloginrd
291
- #: wplogin_redirect.php:1358
292
- msgid "All other users"
293
- msgstr "Seluruh pengguna lain"
294
-
295
- # @ peterloginrd
296
- #: wplogin_redirect.php:1362 wplogin_redirect.php:1370
297
- #: wplogin_redirect.php:1447
298
- msgid "Update"
299
- msgstr "Perbarui"
300
-
301
- # @ peterloginrd
302
- #: wplogin_redirect.php:1367
303
- msgid "Post-registration"
304
- msgstr "Pasca-pendaftaran"
305
-
306
- # @ peterloginrd
307
- #: wplogin_redirect.php:1375
308
- msgid "Customize plugin settings"
309
- msgstr "Kustom aturan plugin"
310
-
311
- # @ peterloginrd
312
- #: wplogin_redirect.php:1380
313
- msgid "Redirect restrictions"
314
- msgstr "Batasan pengalihan"
315
-
316
- # @ peterloginrd
317
- #: wplogin_redirect.php:1384
318
- msgid "Any http or https URL"
319
- msgstr "Setiap http atau https URL"
320
-
321
- # @ peterloginrd
322
- #: wplogin_redirect.php:1385
323
- msgid "Any URL"
324
- msgstr "Setiap URL"
325
-
326
- # @ peterloginrd
327
- #: wplogin_redirect.php:1386
328
- msgid "Any URL on the same domain"
329
- msgstr "Setiap URL di domain yang sama"
330
-
331
- # @ peterloginrd
332
- #: wplogin_redirect.php:1392
333
- msgid ""
334
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
335
- "precedence"
336
- msgstr ""
337
- "Biarkan POST atau GET &#34;redirect_to&#34; variabel untuk mengutamakan "
338
- "pengambilan pengalihan "
339
-
340
- # @ peterloginrd
341
- #: wplogin_redirect.php:1396 wplogin_redirect.php:1407
342
- #: wplogin_redirect.php:1419
343
- msgid "Yes"
344
- msgstr "Ya"
345
-
346
- # @ peterloginrd
347
- #: wplogin_redirect.php:1397 wplogin_redirect.php:1408
348
- #: wplogin_redirect.php:1420
349
- msgid "No"
350
- msgstr "Tidak"
351
-
352
- # @ peterloginrd
353
- #: wplogin_redirect.php:1403
354
- msgid ""
355
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
356
- "precedence"
357
- msgstr ""
358
- "Biarkan POST atau GET &#34;redirect_to&#34; variabel keluar untuk "
359
- "mengutamakan pengalihan"
360
-
361
- # @ peterloginrd
362
- #: wplogin_redirect.php:1415
363
- #, fuzzy, php-format
364
- msgid ""
365
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
366
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
367
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
368
- "other plugin to %s"
369
- msgstr ""
370
- "Gunakan pengalihan file luar. Set ini ke &#34;Yes&#34; jika Anda menggunakan "
371
- "plugin seperti Gigya yang melewati proses pengalihan WordPress reguler (dan "
372
- "hanya memungkinkan untuk satu pengalihan URL tetap). Kemudian, atur URL "
373
- "pengalihan ke % s"
374
-
375
- # @ peterloginrd
376
- #: wplogin_redirect.php:1426
377
- msgid "Permission level required to edit redirect URLs"
378
- msgstr "Izin tingkatan dibutuhkan untuk mengedit pengalihan URL"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-lt_LT.mo DELETED
Binary file
languages/peters-login-redirect-lt_LT.po DELETED
@@ -1,363 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: peters login redirect v2.0\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:10-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Peter <peter@keung.biz>\n"
8
- "Language-Team: \n"
9
- "Language: de_DE\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Generator: Poedit 2.2.1\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
-
21
- #: wplogin_redirect.php:580
22
- msgid "Register"
23
- msgstr "Registruotis"
24
-
25
- #: wplogin_redirect.php:584
26
- msgid "Site Admin"
27
- msgstr "Svetainės Administratorius"
28
-
29
- #: wplogin_redirect.php:706
30
- msgid "ERROR: Non-existent username submitted "
31
- msgstr "KLAIDA: Pateiktas neegzistuojantis vartotojo vardas"
32
-
33
- #: wplogin_redirect.php:716
34
- msgid "ERROR: Non-existent role submitted "
35
- msgstr "KLAIDA: Pateikta neegzistuojanti funkcija"
36
-
37
- #: wplogin_redirect.php:727
38
- msgid "ERROR: Non-existent level submitted "
39
- msgstr "KLAIDA: Pateiktas neegzistuojantis lygmuo"
40
-
41
- #: wplogin_redirect.php:744
42
- #, fuzzy, php-format
43
- msgid "ERROR: Empty %s submitted "
44
- msgstr "KLAIDA: Pateikta neegzistuojanti funkcija"
45
-
46
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
47
- #, fuzzy, php-format
48
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
49
- msgstr ""
50
- "KLAIDA: Vartotojui priskirta nevietinė arba neteisinga Universalioji nuoroda"
51
-
52
- #: wplogin_redirect.php:802
53
- #, fuzzy, php-format
54
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
55
- msgstr ""
56
- "KLAIDA: Nežinoma klaida, atnaujinant specifinio vartotojo Universaliąją "
57
- "nuorodą vartotojui"
58
-
59
- #: wplogin_redirect.php:809
60
- #, fuzzy, php-format
61
- msgid "Successfully added %s-specific redirect rule for %s"
62
- msgstr "Sėkmingai atnaujintos specifinio vartotojo Universaliosios nuorodos"
63
-
64
- #: wplogin_redirect.php:870
65
- #, fuzzy, php-format
66
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
67
- msgstr ""
68
- "KLAIDA: Nežinoma klaida, atnaujinant specifinio vartotojo Universaliąją "
69
- "nuorodą vartotojui"
70
-
71
- #: wplogin_redirect.php:877
72
- #, fuzzy, php-format
73
- msgid "Successfully edited %s-specific redirect rule for %s"
74
- msgstr "Sėkmingai atnaujintos specifinio vartotojo Universaliosios nuorodos"
75
-
76
- #: wplogin_redirect.php:908
77
- #, fuzzy, php-format
78
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
79
- msgstr ""
80
- "KLAIDA: Nežinoma klaida, atnaujinant specifinio vartotojo Universaliąją "
81
- "nuorodą vartotojui"
82
-
83
- #: wplogin_redirect.php:914
84
- #, fuzzy, php-format
85
- msgid "Successfully deleted %s-specific redirect rule for %s"
86
- msgstr "Sėkmingai atnaujintos specifinio vartotojo Universaliosios nuorodos"
87
-
88
- #: wplogin_redirect.php:952
89
- msgid ""
90
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
91
- msgstr ""
92
- "KLAIDA: Nežinoma duomenų bazės problema šalinant universaliąją nuorodą &#34;"
93
- "visiems kitiems vartotojams&#34; "
94
-
95
- #: wplogin_redirect.php:956
96
- msgid "Successfully removed URL for &#34;all other users&#34; "
97
- msgstr "Sėkmingai pašalinta &#34;all other users&#34; Universalioji nuoroda"
98
-
99
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
100
- msgid "ERROR: Non-local or invalid URL submitted "
101
- msgstr "KLAIDA: Pateikta nevietinė arba neteisinga Universalioji nuoroda"
102
-
103
- #: wplogin_redirect.php:980
104
- msgid ""
105
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
106
- msgstr ""
107
- "KLAIDA: Nežinoma duomenų bazės problema atnaujinant Universaliąją nuorodą "
108
- "&#34;visiems kitiems vartotojams&#34; "
109
-
110
- #: wplogin_redirect.php:984
111
- msgid "Successfully updated URL for &#34;all other users&#34;"
112
- msgstr ""
113
- "Universalioji nuoroda &#34;visiems kitiems vartotojams&#34; sėkmingai "
114
- "atnaujinta."
115
-
116
- #: wplogin_redirect.php:1026
117
- msgid ""
118
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
119
- msgstr ""
120
- "KLAIDA: Nežinoma duomenų bazės problema, pašalinant &#34;post-"
121
- "registration&#34; Universaliąją nuorodą"
122
-
123
- #: wplogin_redirect.php:1029
124
- msgid "Successfully removed URL for &#34;post-registration&#34; "
125
- msgstr "Sėkminga pašalinta &#34;po_registracijos&#34; Universalioji nuoroda"
126
-
127
- #: wplogin_redirect.php:1052
128
- msgid ""
129
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
130
- msgstr ""
131
- "KLAIDA: Nežinoma duomenų bazės problema atnaujinant &#34;po-"
132
- "registracijos&#34; Universaliąją nuorodą"
133
-
134
- #: wplogin_redirect.php:1056
135
- msgid "Successfully updated URL for &#34;post-registration&#34;"
136
- msgstr "Sėkmingai atnaujinta &#34;po-registracijos&#34; Universalioji nuoroda"
137
-
138
- #: wplogin_redirect.php:1085
139
- msgid "Successfully updated plugin settings"
140
- msgstr "Papildinio nuostatos sėkmingai atnaujintos"
141
-
142
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
143
- #: wplogin_redirect.php:1275
144
- #, fuzzy
145
- msgid "Login URL"
146
- msgstr "Atsijungimo Universalioji nuoroda:"
147
-
148
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
149
- #: wplogin_redirect.php:1276
150
- #, fuzzy
151
- msgid "Logout URL"
152
- msgstr "Atsijungimo Universalioji nuoroda:"
153
-
154
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
155
- #: wplogin_redirect.php:1280
156
- msgid "Edit"
157
- msgstr ""
158
-
159
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
160
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
161
- #: wplogin_redirect.php:1411
162
- msgid "Delete"
163
- msgstr "Ištrinti"
164
-
165
- #: wplogin_redirect.php:1305
166
- msgid "Manage redirect rules"
167
- msgstr "Valdyti peradresavimo taisykles"
168
-
169
- #: wplogin_redirect.php:1307
170
- msgid ""
171
- "Define custom URLs to which different users, users with specific roles, "
172
- "users with specific levels, and all other users will be redirected upon "
173
- "login."
174
- msgstr ""
175
- "Nurodykite individualizuotas Universaliasias nuorodas, į kurias skirtingi "
176
- "vartotojai, vartotojai su specifinėmis funkcijoms, specifinių lygmenų "
177
- "vartotojai ir visi kiti vartotojai bus nukreipti prisijungimo metu."
178
-
179
- #: wplogin_redirect.php:1308
180
- msgid "Define a custom URL to which all users will be redirected upon logout"
181
- msgstr ""
182
- "Nurodykite individualizuotą Universaliąją nuorodą, į kurią visi vartotojai, "
183
- "atsijungimo metu bus peradresuojami"
184
-
185
- #: wplogin_redirect.php:1309
186
- msgid ""
187
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
188
- "strong> in your URLs so that the system will build a dynamic URL upon each "
189
- "login, replacing that text with the users username."
190
- msgstr ""
191
- "Žinokite, kad galite naudoti sintaksę <strong>[variable]username[/variable]</"
192
- "strong> Jūsų universaliojoje nuorodoje, todėl sistema sukurs dinaminę "
193
- "Universaliąją nuorodą, pakeičiant šį tekstą vartotojo vardu."
194
-
195
- #: wplogin_redirect.php:1311
196
- msgid "Specific users"
197
- msgstr "Specifiniai vartotojai"
198
-
199
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
200
- #: wplogin_redirect.php:1380
201
- msgid "Add:"
202
- msgstr "Pridėti:"
203
-
204
- #: wplogin_redirect.php:1324
205
- msgid "Select a username"
206
- msgstr "Pasirinkite vartotojo vardą"
207
-
208
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
209
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
210
- #: wplogin_redirect.php:1409
211
- msgid "URL:"
212
- msgstr "Universalioji nuoroda:"
213
-
214
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
215
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
216
- msgid "Logout URL:"
217
- msgstr "Atsijungimo Universalioji nuoroda:"
218
-
219
- #: wplogin_redirect.php:1331
220
- msgid "Add username rule"
221
- msgstr ""
222
-
223
- #: wplogin_redirect.php:1336
224
- msgid "Specific roles"
225
- msgstr "Specifinės funkcijos"
226
-
227
- #: wplogin_redirect.php:1349
228
- msgid "Select a role"
229
- msgstr "Pasirinkite funkciją"
230
-
231
- #: wplogin_redirect.php:1356
232
- msgid "Add role rule"
233
- msgstr ""
234
-
235
- #: wplogin_redirect.php:1361
236
- msgid "Specific levels"
237
- msgstr "Specifiniai lygmenys"
238
-
239
- #: wplogin_redirect.php:1370
240
- msgid "Order"
241
- msgstr "Tvarka"
242
-
243
- #: wplogin_redirect.php:1382
244
- msgid "Select a level"
245
- msgstr "Pasirinkite lygmenį"
246
-
247
- #: wplogin_redirect.php:1385
248
- msgid "Order:"
249
- msgstr "Tvarka:"
250
-
251
- #: wplogin_redirect.php:1390
252
- msgid "Add level rule"
253
- msgstr ""
254
-
255
- #: wplogin_redirect.php:1395
256
- msgid "All other users"
257
- msgstr "Visi kiti vartotojai"
258
-
259
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
260
- #: wplogin_redirect.php:1491
261
- msgid "Update"
262
- msgstr "Atnaujinti"
263
-
264
- #: wplogin_redirect.php:1407
265
- msgid "Post-registration"
266
- msgstr "Po registracijos"
267
-
268
- #: wplogin_redirect.php:1418
269
- msgid "Customize plugin settings"
270
- msgstr "Individualizuoti papildinio nuostatas"
271
-
272
- #: wplogin_redirect.php:1423
273
- msgid "Redirect restrictions"
274
- msgstr "Peradresavimo apribojimai"
275
-
276
- #: wplogin_redirect.php:1427
277
- msgid "Any http or https URL"
278
- msgstr "Bet koks http adresas arba https Universalioji nuoroda"
279
-
280
- #: wplogin_redirect.php:1428
281
- msgid "Any URL"
282
- msgstr "Bet kokia Universalioji nuoroda"
283
-
284
- #: wplogin_redirect.php:1429
285
- msgid "Any URL on the same domain"
286
- msgstr "Bet kokia universalioji nuorda toje pačioje srityje"
287
-
288
- #: wplogin_redirect.php:1435
289
- msgid ""
290
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
291
- "precedence"
292
- msgstr ""
293
- "Leisti POST arba GET &#34;peradresuoti_į&#34; kintamuosius, suteikiant "
294
- "peradresavimo pirmenybę"
295
-
296
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
297
- #: wplogin_redirect.php:1462
298
- msgid "Yes"
299
- msgstr "Taip"
300
-
301
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
302
- #: wplogin_redirect.php:1463
303
- msgid "No"
304
- msgstr "Ne"
305
-
306
- #: wplogin_redirect.php:1446
307
- msgid ""
308
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
309
- "precedence"
310
- msgstr ""
311
- "Leisti POST arba GET &#34;peradresuoti_į&#34; atsijungimo kintamuosius, "
312
- "suteikiant peradresavimo pirmenybę"
313
-
314
- #: wplogin_redirect.php:1458
315
- #, php-format
316
- msgid ""
317
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
318
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
319
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
320
- "other plugin to %s"
321
- msgstr ""
322
-
323
- #: wplogin_redirect.php:1469
324
- msgid "Permission level required to edit redirect URLs"
325
- msgstr "Reikiamas peradresavimo Universaliųjų nuorodų redagavimo leidimo lygis"
326
-
327
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
328
- #~ msgstr ""
329
- #~ "KLAIDA: Funkcijai priskirta nevietinė arba neteisinga Universalioji "
330
- #~ "nuoroda"
331
-
332
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
333
- #~ msgstr ""
334
- #~ "KLAIDA: Nežinoma klaida, atnaujinant specifinės funkcijos Universaliąją "
335
- #~ "nuorodą funkcijai"
336
-
337
- #~ msgid "Successfully updated role-specific URLs"
338
- #~ msgstr "Sėkmingai atnaujintos specifinio vartotojo Universaliosios nuorodos"
339
-
340
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
341
- #~ msgstr ""
342
- #~ "KLAIDA: Lygmeniui priskirta nevietinė arba neteisinga Universalioji "
343
- #~ "nuoroda"
344
-
345
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
346
- #~ msgstr ""
347
- #~ "KLAIDA: Nežinoma klaida, atnaujinant specifinio lygmens Universaliąją "
348
- #~ "nuorodą lygmeniui"
349
-
350
- #~ msgid "Successfully updated level-specific URLs"
351
- #~ msgstr "Sėkmingai atnaujintos specifinio lygmens Universaliosios nuorodos"
352
-
353
- #~ msgid "Username"
354
- #~ msgstr "Vartotojo vardas"
355
-
356
- #~ msgid "URL"
357
- #~ msgstr "Universalioji nuoroda"
358
-
359
- #~ msgid "Role"
360
- #~ msgstr "Funkcija"
361
-
362
- #~ msgid "Level"
363
- #~ msgstr "Lygmuo"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-nl_NL.mo DELETED
Binary file
languages/peters-login-redirect-nl_NL.po DELETED
@@ -1,359 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: peters login redirect v1.9.3\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:09-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Peter <peter@keung.biz>\n"
8
- "Language-Team: werkgroepen.net <team@werkgroepen.net>\n"
9
- "Language: nl_NL\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Generator: Poedit 2.2.1\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
-
21
- #: wplogin_redirect.php:580
22
- msgid "Register"
23
- msgstr "Registreren"
24
-
25
- #: wplogin_redirect.php:584
26
- msgid "Site Admin"
27
- msgstr "Websitebeheerder"
28
-
29
- #: wplogin_redirect.php:706
30
- msgid "ERROR: Non-existent username submitted "
31
- msgstr "FOUT: Niet bestaande gebruikersnaam toegevoegd"
32
-
33
- #: wplogin_redirect.php:716
34
- msgid "ERROR: Non-existent role submitted "
35
- msgstr "FOUT: Niet bestaande rol toegevoegd"
36
-
37
- #: wplogin_redirect.php:727
38
- msgid "ERROR: Non-existent level submitted "
39
- msgstr "FOUT: Niet bestaand niveau toegevoegd"
40
-
41
- #: wplogin_redirect.php:744
42
- #, fuzzy, php-format
43
- msgid "ERROR: Empty %s submitted "
44
- msgstr "FOUT: Niet bestaande rol toegevoegd"
45
-
46
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
47
- #, fuzzy, php-format
48
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
49
- msgstr "FOUT: Geen locale of ongeldige URL ingegeven voor gebruiker "
50
-
51
- #: wplogin_redirect.php:802
52
- #, fuzzy, php-format
53
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
54
- msgstr ""
55
- "FOUT: Onbekende fout tijdens het bijwerken van de gebruiker specifieke URL "
56
- "van de gebruiker "
57
-
58
- #: wplogin_redirect.php:809
59
- #, fuzzy, php-format
60
- msgid "Successfully added %s-specific redirect rule for %s"
61
- msgstr "Gebruiker specifieke URLs bijgewerkt"
62
-
63
- #: wplogin_redirect.php:870
64
- #, fuzzy, php-format
65
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
66
- msgstr ""
67
- "FOUT: Onbekende fout tijdens het bijwerken van de gebruiker specifieke URL "
68
- "van de gebruiker "
69
-
70
- #: wplogin_redirect.php:877
71
- #, fuzzy, php-format
72
- msgid "Successfully edited %s-specific redirect rule for %s"
73
- msgstr "Gebruiker specifieke URLs bijgewerkt"
74
-
75
- #: wplogin_redirect.php:908
76
- #, fuzzy, php-format
77
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
78
- msgstr ""
79
- "FOUT: Onbekende fout tijdens het bijwerken van de gebruiker specifieke URL "
80
- "van de gebruiker "
81
-
82
- #: wplogin_redirect.php:914
83
- #, fuzzy, php-format
84
- msgid "Successfully deleted %s-specific redirect rule for %s"
85
- msgstr "Gebruiker specifieke URLs bijgewerkt"
86
-
87
- #: wplogin_redirect.php:952
88
- msgid ""
89
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
90
- msgstr ""
91
- "FOUT: Onbekend database probleen tijdens het verwijderen van de URL van &#34;"
92
- "alle andere gebruikers&#34; "
93
-
94
- #: wplogin_redirect.php:956
95
- msgid "Successfully removed URL for &#34;all other users&#34; "
96
- msgstr "De URL van &#34;alle andere gebruikers&#34; met succes verwijderd"
97
-
98
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
99
- msgid "ERROR: Non-local or invalid URL submitted "
100
- msgstr "FOUT: Geen locale of ongeldige URL ingegeven"
101
-
102
- #: wplogin_redirect.php:980
103
- msgid ""
104
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
105
- msgstr ""
106
- "FOUT: Onbekend database probleem tijdens het bijwerken van &#34;alle andere "
107
- "gebruikers&#34; "
108
-
109
- #: wplogin_redirect.php:984
110
- msgid "Successfully updated URL for &#34;all other users&#34;"
111
- msgstr "De URL van &#34;all other users&#34; is met succes bijgewerkt"
112
-
113
- #: wplogin_redirect.php:1026
114
- #, fuzzy
115
- msgid ""
116
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
117
- msgstr ""
118
- "FOUT: Onbekend database probleen tijdens het verwijderen van de URL van &#34;"
119
- "alle andere gebruikers&#34; "
120
-
121
- #: wplogin_redirect.php:1029
122
- #, fuzzy
123
- msgid "Successfully removed URL for &#34;post-registration&#34; "
124
- msgstr "De URL van &#34;alle andere gebruikers&#34; met succes verwijderd"
125
-
126
- #: wplogin_redirect.php:1052
127
- #, fuzzy
128
- msgid ""
129
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
130
- msgstr ""
131
- "FOUT: Onbekend database probleem tijdens het bijwerken van &#34;alle andere "
132
- "gebruikers&#34; "
133
-
134
- #: wplogin_redirect.php:1056
135
- #, fuzzy
136
- msgid "Successfully updated URL for &#34;post-registration&#34;"
137
- msgstr "De URL van &#34;all other users&#34; is met succes bijgewerkt"
138
-
139
- #: wplogin_redirect.php:1085
140
- #, fuzzy
141
- msgid "Successfully updated plugin settings"
142
- msgstr "Gebruiker specifieke URLs bijgewerkt"
143
-
144
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
145
- #: wplogin_redirect.php:1275
146
- #, fuzzy
147
- msgid "Login URL"
148
- msgstr "URL(internetadres)"
149
-
150
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
151
- #: wplogin_redirect.php:1276
152
- msgid "Logout URL"
153
- msgstr ""
154
-
155
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
156
- #: wplogin_redirect.php:1280
157
- msgid "Edit"
158
- msgstr ""
159
-
160
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
161
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
162
- #: wplogin_redirect.php:1411
163
- msgid "Delete"
164
- msgstr "Verwijderen"
165
-
166
- #: wplogin_redirect.php:1305
167
- #, fuzzy
168
- msgid "Manage redirect rules"
169
- msgstr "Beheer login redirect(verwijs) regels"
170
-
171
- #: wplogin_redirect.php:1307
172
- #, fuzzy
173
- msgid ""
174
- "Define custom URLs to which different users, users with specific roles, "
175
- "users with specific levels, and all other users will be redirected upon "
176
- "login."
177
- msgstr ""
178
- "Definieer verschillende locale URLs (internetadressen) naar waar "
179
- "verschillende gebruikers, gebruikers met specifieke rollen, gebruikers met "
180
- "specifieke niveaus en alle andere gebruikers naar worden "
181
- "geredirect(doorverwezen)."
182
-
183
- #: wplogin_redirect.php:1308
184
- msgid "Define a custom URL to which all users will be redirected upon logout"
185
- msgstr ""
186
-
187
- #: wplogin_redirect.php:1309
188
- msgid ""
189
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
190
- "strong> in your URLs so that the system will build a dynamic URL upon each "
191
- "login, replacing that text with the users username."
192
- msgstr ""
193
- "Opmerking: je kunt the syntax gebruiken <strong>[variable]username[/"
194
- "variable]</strong in je URLs (internetadressen). Het systeem zal een "
195
- "dynamische URL maken voor elke login. Vervang gebruikersnaam met de "
196
- "gebruikersnaam van de gebruiker."
197
-
198
- #: wplogin_redirect.php:1311
199
- msgid "Specific users"
200
- msgstr "Specifieke gebruikers"
201
-
202
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
203
- #: wplogin_redirect.php:1380
204
- msgid "Add:"
205
- msgstr "Toevoegen:"
206
-
207
- #: wplogin_redirect.php:1324
208
- msgid "Select a username"
209
- msgstr "selecteer een gebruikersnaam"
210
-
211
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
212
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
213
- #: wplogin_redirect.php:1409
214
- msgid "URL:"
215
- msgstr "URL(internetadres):"
216
-
217
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
218
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
219
- msgid "Logout URL:"
220
- msgstr ""
221
-
222
- #: wplogin_redirect.php:1331
223
- msgid "Add username rule"
224
- msgstr ""
225
-
226
- #: wplogin_redirect.php:1336
227
- msgid "Specific roles"
228
- msgstr "Specifieke rollen"
229
-
230
- #: wplogin_redirect.php:1349
231
- msgid "Select a role"
232
- msgstr "Selecteer een rol"
233
-
234
- #: wplogin_redirect.php:1356
235
- msgid "Add role rule"
236
- msgstr ""
237
-
238
- #: wplogin_redirect.php:1361
239
- msgid "Specific levels"
240
- msgstr "Specifieke niveaus"
241
-
242
- #: wplogin_redirect.php:1370
243
- msgid "Order"
244
- msgstr "Volgorde"
245
-
246
- #: wplogin_redirect.php:1382
247
- msgid "Select a level"
248
- msgstr "Selecteer een niveau"
249
-
250
- #: wplogin_redirect.php:1385
251
- msgid "Order:"
252
- msgstr "Volgorde:"
253
-
254
- #: wplogin_redirect.php:1390
255
- msgid "Add level rule"
256
- msgstr ""
257
-
258
- #: wplogin_redirect.php:1395
259
- msgid "All other users"
260
- msgstr "Alle andere gebruikers"
261
-
262
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
263
- #: wplogin_redirect.php:1491
264
- msgid "Update"
265
- msgstr "Bijwerken"
266
-
267
- #: wplogin_redirect.php:1407
268
- msgid "Post-registration"
269
- msgstr ""
270
-
271
- #: wplogin_redirect.php:1418
272
- msgid "Customize plugin settings"
273
- msgstr ""
274
-
275
- #: wplogin_redirect.php:1423
276
- msgid "Redirect restrictions"
277
- msgstr ""
278
-
279
- #: wplogin_redirect.php:1427
280
- msgid "Any http or https URL"
281
- msgstr ""
282
-
283
- #: wplogin_redirect.php:1428
284
- #, fuzzy
285
- msgid "Any URL"
286
- msgstr "URL(internetadres)"
287
-
288
- #: wplogin_redirect.php:1429
289
- msgid "Any URL on the same domain"
290
- msgstr ""
291
-
292
- #: wplogin_redirect.php:1435
293
- msgid ""
294
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
295
- "precedence"
296
- msgstr ""
297
-
298
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
299
- #: wplogin_redirect.php:1462
300
- msgid "Yes"
301
- msgstr ""
302
-
303
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
304
- #: wplogin_redirect.php:1463
305
- msgid "No"
306
- msgstr ""
307
-
308
- #: wplogin_redirect.php:1446
309
- msgid ""
310
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
311
- "precedence"
312
- msgstr ""
313
-
314
- #: wplogin_redirect.php:1458
315
- #, php-format
316
- msgid ""
317
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
318
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
319
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
320
- "other plugin to %s"
321
- msgstr ""
322
-
323
- #: wplogin_redirect.php:1469
324
- msgid "Permission level required to edit redirect URLs"
325
- msgstr ""
326
-
327
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
328
- #~ msgstr "FOUT: Geen locale of ongeldige URL ingegeven voor de rol "
329
-
330
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
331
- #~ msgstr ""
332
- #~ "FOUT: Onbekende fout tijdens het bijwerken van de rol specifieke URL van "
333
- #~ "de rol"
334
-
335
- #~ msgid "Successfully updated role-specific URLs"
336
- #~ msgstr "Rol specifieke URLs met succes bijgewerkt"
337
-
338
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
339
- #~ msgstr "FOUT: Geen locale of ongeldige URL ingegeven voor het niveau"
340
-
341
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
342
- #~ msgstr ""
343
- #~ "FOUT: Onbekende fout tijdens bijwerken van de niveau specifieke URL van "
344
- #~ "niveau"
345
-
346
- #~ msgid "Successfully updated level-specific URLs"
347
- #~ msgstr "Gebruiker niveau specifieke URLs met succes bijgewerkt"
348
-
349
- #~ msgid "Username"
350
- #~ msgstr "Gebruikersnaam"
351
-
352
- #~ msgid "URL"
353
- #~ msgstr "URL(internetadres)"
354
-
355
- #~ msgid "Role"
356
- #~ msgstr "Rol"
357
-
358
- #~ msgid "Level"
359
- #~ msgstr "Niveau"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-pt_BR.mo DELETED
Binary file
languages/peters-login-redirect-pt_BR.po DELETED
@@ -1,382 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peter's Login Redirect v2.8.2\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2016-08-10 21:12-0800\n"
6
- "PO-Revision-Date: 2019-02-23 07:24-0800\n"
7
- "Last-Translator: comglobal <alvaro@localhost.com>\n"
8
- "Language-Team: \n"
9
- "Language: pt_BR\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=n != 1;\n"
14
- "X-Generator: Poedit 2.2.1\n"
15
- "X-Poedit-SourceCharset: utf-8\n"
16
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
17
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n"
18
- "X-Textdomain-Support: yes\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
-
21
- # @ peterloginrd
22
- #: wplogin_redirect.php:579
23
- msgid "Register"
24
- msgstr "Registrar"
25
-
26
- # @ peterloginrd
27
- #: wplogin_redirect.php:583
28
- msgid "Site Admin"
29
- msgstr "Administrador"
30
-
31
- # @ peterloginrd
32
- #: wplogin_redirect.php:705
33
- msgid "ERROR: Non-existent username submitted "
34
- msgstr "ERRO: Usuário inexistente"
35
-
36
- # @ peterloginrd
37
- #: wplogin_redirect.php:715
38
- msgid "ERROR: Non-existent role submitted "
39
- msgstr "ERRO: Papel inexistente"
40
-
41
- # @ peterloginrd
42
- #: wplogin_redirect.php:726
43
- msgid "ERROR: Non-existent level submitted "
44
- msgstr "ERRO: Nível inexistente"
45
-
46
- # @ peterloginrd
47
- #: wplogin_redirect.php:743
48
- #, php-format
49
- msgid "ERROR: Empty %s submitted "
50
- msgstr "ERRO: %s vazio"
51
-
52
- # @ peterloginrd
53
- #: wplogin_redirect.php:772 wplogin_redirect.php:834
54
- #, php-format
55
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
56
- msgstr "ERRO: Endereço inválido ou externo para %s %s"
57
-
58
- # @ peterloginrd
59
- #: wplogin_redirect.php:798
60
- #, php-format
61
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
62
- msgstr ""
63
- "ERRO: Erro desconhecido ao adicionar redirecionamento %s-específico para %s "
64
- "%s"
65
-
66
- # @ peterloginrd
67
- #: wplogin_redirect.php:805
68
- #, php-format
69
- msgid "Successfully added %s-specific redirect rule for %s"
70
- msgstr "Sucesso ao adicionar regra de redirecionamento %s-específica para %s"
71
-
72
- # @ peterloginrd
73
- #: wplogin_redirect.php:863
74
- #, php-format
75
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
76
- msgstr ""
77
- "ERRO: Erro desconhecido ao editar redirecionamento %s-específico para %s %s"
78
-
79
- # @ peterloginrd
80
- #: wplogin_redirect.php:870
81
- #, php-format
82
- msgid "Successfully edited %s-specific redirect rule for %s"
83
- msgstr "Sucesso ao editar regra de redirecionamento %s-específica para %s"
84
-
85
- # @ peterloginrd
86
- #: wplogin_redirect.php:898
87
- #, php-format
88
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
89
- msgstr ""
90
- "ERRO: Erro desconhecido ao excluir redirecionamento %s-específico para %s %s"
91
-
92
- # @ peterloginrd
93
- #: wplogin_redirect.php:904
94
- #, php-format
95
- msgid "Successfully deleted %s-specific redirect rule for %s"
96
- msgstr "Sucesso ao excluir regra de redirecionamento %s-específico para %s "
97
-
98
- # @ peterloginrd
99
- #: wplogin_redirect.php:939
100
- msgid ""
101
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
102
- msgstr ""
103
- "ERRO: Problema desconhecido de banco de dados ao remover a URL para &#34;"
104
- "todos os outros usuários&#34; "
105
-
106
- # @ peterloginrd
107
- #: wplogin_redirect.php:943
108
- msgid "Successfully removed URL for &#34;all other users&#34; "
109
- msgstr "Sucesso ao remover a URL para &#34;todos os outros usuários&#34; "
110
-
111
- # @ peterloginrd
112
- #: wplogin_redirect.php:954 wplogin_redirect.php:1023
113
- msgid "ERROR: Non-local or invalid URL submitted "
114
- msgstr "ERRO: A URL enviada é externa ou inválida"
115
-
116
- # @ peterloginrd
117
- #: wplogin_redirect.php:967
118
- msgid ""
119
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
120
- msgstr ""
121
- "ERRO: Erro desconhecido de banco de dados ao atualizar a URL para &#34;todos "
122
- "os outros usuários&#34; "
123
-
124
- # @ peterloginrd
125
- #: wplogin_redirect.php:971
126
- msgid "Successfully updated URL for &#34;all other users&#34;"
127
- msgstr "Sucesso ao atualizar a URL para &#34;todos os outros usuários&#34;"
128
-
129
- # @ peterloginrd
130
- #: wplogin_redirect.php:1010
131
- msgid ""
132
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
133
- msgstr ""
134
- "ERRO: Problema desconhecido de banco de dados ao remover a URL para &#34;pós-"
135
- "registro&#34; "
136
-
137
- # @ peterloginrd
138
- #: wplogin_redirect.php:1013
139
- msgid "Successfully removed URL for &#34;post-registration&#34; "
140
- msgstr "Sucesso ao remover a URL para &#34;pós-registro&#34; "
141
-
142
- # @ peterloginrd
143
- #: wplogin_redirect.php:1036
144
- msgid ""
145
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
146
- msgstr ""
147
- "ERRO: Problema desconhecido de banco de dados ao atualizar a URL para &#34;"
148
- "pós-registro&#34; "
149
-
150
- # @ peterloginrd
151
- #: wplogin_redirect.php:1040
152
- msgid "Successfully updated URL for &#34;post-registration&#34;"
153
- msgstr "Sucesso ao atualizar a URL para &#34;pós-registro&#34; "
154
-
155
- # @ peterloginrd
156
- #: wplogin_redirect.php:1066
157
- msgid "Successfully updated plugin settings"
158
- msgstr "Sucesso ao atualizar as configurações do plugin"
159
-
160
- # @ peterloginrd
161
- #: wplogin_redirect.php:1215 wplogin_redirect.php:1233
162
- #: wplogin_redirect.php:1250
163
- msgid "Login URL"
164
- msgstr "URL de Login"
165
-
166
- # @ peterloginrd
167
- #: wplogin_redirect.php:1216 wplogin_redirect.php:1234
168
- #: wplogin_redirect.php:1251
169
- msgid "Logout URL"
170
- msgstr "URL de Logout"
171
-
172
- # @ peterloginrd
173
- #: wplogin_redirect.php:1218 wplogin_redirect.php:1236
174
- #: wplogin_redirect.php:1254
175
- msgid "Edit"
176
- msgstr "Editar"
177
-
178
- # @ peterloginrd
179
- #: wplogin_redirect.php:1218 wplogin_redirect.php:1236
180
- #: wplogin_redirect.php:1254 wplogin_redirect.php:1362
181
- #: wplogin_redirect.php:1370
182
- msgid "Delete"
183
- msgstr "Excluir"
184
-
185
- # @ peterloginrd
186
- #: wplogin_redirect.php:1277
187
- msgid "Manage redirect rules"
188
- msgstr "Administrar regras de redirecionamento"
189
-
190
- # @ peterloginrd
191
- #: wplogin_redirect.php:1279
192
- msgid ""
193
- "Define custom URLs to which different users, users with specific roles, "
194
- "users with specific levels, and all other users will be redirected upon "
195
- "login."
196
- msgstr ""
197
- "Definir URLs personalizados para usuários diferentes, usuários com papéis "
198
- "específicos, usuários com níveis específicos e para onde todos os outros "
199
- "usuários serão redirecionados após o login."
200
-
201
- # @ peterloginrd
202
- #: wplogin_redirect.php:1280
203
- msgid "Define a custom URL to which all users will be redirected upon logout"
204
- msgstr ""
205
- "Definir um URL personalizado para onde todos os usuários serão "
206
- "redirecionados após o logout"
207
-
208
- # @ peterloginrd
209
- #: wplogin_redirect.php:1281
210
- msgid ""
211
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
212
- "strong> in your URLs so that the system will build a dynamic URL upon each "
213
- "login, replacing that text with the users username."
214
- msgstr ""
215
- "Observe que você pode utilizar a sintaxe <strong>[variable]username[/"
216
- "variable]</strong> em suas URLs para que o sistema construa uma URL dinâmica "
217
- "a cada login, substituindo esse texto pelo nome de usuário real."
218
-
219
- # @ peterloginrd
220
- #: wplogin_redirect.php:1283
221
- msgid "Specific users"
222
- msgstr "Usuários específicos"
223
-
224
- # @ peterloginrd
225
- #: wplogin_redirect.php:1294 wplogin_redirect.php:1316
226
- #: wplogin_redirect.php:1346
227
- msgid "Add:"
228
- msgstr "Adicionar:"
229
-
230
- # @ peterloginrd
231
- #: wplogin_redirect.php:1296
232
- msgid "Select a username"
233
- msgstr "Selecione um nome de usuário"
234
-
235
- # @ peterloginrd
236
- #: wplogin_redirect.php:1299 wplogin_redirect.php:1321
237
- #: wplogin_redirect.php:1352 wplogin_redirect.php:1360
238
- #: wplogin_redirect.php:1369
239
- msgid "URL:"
240
- msgstr "URL:"
241
-
242
- # @ peterloginrd
243
- #: wplogin_redirect.php:1300 wplogin_redirect.php:1322
244
- #: wplogin_redirect.php:1353 wplogin_redirect.php:1361
245
- msgid "Logout URL:"
246
- msgstr "URL de Logout:"
247
-
248
- # @ peterloginrd
249
- #: wplogin_redirect.php:1302
250
- msgid "Add username rule"
251
- msgstr "Adicione regra de usuário"
252
-
253
- # @ peterloginrd
254
- #: wplogin_redirect.php:1305
255
- msgid "Specific roles"
256
- msgstr "Papéis específicos"
257
-
258
- # @ peterloginrd
259
- #: wplogin_redirect.php:1318
260
- msgid "Select a role"
261
- msgstr "Selecione um papel"
262
-
263
- # @ peterloginrd
264
- #: wplogin_redirect.php:1324
265
- msgid "Add role rule"
266
- msgstr "Adicione uma regra para papel"
267
-
268
- # @ peterloginrd
269
- #: wplogin_redirect.php:1327
270
- msgid "Specific levels"
271
- msgstr "Níveis específicos"
272
-
273
- # @ peterloginrd
274
- #: wplogin_redirect.php:1336
275
- msgid "Order"
276
- msgstr "Ordem"
277
-
278
- # @ peterloginrd
279
- #: wplogin_redirect.php:1348
280
- msgid "Select a level"
281
- msgstr "Selecione um nível"
282
-
283
- # @ peterloginrd
284
- #: wplogin_redirect.php:1351
285
- msgid "Order:"
286
- msgstr "Ordem:"
287
-
288
- # @ peterloginrd
289
- #: wplogin_redirect.php:1355
290
- msgid "Add level rule"
291
- msgstr "Adicione uma regra de nível"
292
-
293
- # @ peterloginrd
294
- #: wplogin_redirect.php:1358
295
- msgid "All other users"
296
- msgstr "Todos os outros usuários"
297
-
298
- # @ peterloginrd
299
- #: wplogin_redirect.php:1362 wplogin_redirect.php:1370
300
- #: wplogin_redirect.php:1447
301
- msgid "Update"
302
- msgstr "Atualizar"
303
-
304
- # @ peterloginrd
305
- #: wplogin_redirect.php:1367
306
- msgid "Post-registration"
307
- msgstr "Pós-registro"
308
-
309
- # @ peterloginrd
310
- #: wplogin_redirect.php:1375
311
- msgid "Customize plugin settings"
312
- msgstr "Personalizar as configurações do plugin"
313
-
314
- # @ peterloginrd
315
- #: wplogin_redirect.php:1380
316
- msgid "Redirect restrictions"
317
- msgstr "Restrições de redirecionamento"
318
-
319
- # @ peterloginrd
320
- #: wplogin_redirect.php:1384
321
- msgid "Any http or https URL"
322
- msgstr "Qualquer URL http ou https"
323
-
324
- # @ peterloginrd
325
- #: wplogin_redirect.php:1385
326
- msgid "Any URL"
327
- msgstr "Qualquer URL"
328
-
329
- # @ peterloginrd
330
- #: wplogin_redirect.php:1386
331
- msgid "Any URL on the same domain"
332
- msgstr "Qualquer URL no mesmo domínio"
333
-
334
- # @ peterloginrd
335
- #: wplogin_redirect.php:1392
336
- msgid ""
337
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
338
- "precedence"
339
- msgstr ""
340
- "Permitir que uma variável POST ou GET &#34;redirect_to&#34; tenha "
341
- "preferência no redirecionamento"
342
-
343
- # @ peterloginrd
344
- #: wplogin_redirect.php:1396 wplogin_redirect.php:1407
345
- #: wplogin_redirect.php:1419
346
- msgid "Yes"
347
- msgstr "Sim"
348
-
349
- # @ peterloginrd
350
- #: wplogin_redirect.php:1397 wplogin_redirect.php:1408
351
- #: wplogin_redirect.php:1420
352
- msgid "No"
353
- msgstr "Não"
354
-
355
- # @ peterloginrd
356
- #: wplogin_redirect.php:1403
357
- msgid ""
358
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
359
- "precedence"
360
- msgstr ""
361
- "Permitir que uma variável de logout POST ou GET &#34;redirect_to&#34; tenha "
362
- "preferência no redirecionamento"
363
-
364
- # @ peterloginrd
365
- #: wplogin_redirect.php:1415
366
- #, php-format
367
- msgid ""
368
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
369
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
370
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
371
- "other plugin to %s"
372
- msgstr ""
373
- "Usar um arquivo externo de redirecionamento. Defina isso para &#34;Sim&#34; "
374
- "se estiver usando um plugin como o Gigya que ignora o processo de "
375
- "redirecionamento normal do WordPress (e permite somente uma URL fixa de "
376
- "redirecionamento). Então, configure a URL de redirecionamento no outro "
377
- "plugin para %s"
378
-
379
- # @ peterloginrd
380
- #: wplogin_redirect.php:1426
381
- msgid "Permission level required to edit redirect URLs"
382
- msgstr "Nível de permissão requerido para editar URLs de redirecionamento"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-ro_RO.mo DELETED
Binary file
languages/peters-login-redirect-ro_RO.po DELETED
@@ -1,354 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peters'login redirect v2.0.0\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:09-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Peter <peter@keung.biz>\n"
8
- "Language-Team: jibo.ro <contact@jibo.ro>\n"
9
- "Language: ro_RO\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Poedit-SourceCharset: utf-8\n"
19
- "X-Generator: Poedit 2.2.1\n"
20
- "X-Poedit-SearchPath-0: .\n"
21
-
22
- #: wplogin_redirect.php:580
23
- msgid "Register"
24
- msgstr "Inregistrare"
25
-
26
- #: wplogin_redirect.php:584
27
- msgid "Site Admin"
28
- msgstr "Administrator site"
29
-
30
- #: wplogin_redirect.php:706
31
- msgid "ERROR: Non-existent username submitted "
32
- msgstr "Eroare: A fost introdus un username inexistent"
33
-
34
- #: wplogin_redirect.php:716
35
- msgid "ERROR: Non-existent role submitted "
36
- msgstr "EROARE: Rolul introdus este inexistent"
37
-
38
- #: wplogin_redirect.php:727
39
- msgid "ERROR: Non-existent level submitted "
40
- msgstr "EROARE: Nivelul trimis este inexistent"
41
-
42
- #: wplogin_redirect.php:744
43
- #, fuzzy, php-format
44
- msgid "ERROR: Empty %s submitted "
45
- msgstr "EROARE: Rolul introdus este inexistent"
46
-
47
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
48
- #, fuzzy, php-format
49
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
50
- msgstr "EROARE: URL-ul trimis de utilizator este invalid sau nu este local"
51
-
52
- #: wplogin_redirect.php:802
53
- #, fuzzy, php-format
54
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
55
- msgstr ""
56
- "EROARE: Eroare necunoscuta la actualizarea URL-ului specific pentru "
57
- "utilizator"
58
-
59
- #: wplogin_redirect.php:809
60
- #, fuzzy, php-format
61
- msgid "Successfully added %s-specific redirect rule for %s"
62
- msgstr "URL-urile specifice utilizatorilor actualizate cu succes"
63
-
64
- #: wplogin_redirect.php:870
65
- #, fuzzy, php-format
66
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
67
- msgstr ""
68
- "EROARE: Eroare necunoscuta la actualizarea URL-ului specific pentru "
69
- "utilizator"
70
-
71
- #: wplogin_redirect.php:877
72
- #, fuzzy, php-format
73
- msgid "Successfully edited %s-specific redirect rule for %s"
74
- msgstr "URL-urile specifice utilizatorilor actualizate cu succes"
75
-
76
- #: wplogin_redirect.php:908
77
- #, fuzzy, php-format
78
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
79
- msgstr ""
80
- "EROARE: Eroare necunoscuta la actualizarea URL-ului specific pentru "
81
- "utilizator"
82
-
83
- #: wplogin_redirect.php:914
84
- #, fuzzy, php-format
85
- msgid "Successfully deleted %s-specific redirect rule for %s"
86
- msgstr "URL-urile specifice utilizatorilor actualizate cu succes"
87
-
88
- #: wplogin_redirect.php:952
89
- msgid ""
90
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
91
- msgstr ""
92
- "EROARE: Eroare de baza de date necunoscuta la inlaturarea URL-urilor pentru "
93
- "&#34;toti utilizatorii&#34; "
94
-
95
- #: wplogin_redirect.php:956
96
- msgid "Successfully removed URL for &#34;all other users&#34; "
97
- msgstr "S-a inlaturat cu succes URL-ul pentru &#34;toti utilizatorii&#34; "
98
-
99
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
100
- msgid "ERROR: Non-local or invalid URL submitted "
101
- msgstr "EROARE: S-a trimis un URL inexistent sau nu este local"
102
-
103
- #: wplogin_redirect.php:980
104
- msgid ""
105
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
106
- msgstr ""
107
- "EROARE: Problema necunoscuta la actualizarea URL-ului in baza de date pentru "
108
- "&#34;toti utilizatorii&#34; "
109
-
110
- #: wplogin_redirect.php:984
111
- msgid "Successfully updated URL for &#34;all other users&#34;"
112
- msgstr "URL actualizat cu succes pentru &#34;toti ceilalti utilizatori&#34;"
113
-
114
- #: wplogin_redirect.php:1026
115
- #, fuzzy
116
- msgid ""
117
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
118
- msgstr ""
119
- "EROARE: Eroare de baza de date necunoscuta la inlaturarea URL-urilor pentru "
120
- "&#34;toti utilizatorii&#34; "
121
-
122
- #: wplogin_redirect.php:1029
123
- #, fuzzy
124
- msgid "Successfully removed URL for &#34;post-registration&#34; "
125
- msgstr "S-a inlaturat cu succes URL-ul pentru &#34;toti utilizatorii&#34; "
126
-
127
- #: wplogin_redirect.php:1052
128
- #, fuzzy
129
- msgid ""
130
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
131
- msgstr ""
132
- "EROARE: Problema necunoscuta la actualizarea URL-ului in baza de date pentru "
133
- "&#34;toti utilizatorii&#34; "
134
-
135
- #: wplogin_redirect.php:1056
136
- #, fuzzy
137
- msgid "Successfully updated URL for &#34;post-registration&#34;"
138
- msgstr "URL actualizat cu succes pentru &#34;toti ceilalti utilizatori&#34;"
139
-
140
- #: wplogin_redirect.php:1085
141
- #, fuzzy
142
- msgid "Successfully updated plugin settings"
143
- msgstr "URL-urile specifice utilizatorilor actualizate cu succes"
144
-
145
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
146
- #: wplogin_redirect.php:1275
147
- #, fuzzy
148
- msgid "Login URL"
149
- msgstr "URL"
150
-
151
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
152
- #: wplogin_redirect.php:1276
153
- msgid "Logout URL"
154
- msgstr ""
155
-
156
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
157
- #: wplogin_redirect.php:1280
158
- msgid "Edit"
159
- msgstr ""
160
-
161
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
162
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
163
- #: wplogin_redirect.php:1411
164
- msgid "Delete"
165
- msgstr "Sterge"
166
-
167
- #: wplogin_redirect.php:1305
168
- #, fuzzy
169
- msgid "Manage redirect rules"
170
- msgstr "Modifica regulile de redirectionare a autentificarii"
171
-
172
- #: wplogin_redirect.php:1307
173
- #, fuzzy
174
- msgid ""
175
- "Define custom URLs to which different users, users with specific roles, "
176
- "users with specific levels, and all other users will be redirected upon "
177
- "login."
178
- msgstr ""
179
- "Specifica URL-uri locale diferite pentru care utilizatorii diferiti, "
180
- "utilizatorii cu roluri specifice, utilizatorii cu nivele specifice si toti "
181
- "ceilalti utilizatori vor fi redirectionati."
182
-
183
- #: wplogin_redirect.php:1308
184
- msgid "Define a custom URL to which all users will be redirected upon logout"
185
- msgstr ""
186
-
187
- #: wplogin_redirect.php:1309
188
- msgid ""
189
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
190
- "strong> in your URLs so that the system will build a dynamic URL upon each "
191
- "login, replacing that text with the users username."
192
- msgstr ""
193
- "Tine minte ca poti folosi sintaxa <strong>[variable]username[/variable]</"
194
- "strong> in URL-urile tale pentru ca sistemul sa construiasca un URL dinamic "
195
- "dupa fiecare autentificare, schimband acel text cu numele utilizatorului."
196
-
197
- #: wplogin_redirect.php:1311
198
- msgid "Specific users"
199
- msgstr "Utilizatori specifici"
200
-
201
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
202
- #: wplogin_redirect.php:1380
203
- msgid "Add:"
204
- msgstr "Adauga:"
205
-
206
- #: wplogin_redirect.php:1324
207
- msgid "Select a username"
208
- msgstr "Selecteaza un username"
209
-
210
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
211
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
212
- #: wplogin_redirect.php:1409
213
- msgid "URL:"
214
- msgstr "URL:"
215
-
216
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
217
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
218
- msgid "Logout URL:"
219
- msgstr ""
220
-
221
- #: wplogin_redirect.php:1331
222
- msgid "Add username rule"
223
- msgstr ""
224
-
225
- #: wplogin_redirect.php:1336
226
- msgid "Specific roles"
227
- msgstr "Roluri specifice"
228
-
229
- #: wplogin_redirect.php:1349
230
- msgid "Select a role"
231
- msgstr "Selecteaza un rol"
232
-
233
- #: wplogin_redirect.php:1356
234
- msgid "Add role rule"
235
- msgstr ""
236
-
237
- #: wplogin_redirect.php:1361
238
- msgid "Specific levels"
239
- msgstr "Nivele specifice"
240
-
241
- #: wplogin_redirect.php:1370
242
- msgid "Order"
243
- msgstr "Ordoneaza"
244
-
245
- #: wplogin_redirect.php:1382
246
- msgid "Select a level"
247
- msgstr "Selecteaza un nivel"
248
-
249
- #: wplogin_redirect.php:1385
250
- msgid "Order:"
251
- msgstr "Ordine:"
252
-
253
- #: wplogin_redirect.php:1390
254
- msgid "Add level rule"
255
- msgstr ""
256
-
257
- #: wplogin_redirect.php:1395
258
- msgid "All other users"
259
- msgstr "Toti utilizatorii ramasi"
260
-
261
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
262
- #: wplogin_redirect.php:1491
263
- msgid "Update"
264
- msgstr "Actualizeaza"
265
-
266
- #: wplogin_redirect.php:1407
267
- msgid "Post-registration"
268
- msgstr ""
269
-
270
- #: wplogin_redirect.php:1418
271
- msgid "Customize plugin settings"
272
- msgstr ""
273
-
274
- #: wplogin_redirect.php:1423
275
- msgid "Redirect restrictions"
276
- msgstr ""
277
-
278
- #: wplogin_redirect.php:1427
279
- msgid "Any http or https URL"
280
- msgstr ""
281
-
282
- #: wplogin_redirect.php:1428
283
- #, fuzzy
284
- msgid "Any URL"
285
- msgstr "URL"
286
-
287
- #: wplogin_redirect.php:1429
288
- msgid "Any URL on the same domain"
289
- msgstr ""
290
-
291
- #: wplogin_redirect.php:1435
292
- msgid ""
293
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
294
- "precedence"
295
- msgstr ""
296
-
297
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
298
- #: wplogin_redirect.php:1462
299
- msgid "Yes"
300
- msgstr ""
301
-
302
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
303
- #: wplogin_redirect.php:1463
304
- msgid "No"
305
- msgstr ""
306
-
307
- #: wplogin_redirect.php:1446
308
- msgid ""
309
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
310
- "precedence"
311
- msgstr ""
312
-
313
- #: wplogin_redirect.php:1458
314
- #, php-format
315
- msgid ""
316
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
317
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
318
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
319
- "other plugin to %s"
320
- msgstr ""
321
-
322
- #: wplogin_redirect.php:1469
323
- msgid "Permission level required to edit redirect URLs"
324
- msgstr ""
325
-
326
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
327
- #~ msgstr "EROARE: URL-ul trimis pentru rol este invalid sau nu este local"
328
-
329
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
330
- #~ msgstr "EROARE: Eroare necunoscuta la actualizarea URL-ului pentru rol"
331
-
332
- #~ msgid "Successfully updated role-specific URLs"
333
- #~ msgstr "URL-urile specifice rolurilor actualizate cu succes"
334
-
335
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
336
- #~ msgstr "EROARE: URL invalid sau extern trimis pentru nivel"
337
-
338
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
339
- #~ msgstr "EROARE: Eroare necunoscuta la actualizare URL pentru nivel"
340
-
341
- #~ msgid "Successfully updated level-specific URLs"
342
- #~ msgstr "Nivelele specifice URL-urilor actualizate cu succes"
343
-
344
- #~ msgid "Username"
345
- #~ msgstr "Username"
346
-
347
- #~ msgid "URL"
348
- #~ msgstr "URL"
349
-
350
- #~ msgid "Role"
351
- #~ msgstr "Rol"
352
-
353
- #~ msgid "Level"
354
- #~ msgstr "Nivel"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-ru_RU.mo DELETED
Binary file
languages/peters-login-redirect-ru_RU.po DELETED
@@ -1,345 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peters'login redirect\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:09-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Peter <peter@keung.biz>\n"
8
- "Language-Team: \n"
9
- "Language: ru_RU\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Poedit-SourceCharset: UTF-8\n"
19
- "X-Generator: Poedit 2.2.1\n"
20
- "X-Poedit-SearchPath-0: .\n"
21
-
22
- #: wplogin_redirect.php:580
23
- msgid "Register"
24
- msgstr "Регистрация"
25
-
26
- #: wplogin_redirect.php:584
27
- msgid "Site Admin"
28
- msgstr "Администратор"
29
-
30
- #: wplogin_redirect.php:706
31
- msgid "ERROR: Non-existent username submitted "
32
- msgstr "ОШИБКА: Имя пользователя не существует"
33
-
34
- #: wplogin_redirect.php:716
35
- msgid "ERROR: Non-existent role submitted "
36
- msgstr "ОШИБКА: Роль не существует"
37
-
38
- #: wplogin_redirect.php:727
39
- msgid "ERROR: Non-existent level submitted "
40
- msgstr "ОШИБКА: Уровень не существует"
41
-
42
- #: wplogin_redirect.php:744
43
- #, php-format
44
- msgid "ERROR: Empty %s submitted "
45
- msgstr "ОШИБКА: Пустое поле %s"
46
-
47
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
48
- #, php-format
49
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
50
- msgstr "ОШИБКА: Не внутренняя или не верная ссылка для %s %s"
51
-
52
- #: wplogin_redirect.php:802
53
- #, php-format
54
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
55
- msgstr "ОШИБКА: Редирект %s не был добавлен для %s %s"
56
-
57
- #: wplogin_redirect.php:809
58
- #, php-format
59
- msgid "Successfully added %s-specific redirect rule for %s"
60
- msgstr "Добавлен редирект %s для правила %s"
61
-
62
- #: wplogin_redirect.php:870
63
- #, php-format
64
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
65
- msgstr "ОШИБКА: Редирект %s не был изменён для %s %s"
66
-
67
- #: wplogin_redirect.php:877
68
- #, php-format
69
- msgid "Successfully edited %s-specific redirect rule for %s"
70
- msgstr "Изменён редирект %s для правила %s"
71
-
72
- #: wplogin_redirect.php:908
73
- #, php-format
74
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
75
- msgstr "ОШИБКА: Редирект %s не был удалён для %s %s"
76
-
77
- #: wplogin_redirect.php:914
78
- #, php-format
79
- msgid "Successfully deleted %s-specific redirect rule for %s"
80
- msgstr "Удалён редирект %s для правила %s"
81
-
82
- #: wplogin_redirect.php:952
83
- msgid ""
84
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
85
- msgstr ""
86
- "ОШИБКА: Проблема при удалении ссылки для &#34;всех остальных "
87
- "пользователей&#34;"
88
-
89
- #: wplogin_redirect.php:956
90
- msgid "Successfully removed URL for &#34;all other users&#34; "
91
- msgstr "Удалены ссылки &#34;для всех остальных пользователей&#34; "
92
-
93
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
94
- msgid "ERROR: Non-local or invalid URL submitted "
95
- msgstr "ОШИБКА: Не внутренняя или не верная ссылка"
96
-
97
- #: wplogin_redirect.php:980
98
- msgid ""
99
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
100
- msgstr ""
101
- "ОШИБКА: Проблема обновления ссылки для &#34;всех остальных пользователей&#34;"
102
-
103
- #: wplogin_redirect.php:984
104
- msgid "Successfully updated URL for &#34;all other users&#34;"
105
- msgstr "Обновлены ссылки &#34;для всех остальных пользователей&#34; "
106
-
107
- #: wplogin_redirect.php:1026
108
- msgid ""
109
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
110
- msgstr ""
111
- "ОШИБКА: Проблема при удалении ссылки для &#34;входа после регистрации&#34;"
112
-
113
- #: wplogin_redirect.php:1029
114
- msgid "Successfully removed URL for &#34;post-registration&#34; "
115
- msgstr "Удалены ссылки &#34;для входа после регистрации&#34; "
116
-
117
- #: wplogin_redirect.php:1052
118
- msgid ""
119
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
120
- msgstr ""
121
- "ОШИБКА: Проблема обновления ссылки для &#34;входа после регистрации&#34;"
122
-
123
- #: wplogin_redirect.php:1056
124
- msgid "Successfully updated URL for &#34;post-registration&#34;"
125
- msgstr "Обновлены ссылки &#34;для входа после регистрации&#34; "
126
-
127
- #: wplogin_redirect.php:1085
128
- msgid "Successfully updated plugin settings"
129
- msgstr "Настройки сохранены"
130
-
131
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
132
- #: wplogin_redirect.php:1275
133
- msgid "Login URL"
134
- msgstr "Ссылка входа"
135
-
136
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
137
- #: wplogin_redirect.php:1276
138
- msgid "Logout URL"
139
- msgstr "Ссылка выхода"
140
-
141
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
142
- #: wplogin_redirect.php:1280
143
- msgid "Edit"
144
- msgstr "Редактировать"
145
-
146
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
147
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
148
- #: wplogin_redirect.php:1411
149
- msgid "Delete"
150
- msgstr "Удалить"
151
-
152
- #: wplogin_redirect.php:1305
153
- msgid "Manage redirect rules"
154
- msgstr "Управление входом/выходом"
155
-
156
- #: wplogin_redirect.php:1307
157
- msgid ""
158
- "Define custom URLs to which different users, users with specific roles, "
159
- "users with specific levels, and all other users will be redirected upon "
160
- "login."
161
- msgstr ""
162
- "Установите ссылки по которым пользователи в соответствии с установленными "
163
- "правилами будут перенаправляться при входе в Панель управления."
164
-
165
- #: wplogin_redirect.php:1308
166
- msgid "Define a custom URL to which all users will be redirected upon logout"
167
- msgstr ""
168
- "Установите ссылку, по которой все пользователи будут перенаправляться при "
169
- "выходе из системы"
170
-
171
- #: wplogin_redirect.php:1309
172
- msgid ""
173
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
174
- "strong> in your URLs so that the system will build a dynamic URL upon each "
175
- "login, replacing that text with the users username."
176
- msgstr ""
177
- "Вы можете использовать синтаксис ссылки <strong>[variable]username[/"
178
- "variable]</strong>, таким образом система будет создавать динамическую "
179
- "ссылку после каждого входа, заменяя текст с именем пользователя."
180
-
181
- #: wplogin_redirect.php:1311
182
- msgid "Specific users"
183
- msgstr "Пользователи"
184
-
185
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
186
- #: wplogin_redirect.php:1380
187
- msgid "Add:"
188
- msgstr "Добавить:"
189
-
190
- #: wplogin_redirect.php:1324
191
- msgid "Select a username"
192
- msgstr "Выберите пользователя"
193
-
194
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
195
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
196
- #: wplogin_redirect.php:1409
197
- msgid "URL:"
198
- msgstr "Ссылка входа:"
199
-
200
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
201
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
202
- msgid "Logout URL:"
203
- msgstr "Ссылка выхода:"
204
-
205
- #: wplogin_redirect.php:1331
206
- msgid "Add username rule"
207
- msgstr "Добавить правило имени пользователя"
208
-
209
- #: wplogin_redirect.php:1336
210
- msgid "Specific roles"
211
- msgstr "Роли"
212
-
213
- #: wplogin_redirect.php:1349
214
- msgid "Select a role"
215
- msgstr "Выберите роль"
216
-
217
- #: wplogin_redirect.php:1356
218
- msgid "Add role rule"
219
- msgstr "Добавить правило роли"
220
-
221
- #: wplogin_redirect.php:1361
222
- msgid "Specific levels"
223
- msgstr "Уровни"
224
-
225
- #: wplogin_redirect.php:1370
226
- msgid "Order"
227
- msgstr "Порядок"
228
-
229
- #: wplogin_redirect.php:1382
230
- msgid "Select a level"
231
- msgstr "Выберите уровень"
232
-
233
- #: wplogin_redirect.php:1385
234
- msgid "Order:"
235
- msgstr "Порядок:"
236
-
237
- #: wplogin_redirect.php:1390
238
- msgid "Add level rule"
239
- msgstr "Добавить правило уровня"
240
-
241
- #: wplogin_redirect.php:1395
242
- msgid "All other users"
243
- msgstr "Все остальные пользователи"
244
-
245
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
246
- #: wplogin_redirect.php:1491
247
- msgid "Update"
248
- msgstr "Обновить"
249
-
250
- #: wplogin_redirect.php:1407
251
- msgid "Post-registration"
252
- msgstr "После регистрации"
253
-
254
- #: wplogin_redirect.php:1418
255
- msgid "Customize plugin settings"
256
- msgstr "Дополнительные настройки"
257
-
258
- #: wplogin_redirect.php:1423
259
- msgid "Redirect restrictions"
260
- msgstr "Ограничения перенаправления"
261
-
262
- #: wplogin_redirect.php:1427
263
- msgid "Any http or https URL"
264
- msgstr "Любая ссылка http или https"
265
-
266
- #: wplogin_redirect.php:1428
267
- msgid "Any URL"
268
- msgstr "Любая ссылка"
269
-
270
- #: wplogin_redirect.php:1429
271
- msgid "Any URL on the same domain"
272
- msgstr "Любая ссылка с того же домена"
273
-
274
- #: wplogin_redirect.php:1435
275
- msgid ""
276
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
277
- "precedence"
278
- msgstr ""
279
- "Запросы POST или GET в переменной &#34;redirect_to&#34; для задания "
280
- "приоритета входа"
281
-
282
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
283
- #: wplogin_redirect.php:1462
284
- msgid "Yes"
285
- msgstr "Да"
286
-
287
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
288
- #: wplogin_redirect.php:1463
289
- msgid "No"
290
- msgstr "Нет"
291
-
292
- #: wplogin_redirect.php:1446
293
- msgid ""
294
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
295
- "precedence"
296
- msgstr ""
297
- "Запросы POST или GET в переменной &#34;redirect_to&#34; для задания "
298
- "приоритета выхода"
299
-
300
- #: wplogin_redirect.php:1458
301
- #, php-format
302
- msgid ""
303
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
304
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
305
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
306
- "other plugin to %s"
307
- msgstr ""
308
- "Использовать для перенаправления внешний файл. Это может быть применимо, "
309
- "если вы используете плагин, который обходит стандартное перенаправление "
310
- "системы, например плагин Gigya. Допустима только одна ссылка "
311
- "перенаправления. В плагине установите следующую ссылку перенаправления: %s"
312
-
313
- #: wplogin_redirect.php:1469
314
- msgid "Permission level required to edit redirect URLs"
315
- msgstr "Право доступа, при котором разрешёно редактирование ссылок"
316
-
317
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
318
- #~ msgstr "EROARE: URL-ul trimis pentru rol este invalid sau nu este local"
319
-
320
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
321
- #~ msgstr "EROARE: Eroare necunoscuta la actualizarea URL-ului pentru rol"
322
-
323
- #~ msgid "Successfully updated role-specific URLs"
324
- #~ msgstr "URL-urile specifice rolurilor actualizate cu succes"
325
-
326
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
327
- #~ msgstr "EROARE: URL invalid sau extern trimis pentru nivel"
328
-
329
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
330
- #~ msgstr "EROARE: Eroare necunoscuta la actualizare URL pentru nivel"
331
-
332
- #~ msgid "Successfully updated level-specific URLs"
333
- #~ msgstr "Nivelele specifice URL-urilor actualizate cu succes"
334
-
335
- #~ msgid "Username"
336
- #~ msgstr "Username"
337
-
338
- #~ msgid "URL"
339
- #~ msgstr "URL"
340
-
341
- #~ msgid "Role"
342
- #~ msgstr "Rol"
343
-
344
- #~ msgid "Level"
345
- #~ msgstr "Nivel"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-sk_SK.mo DELETED
Binary file
languages/peters-login-redirect-sk_SK.po DELETED
@@ -1,346 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: peterloginrd\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:08-0800\n"
6
- "PO-Revision-Date: 2019-02-23 14:09-0800\n"
7
- "Last-Translator: Peter <peter@keung.biz>\n"
8
- "Language-Team: Moonpixel.com <info@moonpixel.com>\n"
9
- "Language: sk_SK\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "X-Poedit-KeywordsList: __;gettext;gettext_noop;_e\n"
14
- "X-Poedit-Basepath: .\n"
15
- "X-Generator: Poedit 2.2.1\n"
16
- "X-Poedit-SearchPath-0: .\n"
17
-
18
- #: wplogin_redirect.php:580
19
- msgid "Register"
20
- msgstr "Registrovať"
21
-
22
- #: wplogin_redirect.php:584
23
- msgid "Site Admin"
24
- msgstr "Administrátor"
25
-
26
- #: wplogin_redirect.php:706
27
- msgid "ERROR: Non-existent username submitted "
28
- msgstr "CHYBA: Zadané neplatné meno užívateľa"
29
-
30
- #: wplogin_redirect.php:716
31
- msgid "ERROR: Non-existent role submitted "
32
- msgstr "CHYBA: Zadané neplatné meno užívateľa"
33
-
34
- #: wplogin_redirect.php:727
35
- msgid "ERROR: Non-existent level submitted "
36
- msgstr "CHYBA: Zadaná neexistujúca úroveň"
37
-
38
- #: wplogin_redirect.php:744
39
- #, fuzzy, php-format
40
- msgid "ERROR: Empty %s submitted "
41
- msgstr "CHYBA: Zadané neplatné meno užívateľa"
42
-
43
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
44
- #, fuzzy, php-format
45
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
46
- msgstr "CHYBA: Zadané nelokálne alebo neplatné URL užívateľa"
47
-
48
- #: wplogin_redirect.php:802
49
- #, fuzzy, php-format
50
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
51
- msgstr "CHYBA: Nezistená chyba aktualizácie URL pre daného používateľa"
52
-
53
- #: wplogin_redirect.php:809
54
- #, fuzzy, php-format
55
- msgid "Successfully added %s-specific redirect rule for %s"
56
- msgstr "URL pre daného užívateľa bolo úspešne aktualizované"
57
-
58
- #: wplogin_redirect.php:870
59
- #, fuzzy, php-format
60
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
61
- msgstr "CHYBA: Nezistená chyba aktualizácie URL pre daného používateľa"
62
-
63
- #: wplogin_redirect.php:877
64
- #, fuzzy, php-format
65
- msgid "Successfully edited %s-specific redirect rule for %s"
66
- msgstr "URL pre daného užívateľa bolo úspešne aktualizované"
67
-
68
- #: wplogin_redirect.php:908
69
- #, fuzzy, php-format
70
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
71
- msgstr "CHYBA: Nezistená chyba aktualizácie URL pre daného používateľa"
72
-
73
- #: wplogin_redirect.php:914
74
- #, fuzzy, php-format
75
- msgid "Successfully deleted %s-specific redirect rule for %s"
76
- msgstr "URL pre daného užívateľa bolo úspešne aktualizované"
77
-
78
- #: wplogin_redirect.php:952
79
- msgid ""
80
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
81
- msgstr ""
82
- "CHYBA: Nezistená chyba databázy odstránenia URL pre &#34;všetkých ostatných "
83
- "používateľov&#34;"
84
-
85
- #: wplogin_redirect.php:956
86
- msgid "Successfully removed URL for &#34;all other users&#34; "
87
- msgstr "Úspešne odstránené URL pre &#34;všetkých ostatných používateľov&#34;"
88
-
89
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
90
- msgid "ERROR: Non-local or invalid URL submitted "
91
- msgstr "CHYBA: Zadané nelokálne alebo neplatné URL"
92
-
93
- #: wplogin_redirect.php:980
94
- msgid ""
95
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
96
- msgstr ""
97
- "CHYBA: Nezistená chyba databázy aktualizácie URL pre &#34;všetkých ostatných "
98
- "používateľov&#34;"
99
-
100
- #: wplogin_redirect.php:984
101
- msgid "Successfully updated URL for &#34;all other users&#34;"
102
- msgstr ""
103
- "Úspešne aktualizované URL pre &#34;všetkých ostatných používateľov&#34;"
104
-
105
- #: wplogin_redirect.php:1026
106
- #, fuzzy
107
- msgid ""
108
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
109
- msgstr ""
110
- "CHYBA: Nezistená chyba databázy odstránenia URL pre &#34;všetkých ostatných "
111
- "používateľov&#34;"
112
-
113
- #: wplogin_redirect.php:1029
114
- #, fuzzy
115
- msgid "Successfully removed URL for &#34;post-registration&#34; "
116
- msgstr "Úspešne odstránené URL pre &#34;všetkých ostatných používateľov&#34;"
117
-
118
- #: wplogin_redirect.php:1052
119
- #, fuzzy
120
- msgid ""
121
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
122
- msgstr ""
123
- "CHYBA: Nezistená chyba databázy aktualizácie URL pre &#34;všetkých ostatných "
124
- "používateľov&#34;"
125
-
126
- #: wplogin_redirect.php:1056
127
- #, fuzzy
128
- msgid "Successfully updated URL for &#34;post-registration&#34;"
129
- msgstr ""
130
- "Úspešne aktualizované URL pre &#34;všetkých ostatných používateľov&#34;"
131
-
132
- #: wplogin_redirect.php:1085
133
- #, fuzzy
134
- msgid "Successfully updated plugin settings"
135
- msgstr "URL pre daného užívateľa bolo úspešne aktualizované"
136
-
137
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
138
- #: wplogin_redirect.php:1275
139
- #, fuzzy
140
- msgid "Login URL"
141
- msgstr "URL"
142
-
143
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
144
- #: wplogin_redirect.php:1276
145
- msgid "Logout URL"
146
- msgstr ""
147
-
148
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
149
- #: wplogin_redirect.php:1280
150
- msgid "Edit"
151
- msgstr ""
152
-
153
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
154
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
155
- #: wplogin_redirect.php:1411
156
- msgid "Delete"
157
- msgstr "Odstrániť"
158
-
159
- #: wplogin_redirect.php:1305
160
- #, fuzzy
161
- msgid "Manage redirect rules"
162
- msgstr "Správa pravidiel pre presmerovanie po prihlásení"
163
-
164
- #: wplogin_redirect.php:1307
165
- #, fuzzy
166
- msgid ""
167
- "Define custom URLs to which different users, users with specific roles, "
168
- "users with specific levels, and all other users will be redirected upon "
169
- "login."
170
- msgstr ""
171
- "Definovať rôzne lokálne URL na ktoré rôzny užívatelia, užívatelia s "
172
- "konkrétnymi rolami, užívatelia s konkrétnymi úrovňami a všetci ostatní "
173
- "užívatelia budú presmerovaní."
174
-
175
- #: wplogin_redirect.php:1308
176
- msgid "Define a custom URL to which all users will be redirected upon logout"
177
- msgstr ""
178
-
179
- #: wplogin_redirect.php:1309
180
- msgid ""
181
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
182
- "strong> in your URLs so that the system will build a dynamic URL upon each "
183
- "login, replacing that text with the users username."
184
- msgstr ""
185
- "Poznámka: je možné používať syntax <strong>[variable]username[/variable]</"
186
- "strong> v URL. Systém vytvorí dynamické URL po každom prihlásení, nahraďujúc "
187
- "tento text užívateľským menom."
188
-
189
- #: wplogin_redirect.php:1311
190
- msgid "Specific users"
191
- msgstr "Konkrétni užívatelia"
192
-
193
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
194
- #: wplogin_redirect.php:1380
195
- msgid "Add:"
196
- msgstr "Pridať:"
197
-
198
- #: wplogin_redirect.php:1324
199
- msgid "Select a username"
200
- msgstr "Vybrať užívateľské meno"
201
-
202
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
203
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
204
- #: wplogin_redirect.php:1409
205
- msgid "URL:"
206
- msgstr "URL:"
207
-
208
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
209
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
210
- msgid "Logout URL:"
211
- msgstr ""
212
-
213
- #: wplogin_redirect.php:1331
214
- msgid "Add username rule"
215
- msgstr ""
216
-
217
- #: wplogin_redirect.php:1336
218
- msgid "Specific roles"
219
- msgstr "Konkrétne role"
220
-
221
- #: wplogin_redirect.php:1349
222
- msgid "Select a role"
223
- msgstr "Vybrať rolu"
224
-
225
- #: wplogin_redirect.php:1356
226
- msgid "Add role rule"
227
- msgstr ""
228
-
229
- #: wplogin_redirect.php:1361
230
- msgid "Specific levels"
231
- msgstr "Konkrétne úrovne"
232
-
233
- #: wplogin_redirect.php:1370
234
- msgid "Order"
235
- msgstr "Príkaz"
236
-
237
- #: wplogin_redirect.php:1382
238
- msgid "Select a level"
239
- msgstr "Vybrať úroveň"
240
-
241
- #: wplogin_redirect.php:1385
242
- msgid "Order:"
243
- msgstr "Príkaz:"
244
-
245
- #: wplogin_redirect.php:1390
246
- msgid "Add level rule"
247
- msgstr ""
248
-
249
- #: wplogin_redirect.php:1395
250
- msgid "All other users"
251
- msgstr "Všetci ostatní užívatelia"
252
-
253
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
254
- #: wplogin_redirect.php:1491
255
- msgid "Update"
256
- msgstr "Aktualizácia\""
257
-
258
- #: wplogin_redirect.php:1407
259
- msgid "Post-registration"
260
- msgstr ""
261
-
262
- #: wplogin_redirect.php:1418
263
- msgid "Customize plugin settings"
264
- msgstr ""
265
-
266
- #: wplogin_redirect.php:1423
267
- msgid "Redirect restrictions"
268
- msgstr ""
269
-
270
- #: wplogin_redirect.php:1427
271
- msgid "Any http or https URL"
272
- msgstr ""
273
-
274
- #: wplogin_redirect.php:1428
275
- #, fuzzy
276
- msgid "Any URL"
277
- msgstr "URL"
278
-
279
- #: wplogin_redirect.php:1429
280
- msgid "Any URL on the same domain"
281
- msgstr ""
282
-
283
- #: wplogin_redirect.php:1435
284
- msgid ""
285
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
286
- "precedence"
287
- msgstr ""
288
-
289
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
290
- #: wplogin_redirect.php:1462
291
- msgid "Yes"
292
- msgstr ""
293
-
294
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
295
- #: wplogin_redirect.php:1463
296
- msgid "No"
297
- msgstr ""
298
-
299
- #: wplogin_redirect.php:1446
300
- msgid ""
301
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
302
- "precedence"
303
- msgstr ""
304
-
305
- #: wplogin_redirect.php:1458
306
- #, php-format
307
- msgid ""
308
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
309
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
310
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
311
- "other plugin to %s"
312
- msgstr ""
313
-
314
- #: wplogin_redirect.php:1469
315
- msgid "Permission level required to edit redirect URLs"
316
- msgstr ""
317
-
318
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
319
- #~ msgstr "CHYBA: Zadané nelokálne alebo neplatné URL pre danú rolu"
320
-
321
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
322
- #~ msgstr "CHYBA: Zadané nelokálne alebo neplatné URL pre pre danú rolu"
323
-
324
- #~ msgid "Successfully updated role-specific URLs"
325
- #~ msgstr "URL pre danú rolu bolo úspešne aktualizované"
326
-
327
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
328
- #~ msgstr "CHYBA: Zadané nelokálne alebo neplatné URL pre danú úroveň"
329
-
330
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
331
- #~ msgstr "CHYBA: Nezistená chyba aktualizácie URL pre danú úroveň"
332
-
333
- #~ msgid "Successfully updated level-specific URLs"
334
- #~ msgstr "URL pre dané úrovne úspešne aktualizované"
335
-
336
- #~ msgid "Username"
337
- #~ msgstr "Užívateľské meno"
338
-
339
- #~ msgid "URL"
340
- #~ msgstr "URL"
341
-
342
- #~ msgid "Role"
343
- #~ msgstr "Rola"
344
-
345
- #~ msgid "Level"
346
- #~ msgstr "Úroveň"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-sr_RS.mo DELETED
Binary file
languages/peters-login-redirect-sr_RS.po DELETED
@@ -1,368 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peters'login redirect v2.0.0\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:08-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Borisa Djuraskovic <borisad@webhostinghub.com>\n"
8
- "Language-Team: jibo.ro <contact@jibo.ro>\n"
9
- "Language: ro_RO\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Poedit-SourceCharset: utf-8\n"
19
- "X-Generator: Poedit 2.2.1\n"
20
- "X-Poedit-SearchPath-0: .\n"
21
-
22
- #: wplogin_redirect.php:580
23
- msgid "Register"
24
- msgstr "Registruj"
25
-
26
- #: wplogin_redirect.php:584
27
- msgid "Site Admin"
28
- msgstr "Admin sajta"
29
-
30
- #: wplogin_redirect.php:706
31
- msgid "ERROR: Non-existent username submitted "
32
- msgstr "GREŠKA: Nepostojeće korisničko ime podnešeno"
33
-
34
- #: wplogin_redirect.php:716
35
- msgid "ERROR: Non-existent role submitted "
36
- msgstr "GREŠKA: Nepostojeća uloga podnešena"
37
-
38
- #: wplogin_redirect.php:727
39
- msgid "ERROR: Non-existent level submitted "
40
- msgstr "GREŠKA: Nepostojeći nivo podnešen"
41
-
42
- #: wplogin_redirect.php:744
43
- #, fuzzy, php-format
44
- msgid "ERROR: Empty %s submitted "
45
- msgstr "GREŠKA: Nepostojeća uloga podnešena"
46
-
47
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
48
- #, fuzzy, php-format
49
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
50
- msgstr "GREŠKA: Non-local ili nepostojeći URL podnešen za korisnike"
51
-
52
- #: wplogin_redirect.php:802
53
- #, fuzzy, php-format
54
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
55
- msgstr ""
56
- "GREŠKA: Nepoznata greška prilikom updatinga URL odredjenog posebno za "
57
- "korisnike"
58
-
59
- #: wplogin_redirect.php:809
60
- #, fuzzy, php-format
61
- msgid "Successfully added %s-specific redirect rule for %s"
62
- msgstr "Uspešnon updateovani URLovi odredjeni za korisnike"
63
-
64
- #: wplogin_redirect.php:870
65
- #, fuzzy, php-format
66
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
67
- msgstr ""
68
- "GREŠKA: Nepoznata greška prilikom updatinga URL odredjenog posebno za "
69
- "korisnike"
70
-
71
- #: wplogin_redirect.php:877
72
- #, fuzzy, php-format
73
- msgid "Successfully edited %s-specific redirect rule for %s"
74
- msgstr "Uspešnon updateovani URLovi odredjeni za korisnike"
75
-
76
- #: wplogin_redirect.php:908
77
- #, fuzzy, php-format
78
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
79
- msgstr ""
80
- "GREŠKA: Nepoznata greška prilikom updatinga URL odredjenog posebno za "
81
- "korisnike"
82
-
83
- #: wplogin_redirect.php:914
84
- #, fuzzy, php-format
85
- msgid "Successfully deleted %s-specific redirect rule for %s"
86
- msgstr "Uspešnon updateovani URLovi odredjeni za korisnike"
87
-
88
- #: wplogin_redirect.php:952
89
- msgid ""
90
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
91
- msgstr ""
92
- "GREŠKA: Nepoznati problem baze podataka uklanjanjem URLa za &#34;svi ostali "
93
- "korisnici&#34;"
94
-
95
- #: wplogin_redirect.php:956
96
- msgid "Successfully removed URL for &#34;all other users&#34; "
97
- msgstr "Uspešno uklonjen URL za &#34;svi ostali korisnici&#34;"
98
-
99
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
100
- msgid "ERROR: Non-local or invalid URL submitted "
101
- msgstr "GREŠKA: Non-local ili nedostupan URL podnet"
102
-
103
- #: wplogin_redirect.php:980
104
- msgid ""
105
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
106
- msgstr ""
107
- "GREŠKA:Unknown database problem updating URL for &#34;svi ostali "
108
- "korisnici&#34;"
109
-
110
- #: wplogin_redirect.php:984
111
- msgid "Successfully updated URL for &#34;all other users&#34;"
112
- msgstr "Uspešno uklonje URL za &#34;svi ostali korisnici&#34;"
113
-
114
- #: wplogin_redirect.php:1026
115
- #, fuzzy
116
- msgid ""
117
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
118
- msgstr ""
119
- "EROARE: Eroare de baza de date necunoscuta la inlaturarea URL-urilor pentru "
120
- "&#34;toti utilizatorii&#34; "
121
-
122
- #: wplogin_redirect.php:1029
123
- #, fuzzy
124
- msgid "Successfully removed URL for &#34;post-registration&#34; "
125
- msgstr "S-a inlaturat cu succes URL-ul pentru &#34;toti utilizatorii&#34; "
126
-
127
- #: wplogin_redirect.php:1052
128
- #, fuzzy
129
- msgid ""
130
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
131
- msgstr ""
132
- "EROARE: Problema necunoscuta la actualizarea URL-ului in baza de date pentru "
133
- "&#34;toti utilizatorii&#34; "
134
-
135
- #: wplogin_redirect.php:1056
136
- #, fuzzy
137
- msgid "Successfully updated URL for &#34;post-registration&#34;"
138
- msgstr "URL actualizat cu succes pentru &#34;toti ceilalti utilizatori&#34;"
139
-
140
- #: wplogin_redirect.php:1085
141
- #, fuzzy
142
- msgid "Successfully updated plugin settings"
143
- msgstr "URL-urile specifice utilizatorilor actualizate cu succes"
144
-
145
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
146
- #: wplogin_redirect.php:1275
147
- #, fuzzy
148
- msgid "Login URL"
149
- msgstr "Logout URL"
150
-
151
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
152
- #: wplogin_redirect.php:1276
153
- msgid "Logout URL"
154
- msgstr "Logout URL"
155
-
156
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
157
- #: wplogin_redirect.php:1280
158
- msgid "Edit"
159
- msgstr ""
160
-
161
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
162
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
163
- #: wplogin_redirect.php:1411
164
- msgid "Delete"
165
- msgstr "Obrisati"
166
-
167
- #: wplogin_redirect.php:1305
168
- #, fuzzy
169
- msgid "Manage redirect rules"
170
- msgstr "Modifica regulile de redirectionare a autentificarii"
171
-
172
- #: wplogin_redirect.php:1307
173
- #, fuzzy
174
- msgid ""
175
- "Define custom URLs to which different users, users with specific roles, "
176
- "users with specific levels, and all other users will be redirected upon "
177
- "login."
178
- msgstr ""
179
- "Specifica URL-uri locale diferite pentru care utilizatorii diferiti, "
180
- "utilizatorii cu roluri specifice, utilizatorii cu nivele specifice si toti "
181
- "ceilalti utilizatori vor fi redirectionati."
182
-
183
- #: wplogin_redirect.php:1308
184
- msgid "Define a custom URL to which all users will be redirected upon logout"
185
- msgstr ""
186
- "Definisati custom URLove za različite korisnike, korisnike sa odredjenim "
187
- "ulogama, korisdnike sa odredjenim nivoima, i sve ostale korisniuke koji će "
188
- "biti redirectovani prilikom login-a."
189
-
190
- #: wplogin_redirect.php:1309
191
- msgid ""
192
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
193
- "strong> in your URLs so that the system will build a dynamic URL upon each "
194
- "login, replacing that text with the users username."
195
- msgstr ""
196
- "Imajte na umu da možete da koristite sintaksu <strong>[variable]username[/"
197
- "variable]</strong> u URL adresama , tako da će sistem izgraditi dinamički "
198
- "URL na svakom prijavljivanju, zamenjujući taj tekst sa korisničkim imenom "
199
- "korisnika ."
200
-
201
- #: wplogin_redirect.php:1311
202
- msgid "Specific users"
203
- msgstr "Odredjeni korisnici"
204
-
205
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
206
- #: wplogin_redirect.php:1380
207
- msgid "Add:"
208
- msgstr "Dodati:"
209
-
210
- #: wplogin_redirect.php:1324
211
- msgid "Select a username"
212
- msgstr "Izabrati korisničko ime"
213
-
214
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
215
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
216
- #: wplogin_redirect.php:1409
217
- msgid "URL:"
218
- msgstr "URL:"
219
-
220
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
221
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
222
- msgid "Logout URL:"
223
- msgstr "Logout URL:"
224
-
225
- #: wplogin_redirect.php:1331
226
- msgid "Add username rule"
227
- msgstr ""
228
-
229
- #: wplogin_redirect.php:1336
230
- msgid "Specific roles"
231
- msgstr "Odredjene uloge"
232
-
233
- #: wplogin_redirect.php:1349
234
- msgid "Select a role"
235
- msgstr "Izabrati ulogu"
236
-
237
- #: wplogin_redirect.php:1356
238
- msgid "Add role rule"
239
- msgstr ""
240
-
241
- #: wplogin_redirect.php:1361
242
- msgid "Specific levels"
243
- msgstr "Odredjeni nivoi"
244
-
245
- #: wplogin_redirect.php:1370
246
- msgid "Order"
247
- msgstr "Naručiti"
248
-
249
- #: wplogin_redirect.php:1382
250
- msgid "Select a level"
251
- msgstr "Izabrati nivo"
252
-
253
- #: wplogin_redirect.php:1385
254
- msgid "Order:"
255
- msgstr "Naručiti:"
256
-
257
- #: wplogin_redirect.php:1390
258
- msgid "Add level rule"
259
- msgstr ""
260
-
261
- #: wplogin_redirect.php:1395
262
- msgid "All other users"
263
- msgstr "Svi ostali korisnici"
264
-
265
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
266
- #: wplogin_redirect.php:1491
267
- msgid "Update"
268
- msgstr "Update-uj"
269
-
270
- #: wplogin_redirect.php:1407
271
- msgid "Post-registration"
272
- msgstr "Obrisati"
273
-
274
- #: wplogin_redirect.php:1418
275
- msgid "Customize plugin settings"
276
- msgstr "Customize plugin postavke"
277
-
278
- #: wplogin_redirect.php:1423
279
- msgid "Redirect restrictions"
280
- msgstr "Redirektuj restrikcije"
281
-
282
- #: wplogin_redirect.php:1427
283
- msgid "Any http or https URL"
284
- msgstr "Bilo koji http ili https URL"
285
-
286
- #: wplogin_redirect.php:1428
287
- #, fuzzy
288
- msgid "Any URL"
289
- msgstr "URL"
290
-
291
- #: wplogin_redirect.php:1429
292
- msgid "Any URL on the same domain"
293
- msgstr "Bilo koji URL"
294
-
295
- #: wplogin_redirect.php:1435
296
- msgid ""
297
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
298
- "precedence"
299
- msgstr ""
300
- "Dozvoli POST ili GET &#34;redirect_to&#34; varijable da bi redirektovale "
301
- "prisustvo"
302
-
303
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
304
- #: wplogin_redirect.php:1462
305
- msgid "Yes"
306
- msgstr "Da"
307
-
308
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
309
- #: wplogin_redirect.php:1463
310
- msgid "No"
311
- msgstr "Ne"
312
-
313
- #: wplogin_redirect.php:1446
314
- msgid ""
315
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
316
- "precedence"
317
- msgstr ""
318
- "Dozvoli POST ili GET &#34;redirect_to&#34; logout varijable da bi "
319
- "redirektovale prisustvo"
320
-
321
- #: wplogin_redirect.php:1458
322
- #, fuzzy, php-format
323
- msgid ""
324
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
325
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
326
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
327
- "other plugin to %s"
328
- msgstr ""
329
- "Kristite external redirekovani fajl. Podesite ovo na &#34;Yes&#34; ako "
330
- "koristite plugin kao što je Gigya koji prelazi regularni WordPress "
331
- "redirektovani proces (i samo dozvoljava namešteni redirektovani URL). Zatim, "
332
- "namesti redirekt URL na %s"
333
-
334
- #: wplogin_redirect.php:1469
335
- msgid "Permission level required to edit redirect URLs"
336
- msgstr "Nivo sa dozvolom je potrebno za editovanje redirektovanje URLs"
337
-
338
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
339
- #~ msgstr "GREŠKA: Non-local URL podnešen za ulogu"
340
-
341
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
342
- #~ msgstr "GREŠKA: Nepoznata greška prilikom URL for role"
343
-
344
- #~ msgid "Successfully updated role-specific URLs"
345
- #~ msgstr "Uspešno updateovani URLovi"
346
-
347
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
348
- #~ msgstr "GREŠKA: Non-local ili nepostojeći URL podnešen za nivo"
349
-
350
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
351
- #~ msgstr ""
352
- #~ "GREŠKA: Nepoznata greška prilikom updateovana URLa odredjenog nivovm za "
353
- #~ "nivo "
354
-
355
- #~ msgid "Successfully updated level-specific URLs"
356
- #~ msgstr "Uspešno updateovani URLovi odredjeni nivoom "
357
-
358
- #~ msgid "Username"
359
- #~ msgstr "Korisničko ime"
360
-
361
- #~ msgid "URL"
362
- #~ msgstr "URL"
363
-
364
- #~ msgid "Role"
365
- #~ msgstr "Uloga"
366
-
367
- #~ msgid "Level"
368
- #~ msgstr "Nivo"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect-uk.mo DELETED
Binary file
languages/peters-login-redirect-uk.po DELETED
@@ -1,369 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peter's Login Redirect\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:08-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Iurii <yurqua@gmail.com>\n"
8
- "Language-Team: theblog.ca\n"
9
- "Language: uk\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
14
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
15
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
16
- "esc_attr__\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Generator: Poedit 2.2.1\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
-
21
- #: wplogin_redirect.php:580
22
- #, fuzzy
23
- msgid "Register"
24
- msgstr "Зареєструватись"
25
-
26
- #: wplogin_redirect.php:584
27
- msgid "Site Admin"
28
- msgstr "Адміністратор сайта"
29
-
30
- #: wplogin_redirect.php:706
31
- msgid "ERROR: Non-existent username submitted "
32
- msgstr "ПОМИЛКА: надано неіснуюче ім’я користувача"
33
-
34
- #: wplogin_redirect.php:716
35
- msgid "ERROR: Non-existent role submitted "
36
- msgstr "ПОМИЛКА: зазначено неіснуючу роль користувача"
37
-
38
- #: wplogin_redirect.php:727
39
- msgid "ERROR: Non-existent level submitted "
40
- msgstr "ПОМИЛКА: зазначено неіснуючий рівень прав доступу"
41
-
42
- #: wplogin_redirect.php:744
43
- #, fuzzy, php-format
44
- msgid "ERROR: Empty %s submitted "
45
- msgstr "ПОМИЛКА: зазначено неіснуючу роль користувача"
46
-
47
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
48
- #, fuzzy, php-format
49
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
50
- msgstr ""
51
- "ПОМИЛКА: під час налаштування перенаправлення за користувачем, введено "
52
- "хибний або не локальний URL"
53
-
54
- #: wplogin_redirect.php:802
55
- #, fuzzy, php-format
56
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
57
- msgstr ""
58
- "ПОМИЛКА: невідома помилка встановлення URL перенаправлення за користувачем"
59
-
60
- #: wplogin_redirect.php:809
61
- #, fuzzy, php-format
62
- msgid "Successfully added %s-specific redirect rule for %s"
63
- msgstr "URL перенаправлень за користувачами успішно оновлено"
64
-
65
- #: wplogin_redirect.php:870
66
- #, fuzzy, php-format
67
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
68
- msgstr ""
69
- "ПОМИЛКА: невідома помилка встановлення URL перенаправлення за користувачем"
70
-
71
- #: wplogin_redirect.php:877
72
- #, fuzzy, php-format
73
- msgid "Successfully edited %s-specific redirect rule for %s"
74
- msgstr "URL перенаправлень за користувачами успішно оновлено"
75
-
76
- #: wplogin_redirect.php:908
77
- #, fuzzy, php-format
78
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
79
- msgstr ""
80
- "ПОМИЛКА: невідома помилка встановлення URL перенаправлення за користувачем"
81
-
82
- #: wplogin_redirect.php:914
83
- #, fuzzy, php-format
84
- msgid "Successfully deleted %s-specific redirect rule for %s"
85
- msgstr "URL перенаправлень за користувачами успішно оновлено"
86
-
87
- #: wplogin_redirect.php:952
88
- msgid ""
89
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
90
- msgstr ""
91
- "ПОМИЛКА: невідома помилка бази даних під час видалення URL перенаправлення "
92
- "для «решти користувачів»"
93
-
94
- #: wplogin_redirect.php:956
95
- msgid "Successfully removed URL for &#34;all other users&#34; "
96
- msgstr "URL перенаправлення для «решти користувачів» успішно видалено"
97
-
98
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
99
- msgid "ERROR: Non-local or invalid URL submitted "
100
- msgstr "ПОМИЛКА: введено хибний або не локальний URL"
101
-
102
- #: wplogin_redirect.php:980
103
- msgid ""
104
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
105
- msgstr ""
106
- "ПОМИЛКА: невідома помилка бази даних під час оновлення URL перенаправлення "
107
- "для «решти користувачів»"
108
-
109
- #: wplogin_redirect.php:984
110
- msgid "Successfully updated URL for &#34;all other users&#34;"
111
- msgstr "URL перенаправлення для «решти користувачів» успішно оновлено"
112
-
113
- #: wplogin_redirect.php:1026
114
- msgid ""
115
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
116
- msgstr ""
117
- "ПОМИЛКА: невідома помилка бази даних під час видалення URL перенаправлення "
118
- "для «сторінки, що з’являється після реєстрації»"
119
-
120
- #: wplogin_redirect.php:1029
121
- msgid "Successfully removed URL for &#34;post-registration&#34; "
122
- msgstr ""
123
- "URL перенаправлення для «сторінки, що з’являється після реєстрації» успішно "
124
- "видалено"
125
-
126
- #: wplogin_redirect.php:1052
127
- msgid ""
128
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
129
- msgstr ""
130
- "ПОМИЛКА: невідома помилка бази даних під час оновлення URL перенаправлення "
131
- "для «сторінки, що з’являється після реєстрації»"
132
-
133
- #: wplogin_redirect.php:1056
134
- msgid "Successfully updated URL for &#34;post-registration&#34;"
135
- msgstr ""
136
- "URL перенаправлення для «сторінки, що з’являється після реєстрації» успішно "
137
- "оновлено"
138
-
139
- #: wplogin_redirect.php:1085
140
- msgid "Successfully updated plugin settings"
141
- msgstr "Налаштування плаґіну успішно оновлено"
142
-
143
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
144
- #: wplogin_redirect.php:1275
145
- #, fuzzy
146
- msgid "Login URL"
147
- msgstr "URL виходу:"
148
-
149
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
150
- #: wplogin_redirect.php:1276
151
- #, fuzzy
152
- msgid "Logout URL"
153
- msgstr "URL виходу:"
154
-
155
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
156
- #: wplogin_redirect.php:1280
157
- msgid "Edit"
158
- msgstr ""
159
-
160
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
161
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
162
- #: wplogin_redirect.php:1411
163
- msgid "Delete"
164
- msgstr "Видалити"
165
-
166
- #: wplogin_redirect.php:1305
167
- msgid "Manage redirect rules"
168
- msgstr "Керування правилами перенаправлення"
169
-
170
- #: wplogin_redirect.php:1307
171
- msgid ""
172
- "Define custom URLs to which different users, users with specific roles, "
173
- "users with specific levels, and all other users will be redirected upon "
174
- "login."
175
- msgstr ""
176
- "Вкажіть власні URL, на які після входу буде перенаправлено тих чи інших "
177
- "користувачів: користувачів із визначеними ролями, правами доступу, та решту "
178
- "всіх користувачів."
179
-
180
- #: wplogin_redirect.php:1308
181
- msgid "Define a custom URL to which all users will be redirected upon logout"
182
- msgstr ""
183
- "Вкажіть власний URL, на який після виходу буде перенаправлено усіх "
184
- "користувачів"
185
-
186
- #: wplogin_redirect.php:1309
187
- msgid ""
188
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
189
- "strong> in your URLs so that the system will build a dynamic URL upon each "
190
- "login, replacing that text with the users username."
191
- msgstr ""
192
- "Зауважте, що у вказуваних вами URL ви можете використовувати синтаксис "
193
- "<strong>[variable]username[/variable]</strong>. Це дозволить системі під час "
194
- "кожного входу створювати динамічні URL, на льоту заміняючи такий код на "
195
- "лоґіни користувачів."
196
-
197
- #: wplogin_redirect.php:1311
198
- msgid "Specific users"
199
- msgstr "Визначені користувачі"
200
-
201
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
202
- #: wplogin_redirect.php:1380
203
- msgid "Add:"
204
- msgstr "Додати:"
205
-
206
- #: wplogin_redirect.php:1324
207
- msgid "Select a username"
208
- msgstr "Оберіть користувача"
209
-
210
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
211
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
212
- #: wplogin_redirect.php:1409
213
- msgid "URL:"
214
- msgstr "URL:"
215
-
216
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
217
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
218
- msgid "Logout URL:"
219
- msgstr "URL виходу:"
220
-
221
- #: wplogin_redirect.php:1331
222
- msgid "Add username rule"
223
- msgstr ""
224
-
225
- #: wplogin_redirect.php:1336
226
- msgid "Specific roles"
227
- msgstr "Визначені ролі користувачів"
228
-
229
- #: wplogin_redirect.php:1349
230
- msgid "Select a role"
231
- msgstr "Оберіть роль користувача"
232
-
233
- #: wplogin_redirect.php:1356
234
- msgid "Add role rule"
235
- msgstr ""
236
-
237
- #: wplogin_redirect.php:1361
238
- msgid "Specific levels"
239
- msgstr "Визначені рівні доступу"
240
-
241
- #: wplogin_redirect.php:1370
242
- msgid "Order"
243
- msgstr "Порядок"
244
-
245
- #: wplogin_redirect.php:1382
246
- msgid "Select a level"
247
- msgstr "Оберіть права доступу"
248
-
249
- #: wplogin_redirect.php:1385
250
- msgid "Order:"
251
- msgstr "Порядок:"
252
-
253
- #: wplogin_redirect.php:1390
254
- msgid "Add level rule"
255
- msgstr ""
256
-
257
- #: wplogin_redirect.php:1395
258
- msgid "All other users"
259
- msgstr "Решта користувачів"
260
-
261
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
262
- #: wplogin_redirect.php:1491
263
- msgid "Update"
264
- msgstr "Оновити"
265
-
266
- #: wplogin_redirect.php:1407
267
- msgid "Post-registration"
268
- msgstr "Сторінка, що з’являється після реєстрації"
269
-
270
- #: wplogin_redirect.php:1418
271
- msgid "Customize plugin settings"
272
- msgstr "Змінити налаштування плаґіну"
273
-
274
- #: wplogin_redirect.php:1423
275
- msgid "Redirect restrictions"
276
- msgstr "Обмеження перенаправлення"
277
-
278
- #: wplogin_redirect.php:1427
279
- msgid "Any http or https URL"
280
- msgstr "Будь-який http чи https URL"
281
-
282
- #: wplogin_redirect.php:1428
283
- msgid "Any URL"
284
- msgstr "Будь-який URL"
285
-
286
- #: wplogin_redirect.php:1429
287
- msgid "Any URL on the same domain"
288
- msgstr "Будь-який URL на тому ж домені"
289
-
290
- #: wplogin_redirect.php:1435
291
- msgid ""
292
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
293
- "precedence"
294
- msgstr ""
295
- "Віддавати POST чи GET змінній &#34;redirect_to&#34; право першочергової "
296
- "обробки перенаправлення"
297
-
298
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
299
- #: wplogin_redirect.php:1462
300
- msgid "Yes"
301
- msgstr "Так"
302
-
303
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
304
- #: wplogin_redirect.php:1463
305
- msgid "No"
306
- msgstr "Ні"
307
-
308
- #: wplogin_redirect.php:1446
309
- msgid ""
310
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
311
- "precedence"
312
- msgstr ""
313
- "Віддавати POST чи GET змінній виходу &#34;redirect_to&#34; право "
314
- "першочергової обробки перенаправлення"
315
-
316
- #: wplogin_redirect.php:1458
317
- #, fuzzy, php-format
318
- msgid ""
319
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
320
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
321
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
322
- "other plugin to %s"
323
- msgstr ""
324
- "Використовувати зовнішній файл перенаправлень. Вкажіть «Так», якщо ви "
325
- "використовуєте плаґіни на кшталт Gigya, які обходять звичайний процес "
326
- "перенаправлень WordPress і встановлюють лише один фіксований URL "
327
- "перенаправлення. У такому разі, встановіть перенаправлення на %s"
328
-
329
- #: wplogin_redirect.php:1469
330
- msgid "Permission level required to edit redirect URLs"
331
- msgstr "Права доступу, необхідні для зміни URL перенаправлень"
332
-
333
- #~ msgid "ERROR: Non-local or invalid URL submitted for role "
334
- #~ msgstr ""
335
- #~ "ПОМИЛКА: під час налаштування перенаправлення за роллю, введено хибний "
336
- #~ "або не локальний URL"
337
-
338
- #~ msgid "ERROR: Unknown error updating role-specific URL for role "
339
- #~ msgstr ""
340
- #~ "ПОМИЛКА: невідома помилка встановлення URL перенаправлення за роллю "
341
- #~ "користувача"
342
-
343
- #~ msgid "Successfully updated role-specific URLs"
344
- #~ msgstr "URL перенаправлень за ролями користувачів успішно оновлено"
345
-
346
- #~ msgid "ERROR: Non-local or invalid URL submitted for level "
347
- #~ msgstr ""
348
- #~ "ПОМИЛКА: під час налаштування перенаправлення за правами доступу, введено "
349
- #~ "хибний або не локальний URL"
350
-
351
- #~ msgid "ERROR: Unknown error updating level-specific URL for level "
352
- #~ msgstr ""
353
- #~ "ПОМИЛКА: невідома помилка встановлення URL перенаправлення за правами "
354
- #~ "доступу користувача"
355
-
356
- #~ msgid "Successfully updated level-specific URLs"
357
- #~ msgstr "URL перенаправлень за правами доступу успішно оновлено"
358
-
359
- #~ msgid "Username"
360
- #~ msgstr "Лоґін"
361
-
362
- #~ msgid "URL"
363
- #~ msgstr "URL"
364
-
365
- #~ msgid "Role"
366
- #~ msgstr "Роль"
367
-
368
- #~ msgid "Level"
369
- #~ msgstr "Рівень доступу"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect.mo DELETED
Binary file
languages/peters-login-redirect.po DELETED
@@ -1,293 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Peter's Login Redirect\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2019-02-23 14:16-0800\n"
6
- "PO-Revision-Date: \n"
7
- "Last-Translator: Peter <peter@keung.biz>\n"
8
- "Language-Team: theblog.ca\n"
9
- "MIME-Version: 1.0\n"
10
- "Content-Type: text/plain; charset=UTF-8\n"
11
- "Content-Transfer-Encoding: 8bit\n"
12
- "Plural-Forms: nplurals=2; plural=(n != 1);\n"
13
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
14
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;esc_attr_e;"
15
- "esc_attr__\n"
16
- "X-Poedit-Basepath: .\n"
17
- "X-Generator: Poedit 2.2.1\n"
18
- "X-Poedit-SearchPath-0: .\n"
19
-
20
- #: wplogin_redirect.php:580
21
- msgid "Register"
22
- msgstr ""
23
-
24
- #: wplogin_redirect.php:584
25
- msgid "Site Admin"
26
- msgstr ""
27
-
28
- #: wplogin_redirect.php:706
29
- msgid "ERROR: Non-existent username submitted "
30
- msgstr ""
31
-
32
- #: wplogin_redirect.php:716
33
- msgid "ERROR: Non-existent role submitted "
34
- msgstr ""
35
-
36
- #: wplogin_redirect.php:727
37
- msgid "ERROR: Non-existent level submitted "
38
- msgstr ""
39
-
40
- #: wplogin_redirect.php:744
41
- #, php-format
42
- msgid "ERROR: Empty %s submitted "
43
- msgstr ""
44
-
45
- #: wplogin_redirect.php:776 wplogin_redirect.php:841
46
- #, php-format
47
- msgid "ERROR: Non-local or invalid URL submitted for %s %s"
48
- msgstr ""
49
-
50
- #: wplogin_redirect.php:802
51
- #, php-format
52
- msgid "ERROR: Unknown error adding %s-specific redirect for %s %s"
53
- msgstr ""
54
-
55
- #: wplogin_redirect.php:809
56
- #, php-format
57
- msgid "Successfully added %s-specific redirect rule for %s"
58
- msgstr ""
59
-
60
- #: wplogin_redirect.php:870
61
- #, php-format
62
- msgid "ERROR: Unknown error editing %s-specific redirect for %s %s"
63
- msgstr ""
64
-
65
- #: wplogin_redirect.php:877
66
- #, php-format
67
- msgid "Successfully edited %s-specific redirect rule for %s"
68
- msgstr ""
69
-
70
- #: wplogin_redirect.php:908
71
- #, php-format
72
- msgid "ERROR: Unknown error deleting %s-specific redirect for %s %s"
73
- msgstr ""
74
-
75
- #: wplogin_redirect.php:914
76
- #, php-format
77
- msgid "Successfully deleted %s-specific redirect rule for %s"
78
- msgstr ""
79
-
80
- #: wplogin_redirect.php:952
81
- msgid ""
82
- "ERROR: Unknown database problem removing URL for &#34;all other users&#34; "
83
- msgstr ""
84
-
85
- #: wplogin_redirect.php:956
86
- msgid "Successfully removed URL for &#34;all other users&#34; "
87
- msgstr ""
88
-
89
- #: wplogin_redirect.php:967 wplogin_redirect.php:1039
90
- msgid "ERROR: Non-local or invalid URL submitted "
91
- msgstr ""
92
-
93
- #: wplogin_redirect.php:980
94
- msgid ""
95
- "ERROR: Unknown database problem updating URL for &#34;all other users&#34; "
96
- msgstr ""
97
-
98
- #: wplogin_redirect.php:984
99
- msgid "Successfully updated URL for &#34;all other users&#34;"
100
- msgstr ""
101
-
102
- #: wplogin_redirect.php:1026
103
- msgid ""
104
- "ERROR: Unknown database problem removing URL for &#34;post-registration&#34; "
105
- msgstr ""
106
-
107
- #: wplogin_redirect.php:1029
108
- msgid "Successfully removed URL for &#34;post-registration&#34; "
109
- msgstr ""
110
-
111
- #: wplogin_redirect.php:1052
112
- msgid ""
113
- "ERROR: Unknown database problem updating URL for &#34;post-registration&#34; "
114
- msgstr ""
115
-
116
- #: wplogin_redirect.php:1056
117
- msgid "Successfully updated URL for &#34;post-registration&#34;"
118
- msgstr ""
119
-
120
- #: wplogin_redirect.php:1085
121
- msgid "Successfully updated plugin settings"
122
- msgstr ""
123
-
124
- #: wplogin_redirect.php:1234 wplogin_redirect.php:1255
125
- #: wplogin_redirect.php:1275
126
- msgid "Login URL"
127
- msgstr ""
128
-
129
- #: wplogin_redirect.php:1235 wplogin_redirect.php:1256
130
- #: wplogin_redirect.php:1276
131
- msgid "Logout URL"
132
- msgstr ""
133
-
134
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
135
- #: wplogin_redirect.php:1280
136
- msgid "Edit"
137
- msgstr ""
138
-
139
- #: wplogin_redirect.php:1238 wplogin_redirect.php:1259
140
- #: wplogin_redirect.php:1280 wplogin_redirect.php:1400
141
- #: wplogin_redirect.php:1411
142
- msgid "Delete"
143
- msgstr ""
144
-
145
- #: wplogin_redirect.php:1305
146
- msgid "Manage redirect rules"
147
- msgstr ""
148
-
149
- #: wplogin_redirect.php:1307
150
- msgid ""
151
- "Define custom URLs to which different users, users with specific roles, "
152
- "users with specific levels, and all other users will be redirected upon "
153
- "login."
154
- msgstr ""
155
-
156
- #: wplogin_redirect.php:1308
157
- msgid "Define a custom URL to which all users will be redirected upon logout"
158
- msgstr ""
159
-
160
- #: wplogin_redirect.php:1309
161
- msgid ""
162
- "Note that you can use the syntax <strong>[variable]username[/variable]</"
163
- "strong> in your URLs so that the system will build a dynamic URL upon each "
164
- "login, replacing that text with the users username."
165
- msgstr ""
166
-
167
- #: wplogin_redirect.php:1311
168
- msgid "Specific users"
169
- msgstr ""
170
-
171
- #: wplogin_redirect.php:1322 wplogin_redirect.php:1347
172
- #: wplogin_redirect.php:1380
173
- msgid "Add:"
174
- msgstr ""
175
-
176
- #: wplogin_redirect.php:1324
177
- msgid "Select a username"
178
- msgstr ""
179
-
180
- #: wplogin_redirect.php:1327 wplogin_redirect.php:1352
181
- #: wplogin_redirect.php:1386 wplogin_redirect.php:1397
182
- #: wplogin_redirect.php:1409
183
- msgid "URL:"
184
- msgstr ""
185
-
186
- #: wplogin_redirect.php:1328 wplogin_redirect.php:1353
187
- #: wplogin_redirect.php:1387 wplogin_redirect.php:1398
188
- msgid "Logout URL:"
189
- msgstr ""
190
-
191
- #: wplogin_redirect.php:1331
192
- msgid "Add username rule"
193
- msgstr ""
194
-
195
- #: wplogin_redirect.php:1336
196
- msgid "Specific roles"
197
- msgstr ""
198
-
199
- #: wplogin_redirect.php:1349
200
- msgid "Select a role"
201
- msgstr ""
202
-
203
- #: wplogin_redirect.php:1356
204
- msgid "Add role rule"
205
- msgstr ""
206
-
207
- #: wplogin_redirect.php:1361
208
- msgid "Specific levels"
209
- msgstr ""
210
-
211
- #: wplogin_redirect.php:1370
212
- msgid "Order"
213
- msgstr ""
214
-
215
- #: wplogin_redirect.php:1382
216
- msgid "Select a level"
217
- msgstr ""
218
-
219
- #: wplogin_redirect.php:1385
220
- msgid "Order:"
221
- msgstr ""
222
-
223
- #: wplogin_redirect.php:1390
224
- msgid "Add level rule"
225
- msgstr ""
226
-
227
- #: wplogin_redirect.php:1395
228
- msgid "All other users"
229
- msgstr ""
230
-
231
- #: wplogin_redirect.php:1400 wplogin_redirect.php:1411
232
- #: wplogin_redirect.php:1491
233
- msgid "Update"
234
- msgstr ""
235
-
236
- #: wplogin_redirect.php:1407
237
- msgid "Post-registration"
238
- msgstr ""
239
-
240
- #: wplogin_redirect.php:1418
241
- msgid "Customize plugin settings"
242
- msgstr ""
243
-
244
- #: wplogin_redirect.php:1423
245
- msgid "Redirect restrictions"
246
- msgstr ""
247
-
248
- #: wplogin_redirect.php:1427
249
- msgid "Any http or https URL"
250
- msgstr ""
251
-
252
- #: wplogin_redirect.php:1428
253
- msgid "Any URL"
254
- msgstr ""
255
-
256
- #: wplogin_redirect.php:1429
257
- msgid "Any URL on the same domain"
258
- msgstr ""
259
-
260
- #: wplogin_redirect.php:1435
261
- msgid ""
262
- "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
263
- "precedence"
264
- msgstr ""
265
-
266
- #: wplogin_redirect.php:1439 wplogin_redirect.php:1450
267
- #: wplogin_redirect.php:1462
268
- msgid "Yes"
269
- msgstr ""
270
-
271
- #: wplogin_redirect.php:1440 wplogin_redirect.php:1451
272
- #: wplogin_redirect.php:1463
273
- msgid "No"
274
- msgstr ""
275
-
276
- #: wplogin_redirect.php:1446
277
- msgid ""
278
- "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
279
- "precedence"
280
- msgstr ""
281
-
282
- #: wplogin_redirect.php:1458
283
- #, php-format
284
- msgid ""
285
- "Use external redirect file. Set this to &#34;Yes&#34; if you are using a "
286
- "plugin such as Gigya that bypasses the regular WordPress redirect process "
287
- "(and allows only one fixed redirect URL). Then, set the redirect URL in the "
288
- "other plugin to %s"
289
- msgstr ""
290
-
291
- #: wplogin_redirect.php:1469
292
- msgid "Permission level required to edit redirect URLs"
293
- msgstr ""
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/peters-login-redirect.pot ADDED
@@ -0,0 +1,642 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2021 LoginWP (Formerly Peter's Login Redirect)
2
+ # This file is distributed under the same license as the LoginWP (Formerly Peter's Login Redirect) package.
3
+ msgid ""
4
+ msgstr ""
5
+ "Project-Id-Version: LoginWP (Formerly Peter's Login Redirect) 3.0.0.0\n"
6
+ "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/peters-login-"
7
+ "redirect\n"
8
+ "POT-Creation-Date: 2021-09-12 20:09:54+00:00\n"
9
+ "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
+ "Content-Transfer-Encoding: 8bit\n"
12
+ "PO-Revision-Date: 2021-MO-DA HO:MI+ZONE\n"
13
+ "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14
+ "Language-Team: LANGUAGE <LL@li.org>\n"
15
+
16
+ #: src/core/src/Admin/AbstractSettingsPage.php:30
17
+ msgid "Request Support"
18
+ msgstr ""
19
+
20
+ #: src/core/src/Admin/AbstractSettingsPage.php:34
21
+ msgid "Pro Upgrade"
22
+ msgstr ""
23
+
24
+ #: src/core/src/Admin/AbstractSettingsPage.php:38
25
+ msgid "Review"
26
+ msgstr ""
27
+
28
+ #: src/core/src/Admin/AbstractSettingsPage.php:41
29
+ msgid "Documentation"
30
+ msgstr ""
31
+
32
+ #: src/core/src/Admin/AbstractSettingsPage.php:81
33
+ msgid "Upgrade to Pro"
34
+ msgstr ""
35
+
36
+ #: src/core/src/Admin/AbstractSettingsPage.php:85
37
+ msgid "Need Support?"
38
+ msgstr ""
39
+
40
+ #: src/core/src/Admin/AbstractSettingsPage.php:121
41
+ msgid ""
42
+ "Enhance the power of LoginWP with the Pro version featuring integrations "
43
+ "with many plugins. %sLearn more%s"
44
+ msgstr ""
45
+
46
+ #: src/core/src/Admin/AbstractSettingsPage.php:128
47
+ msgid "Redirect to referrer or previous page"
48
+ msgstr ""
49
+
50
+ #: src/core/src/Admin/AbstractSettingsPage.php:129
51
+ msgid "Redirect to currently viewing page"
52
+ msgstr ""
53
+
54
+ #: src/core/src/Admin/AbstractSettingsPage.php:137
55
+ msgid "Get LoginWP Pro →"
56
+ msgstr ""
57
+
58
+ #: src/core/src/Admin/AbstractSettingsPage.php:155
59
+ msgid ""
60
+ "Whether you need help or have a new feature request, let us know. %sRequest "
61
+ "Support%s"
62
+ msgstr ""
63
+
64
+ #: src/core/src/Admin/AbstractSettingsPage.php:163
65
+ msgid ""
66
+ "Detailed documentation is also available on the plugin website. %sView "
67
+ "Knowledge Base%s"
68
+ msgstr ""
69
+
70
+ #: src/core/src/Admin/AbstractSettingsPage.php:171
71
+ msgid ""
72
+ "If you are enjoying LoginWP and find it useful, please consider leaving a "
73
+ "★★★★★ review on WordPress.org. %sLeave a Review%s"
74
+ msgstr ""
75
+
76
+ #: src/core/src/Admin/Admin.php:39
77
+ msgid "Settings – LoginWP"
78
+ msgstr ""
79
+
80
+ #: src/core/src/Admin/Admin.php:40
81
+ msgid "LoginWP"
82
+ msgstr ""
83
+
84
+ #: src/core/src/Admin/Admin.php:82
85
+ msgid "Are you sure?"
86
+ msgstr ""
87
+
88
+ #: src/core/src/Admin/Admin.php:105
89
+ msgid ""
90
+ "Thank you for using LoginWP. Please rate the plugin %1$s on %2$sWordPress.org"
91
+ "%3$s to help us spread the word."
92
+ msgstr ""
93
+
94
+ #: src/core/src/Admin/Admin.php:126 src/core/src/Admin/SettingsPage.php:29
95
+ #: src/core/src/Admin/SettingsPage.php:35
96
+ msgid "Settings"
97
+ msgstr ""
98
+
99
+ #: src/core/src/Admin/Admin.php:132 src/core/src/Admin/Admin.php:158
100
+ msgid "Go Premium"
101
+ msgstr ""
102
+
103
+ #: src/core/src/Admin/Admin.php:152
104
+ msgid "View LoginWP documentation"
105
+ msgstr ""
106
+
107
+ #: src/core/src/Admin/Admin.php:152
108
+ msgid "Docs"
109
+ msgstr ""
110
+
111
+ #: src/core/src/Admin/Admin.php:153
112
+ msgid "Visit customer support"
113
+ msgstr ""
114
+
115
+ #: src/core/src/Admin/Admin.php:153
116
+ msgid "Support"
117
+ msgstr ""
118
+
119
+ #: src/core/src/Admin/Admin.php:158 src/core/src/Admin/RedirectionsPage.php:449
120
+ msgid "Upgrade to PRO"
121
+ msgstr ""
122
+
123
+ #: src/core/src/Admin/Admin.php:176
124
+ msgid ""
125
+ "Important news! %1$sPeters Login Redirect%2$s has been rebranded to "
126
+ "%1$sLoginWP%2$s with a new UI. %3$sCheck It Out%5$s | %4$sDismiss Notice%5$s"
127
+ msgstr ""
128
+
129
+ #: src/core/src/Admin/Admin.php:206
130
+ msgid ""
131
+ "Hey, I noticed you have been using LoginWP (Formerly Peter's Login Redirect) "
132
+ "for a while now - that's awesome! Could you please do me a BIG favor and "
133
+ "give it a %1$s5-star rating on WordPress?%2$s This will help us spread the "
134
+ "word and boost our motivation - thanks!"
135
+ msgstr ""
136
+
137
+ #: src/core/src/Admin/Admin.php:210
138
+ msgid "Sure! I'd love to give a review"
139
+ msgstr ""
140
+
141
+ #: src/core/src/Admin/Admin.php:212
142
+ msgid "Dismiss"
143
+ msgstr ""
144
+
145
+ #: src/core/src/Admin/ProfilePress.php:47
146
+ msgid "There was an error while performing your request."
147
+ msgstr ""
148
+
149
+ #: src/core/src/Admin/ProfilePress.php:59
150
+ msgid "Could not install plugin. Please download and install manually."
151
+ msgstr ""
152
+
153
+ #: src/core/src/Admin/ProfilePress.php:59
154
+ msgid ""
155
+ "Could not install addon. Please download from wpforms.com and install "
156
+ "manually."
157
+ msgstr ""
158
+
159
+ #: src/core/src/Admin/ProfilePress.php:125
160
+ msgid "Plugin installed."
161
+ msgstr ""
162
+
163
+ #: src/core/src/Admin/ProfilePress.php:125
164
+ msgid "Addon installed."
165
+ msgstr ""
166
+
167
+ #: src/core/src/Admin/ProfilePress.php:135
168
+ msgid "Plugin installed & activated."
169
+ msgstr ""
170
+
171
+ #: src/core/src/Admin/ProfilePress.php:135
172
+ msgid "Addon installed & activated."
173
+ msgstr ""
174
+
175
+ #: src/core/src/Admin/ProfilePress.php:151
176
+ msgid "Plugin activation is disabled for you on this site."
177
+ msgstr ""
178
+
179
+ #: src/core/src/Admin/ProfilePress.php:160
180
+ msgid "Plugin activated."
181
+ msgstr ""
182
+
183
+ #: src/core/src/Admin/ProfilePress.php:164
184
+ msgid "Could not activate plugin. Please activate from the Plugins page."
185
+ msgstr ""
186
+
187
+ #: src/core/src/Admin/ProfilePress.php:172
188
+ msgid "Login Forms"
189
+ msgstr ""
190
+
191
+ #. translators: %s - Lite plugin download URL.
192
+ #: src/core/src/Admin/ProfilePress.php:207
193
+ msgid ""
194
+ "Could not install plugin. Please <a href=\"%s\">download</a> and install "
195
+ "manually."
196
+ msgstr ""
197
+
198
+ #. translators: %s - Lite plugin download URL.
199
+ #: src/core/src/Admin/ProfilePress.php:219
200
+ msgid ""
201
+ "Could not activate plugin. Please activate from the <a href=\"%s\">Plugins "
202
+ "page</a>."
203
+ msgstr ""
204
+
205
+ #: src/core/src/Admin/ProfilePress.php:230
206
+ msgid "Installing..."
207
+ msgstr ""
208
+
209
+ #: src/core/src/Admin/ProfilePress.php:231
210
+ msgid "Activating..."
211
+ msgstr ""
212
+
213
+ #: src/core/src/Admin/ProfilePress.php:232
214
+ #: src/core/src/Admin/ProfilePress.php:599
215
+ msgid "ProfilePress Installed & Activated"
216
+ msgstr ""
217
+
218
+ #: src/core/src/Admin/ProfilePress.php:233
219
+ msgid "Install Now"
220
+ msgstr ""
221
+
222
+ #: src/core/src/Admin/ProfilePress.php:234
223
+ msgid "Activate Now"
224
+ msgstr ""
225
+
226
+ #: src/core/src/Admin/ProfilePress.php:235
227
+ msgid "Download Now"
228
+ msgstr ""
229
+
230
+ #: src/core/src/Admin/ProfilePress.php:236
231
+ msgid "Go to Plugins page"
232
+ msgstr ""
233
+
234
+ #: src/core/src/Admin/ProfilePress.php:241
235
+ msgid "Go to ProfilePress Settings"
236
+ msgstr ""
237
+
238
+ #: src/core/src/Admin/ProfilePress.php:475
239
+ msgid "ProfilePress ♥ ProfilePress"
240
+ msgstr ""
241
+
242
+ #: src/core/src/Admin/ProfilePress.php:476
243
+ msgid "Modern Custom Login Forms & Membership Plugin"
244
+ msgstr ""
245
+
246
+ #: src/core/src/Admin/ProfilePress.php:477
247
+ msgid ""
248
+ "ProfilePress lets you create beautiful frontend custom login forms, "
249
+ "registration forms, member directories and user profiles. You can also "
250
+ "protect sensitive contents and control user access."
251
+ msgstr ""
252
+
253
+ #: src/core/src/Admin/ProfilePress.php:500
254
+ msgid "ProfilePress screenshot"
255
+ msgstr ""
256
+
257
+ #: src/core/src/Admin/ProfilePress.php:501
258
+ msgid ""
259
+ "Beautiful templates for login, registration, password reset & edit profile "
260
+ "edit forms."
261
+ msgstr ""
262
+
263
+ #: src/core/src/Admin/ProfilePress.php:502
264
+ msgid ""
265
+ "Fine-grained control over what content your users can see based on your "
266
+ "protection rules."
267
+ msgstr ""
268
+
269
+ #: src/core/src/Admin/ProfilePress.php:503
270
+ msgid ""
271
+ "Restrict access to pages, posts, custom post types, categories, tags and "
272
+ "custom taxonomies."
273
+ msgstr ""
274
+
275
+ #: src/core/src/Admin/ProfilePress.php:504
276
+ msgid ""
277
+ "Add beautiful user profiles to your site that can be customised to your "
278
+ "specific requirements."
279
+ msgstr ""
280
+
281
+ #: src/core/src/Admin/ProfilePress.php:505
282
+ msgid ""
283
+ "Create searchable and filterable member directories with avatars and user "
284
+ "info allowing users to find each other."
285
+ msgstr ""
286
+
287
+ #: src/core/src/Admin/ProfilePress.php:533
288
+ msgid "Step 1"
289
+ msgstr ""
290
+
291
+ #: src/core/src/Admin/ProfilePress.php:534
292
+ msgid "Install and Activate ProfilePress"
293
+ msgstr ""
294
+
295
+ #: src/core/src/Admin/ProfilePress.php:535
296
+ msgid "Install ProfilePress from the WordPress.org plugin repository."
297
+ msgstr ""
298
+
299
+ #: src/core/src/Admin/ProfilePress.php:568
300
+ msgid "Step 2"
301
+ msgstr ""
302
+
303
+ #: src/core/src/Admin/ProfilePress.php:569
304
+ msgid "Set Up ProfilePress"
305
+ msgstr ""
306
+
307
+ #: src/core/src/Admin/ProfilePress.php:570
308
+ msgid "Configure and create your first login form."
309
+ msgstr ""
310
+
311
+ #: src/core/src/Admin/ProfilePress.php:591
312
+ msgid "Install ProfilePress"
313
+ msgstr ""
314
+
315
+ #: src/core/src/Admin/ProfilePress.php:599
316
+ msgid "Activate ProfilePress"
317
+ msgstr ""
318
+
319
+ #: src/core/src/Admin/ProfilePress.php:617
320
+ msgid "Start Setup"
321
+ msgstr ""
322
+
323
+ #: src/core/src/Admin/ProfilePress.php:623
324
+ msgid "Go to ProfilePress settings"
325
+ msgstr ""
326
+
327
+ #: src/core/src/Admin/ProfilePress.php:644
328
+ msgid "You do not have permission."
329
+ msgstr ""
330
+
331
+ #: src/core/src/Admin/ProfilePress.php:654
332
+ msgid "Plugin unavailable."
333
+ msgstr ""
334
+
335
+ #: src/core/src/Admin/RedirectWPList.php:24
336
+ msgid "loginwp_redirect"
337
+ msgstr ""
338
+
339
+ #: src/core/src/Admin/RedirectWPList.php:25
340
+ msgid "loginwp_redirects"
341
+ msgstr ""
342
+
343
+ #: src/core/src/Admin/RedirectWPList.php:36
344
+ #: src/core/src/Admin/RedirectionsPage.php:66
345
+ msgid "Username"
346
+ msgstr ""
347
+
348
+ #: src/core/src/Admin/RedirectWPList.php:37
349
+ #: src/core/src/Admin/RedirectionsPage.php:72
350
+ msgid "User Role"
351
+ msgstr ""
352
+
353
+ #: src/core/src/Admin/RedirectWPList.php:38
354
+ #: src/core/src/Admin/RedirectionsPage.php:78
355
+ msgid "User Capability"
356
+ msgstr ""
357
+
358
+ #: src/core/src/Admin/RedirectWPList.php:95
359
+ msgid "No redirection rule found. %sConsider creating one%s"
360
+ msgstr ""
361
+
362
+ #: src/core/src/Admin/RedirectWPList.php:149
363
+ #: src/core/src/Admin/RedirectWPList.php:172
364
+ msgid "[Not Set]"
365
+ msgstr ""
366
+
367
+ #: src/core/src/Admin/RedirectWPList.php:154
368
+ msgid "Edit"
369
+ msgstr ""
370
+
371
+ #: src/core/src/Admin/RedirectWPList.php:155
372
+ #: src/core/src/Admin/RedirectWPList.php:254
373
+ #: src/core/src/Admin/views/include.view.php:44
374
+ msgid "Delete"
375
+ msgstr ""
376
+
377
+ #: src/core/src/Admin/RedirectWPList.php:223
378
+ #: src/core/src/Admin/views/view.redirect-urls.php:18
379
+ msgid "Login URL"
380
+ msgstr ""
381
+
382
+ #: src/core/src/Admin/RedirectWPList.php:224
383
+ #: src/core/src/Admin/views/view.redirect-urls.php:26
384
+ msgid "Logout URL"
385
+ msgstr ""
386
+
387
+ #: src/core/src/Admin/RedirectWPList.php:225
388
+ msgid "Condition"
389
+ msgstr ""
390
+
391
+ #: src/core/src/Admin/RedirectWPList.php:226
392
+ msgid "Condition Value"
393
+ msgstr ""
394
+
395
+ #: src/core/src/Admin/RedirectionsPage.php:31
396
+ msgid "Redirections - LoginWP"
397
+ msgstr ""
398
+
399
+ #: src/core/src/Admin/RedirectionsPage.php:34
400
+ msgid "Redirection "
401
+ msgstr ""
402
+
403
+ #: src/core/src/Admin/RedirectionsPage.php:40
404
+ msgid "Redirections"
405
+ msgstr ""
406
+
407
+ #: src/core/src/Admin/RedirectionsPage.php:56
408
+ #: src/core/src/Admin/RedirectionsPage.php:97
409
+ msgid "Rules"
410
+ msgstr ""
411
+
412
+ #: src/core/src/Admin/RedirectionsPage.php:112
413
+ msgid "Add New"
414
+ msgstr ""
415
+
416
+ #: src/core/src/Admin/RedirectionsPage.php:116
417
+ msgid "Go Back"
418
+ msgstr ""
419
+
420
+ #: src/core/src/Admin/RedirectionsPage.php:129
421
+ msgid "Redirection Rules"
422
+ msgstr ""
423
+
424
+ #: src/core/src/Admin/RedirectionsPage.php:185
425
+ msgid "Select..."
426
+ msgstr ""
427
+
428
+ #: src/core/src/Admin/RedirectionsPage.php:228
429
+ msgid "Redirect rule saved successfully"
430
+ msgstr ""
431
+
432
+ #: src/core/src/Admin/RedirectionsPage.php:231
433
+ msgid "Changes saved"
434
+ msgstr ""
435
+
436
+ #: src/core/src/Admin/RedirectionsPage.php:240
437
+ msgid "Redirect rule deleted"
438
+ msgstr ""
439
+
440
+ #: src/core/src/Admin/RedirectionsPage.php:257
441
+ msgid "ERROR: No Login or Logout URL specified"
442
+ msgstr ""
443
+
444
+ #: src/core/src/Admin/RedirectionsPage.php:261
445
+ msgid "ERROR: Non-existent username submitted"
446
+ msgstr ""
447
+
448
+ #: src/core/src/Admin/RedirectionsPage.php:265
449
+ msgid "ERROR: Non-existent role submitted"
450
+ msgstr ""
451
+
452
+ #: src/core/src/Admin/RedirectionsPage.php:269
453
+ msgid "ERROR: Non-existent level submitted"
454
+ msgstr ""
455
+
456
+ #: src/core/src/Admin/RedirectionsPage.php:302
457
+ msgid "ERROR: Unknown error editing redirect rule"
458
+ msgstr ""
459
+
460
+ #: src/core/src/Admin/RedirectionsPage.php:326
461
+ msgid "ERROR: Unknown error when adding the redirect rule"
462
+ msgstr ""
463
+
464
+ #: src/core/src/Admin/RedirectionsPage.php:357
465
+ #: src/core/src/Admin/RedirectionsPage.php:380
466
+ msgid "ERROR: Unknown problem updating URL"
467
+ msgstr ""
468
+
469
+ #: src/core/src/Admin/RedirectionsPage.php:427
470
+ msgid "Username of user"
471
+ msgstr ""
472
+
473
+ #: src/core/src/Admin/RedirectionsPage.php:428
474
+ msgid "Author URL slug or user nicename"
475
+ msgstr ""
476
+
477
+ #: src/core/src/Admin/RedirectionsPage.php:429
478
+ msgid "Website URL"
479
+ msgstr ""
480
+
481
+ #: src/core/src/Admin/RedirectionsPage.php:444
482
+ msgid ""
483
+ "With %sLoginWP PRO%s, you can redirect users to the current page they are "
484
+ "logging in from or the previous page before they are redirected to the login "
485
+ "page."
486
+ msgstr ""
487
+
488
+ #: src/core/src/Admin/SettingsPage.php:26
489
+ msgid "Settings - LoginWP"
490
+ msgstr ""
491
+
492
+ #: src/core/src/Admin/SettingsPage.php:49
493
+ #: src/core/src/Admin/SettingsPage.php:72
494
+ msgid "General"
495
+ msgstr ""
496
+
497
+ #: src/core/src/Admin/SettingsPage.php:64
498
+ msgid "Remove Data on Uninstall"
499
+ msgstr ""
500
+
501
+ #: src/core/src/Admin/SettingsPage.php:65
502
+ #: src/core/src/Admin/SettingsPageApi.php:1009
503
+ msgid "Activate"
504
+ msgstr ""
505
+
506
+ #: src/core/src/Admin/SettingsPage.php:66
507
+ msgid ""
508
+ "Check this box if you would like LoginWP to completely remove all of its "
509
+ "data when uninstalled."
510
+ msgstr ""
511
+
512
+ #: src/core/src/Admin/SettingsPageApi.php:857
513
+ msgid "Code"
514
+ msgstr ""
515
+
516
+ #: src/core/src/Admin/SettingsPageApi.php:858
517
+ msgid "Preview"
518
+ msgstr ""
519
+
520
+ #: src/core/src/Admin/SettingsPageApi.php:1080
521
+ #: src/core/src/Admin/views/view.bottom-settings.php:48
522
+ #: src/core/src/Admin/views/view.bottom-settings.php:74
523
+ #: src/core/src/Admin/views/view.bottom-settings.php:116
524
+ msgid "Save Changes"
525
+ msgstr ""
526
+
527
+ #: src/core/src/Admin/views/include.view.php:15
528
+ msgid "Rule Condition"
529
+ msgstr ""
530
+
531
+ #: src/core/src/Admin/views/include.view.php:26
532
+ msgid "Redirect URLs"
533
+ msgstr ""
534
+
535
+ #: src/core/src/Admin/views/include.view.php:50
536
+ msgid "Save Rule"
537
+ msgstr ""
538
+
539
+ #: src/core/src/Admin/views/view.bottom-settings.php:15
540
+ #: src/core/src/Admin/views/view.redirect-urls.php:6
541
+ msgid "View Available Placeholders"
542
+ msgstr ""
543
+
544
+ #: src/core/src/Admin/views/view.bottom-settings.php:20
545
+ msgid "All Other Users"
546
+ msgstr ""
547
+
548
+ #: src/core/src/Admin/views/view.bottom-settings.php:30
549
+ msgid "Login URL:"
550
+ msgstr ""
551
+
552
+ #: src/core/src/Admin/views/view.bottom-settings.php:38
553
+ msgid "Logout URL:"
554
+ msgstr ""
555
+
556
+ #: src/core/src/Admin/views/view.bottom-settings.php:57
557
+ msgid "After Registration"
558
+ msgstr ""
559
+
560
+ #: src/core/src/Admin/views/view.bottom-settings.php:64
561
+ msgid "URL:"
562
+ msgstr ""
563
+
564
+ #: src/core/src/Admin/views/view.bottom-settings.php:80
565
+ msgid "Redirect Settings"
566
+ msgstr ""
567
+
568
+ #: src/core/src/Admin/views/view.bottom-settings.php:86
569
+ msgid ""
570
+ "Allow a POST or GET &#34;redirect_to&#34; variable to take redirect "
571
+ "precedence"
572
+ msgstr ""
573
+
574
+ #: src/core/src/Admin/views/view.bottom-settings.php:92
575
+ #: src/core/src/Admin/views/view.bottom-settings.php:107
576
+ msgid "Yes"
577
+ msgstr ""
578
+
579
+ #: src/core/src/Admin/views/view.bottom-settings.php:93
580
+ #: src/core/src/Admin/views/view.bottom-settings.php:108
581
+ msgid "No"
582
+ msgstr ""
583
+
584
+ #: src/core/src/Admin/views/view.bottom-settings.php:101
585
+ msgid ""
586
+ "Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect "
587
+ "precedence"
588
+ msgstr ""
589
+
590
+ #: src/core/src/Admin/views/view.condition-rule.php:15
591
+ msgid "Select a condition"
592
+ msgstr ""
593
+
594
+ #: src/core/src/Admin/views/view.condition-rule.php:35
595
+ msgid "Order"
596
+ msgstr ""
597
+
598
+ #: src/core/src/Functions.php:17
599
+ msgid "Register"
600
+ msgstr ""
601
+
602
+ #: src/core/src/Functions.php:22
603
+ msgid "Site Admin"
604
+ msgstr ""
605
+
606
+ #: src/core/src/MoAdminNotice.php:64
607
+ msgid ""
608
+ "Free optin form plugin that will %1$sincrease your email list subscribers"
609
+ "%2$s and keep them engaged with %1$sautomated and schedule newsletters%2$s."
610
+ msgstr ""
611
+
612
+ #: src/core/src/MoAdminNotice.php:73
613
+ msgid "Install MailOptin Now for Free!"
614
+ msgstr ""
615
+
616
+ #: src/core/src/MoAdminNotice.php:78
617
+ msgid "Activate MailOptin Now!"
618
+ msgstr ""
619
+
620
+ #: src/core/src/MoAdminNotice.php:87
621
+ msgid "Dismiss this notice"
622
+ msgstr ""
623
+
624
+ #. Plugin Name of the plugin/theme
625
+ msgid "LoginWP (Formerly Peter's Login Redirect)"
626
+ msgstr ""
627
+
628
+ #. #-#-#-#-# peters-login-redirect.pot (LoginWP (Formerly Peter's Login Redirect) 3.0.0.0) #-#-#-#-#
629
+ #. Plugin URI of the plugin/theme
630
+ #. #-#-#-#-# peters-login-redirect.pot (LoginWP (Formerly Peter's Login Redirect) 3.0.0.0) #-#-#-#-#
631
+ #. Author URI of the plugin/theme
632
+ msgid "https://loginwp.com"
633
+ msgstr ""
634
+
635
+ #. Description of the plugin/theme
636
+ msgid ""
637
+ "Redirect users to different URLs based on their role, capability and more."
638
+ msgstr ""
639
+
640
+ #. Author of the plugin/theme
641
+ msgid "LoginWP Team"
642
+ msgstr ""
readme.txt CHANGED
@@ -1,289 +1,78 @@
1
- === Peter's Login Redirect ===
2
  Contributors: properfraction, collizo4sky
3
- Donate link: https://profilepress.net/pricing
4
- Tags: login, logout, redirect, admin, administration, dashboard, users, authentication
5
  Requires at least: 4.0
6
- Requires PHP: 5.4
7
  Tested up to: 5.8
8
- Stable tag: 2.9.9
9
  License: GPL-2.0+
10
 
11
- Redirect users to different locations after logging in and logging out.
12
 
13
  == Description ==
14
 
15
- Define a set of redirect rules for specific users, users with specific roles, users with specific capabilities, and a blanket rule for all other users. Also, set a redirect URL for post-registration. This is all managed in Settings > Login/logout redirects.
16
 
17
- You can use the syntax **[variable]username[/variable]** in your URLs so that the system will build a dynamic URL upon each login, replacing that text with the user's username. In addition to username, there is "userslug", "homeurl", "siteurl", "postid-23", "http_referer" and you can also add your own custom URL "variables". See Other Notes / How to Extend for documentation.
18
 
19
- You can add your own code logic before and between any of the plugin's normal redirect checks if needed. See Other Notes / How to Extend for documentation. Some examples include: redirecting the user based on their IP address; and redirect users to a special page on first login.
20
 
21
- This plugin also includes a function `rul_register` that acts the same as the `wp_register` function you see in templates (typically producing the Register or Site Admin links in the sidebar), except that it will return the custom defined admin address. `rul_register` takes three parameters: the "before" code (by default "&lt;li&gt;"), the "after" code (by default "&lt;/li&gt;"), and whether to echo or return the result (default is `true` and thus echo).
22
 
23
- == Installation ==
24
-
25
- Installing this plugin is just like any other WordPress plugin.
26
- Navigate to your WordPress “Plugins” page, inside of your WordPress dashboard, and follow these instructions:
27
-
28
- 1. In the search field enter **Peter’s Login Redirect**. Click "Search Plugins", or hit Enter.
29
- 1. Select **Peter’s Login Redirect** and click either "Details" or "Install Now".
30
- 1. Once installed, click "Activate".
31
-
32
- == Screenshots ==
33
-
34
- 1. Defining redirect rules per role.
35
-
36
- == Frequently Asked Questions ==
37
-
38
- Please visit the plugin page at http://www.theblog.ca/wplogin-redirect with any questions.
39
-
40
- Login redirects not working? This plugin uses WordPress's standard login_redirect hook. The usual cause of problems is that another plugin is using the hook first, or there is a custom login form that isn't even running through the standard WordPress login functions.
41
-
42
- These threads might be useful:
43
-
44
- * http://www.theblog.ca/peter-forum/peters-login-redirect/logout-works-great-but-log-in-keeps-going-to-my-account-pages
45
- * http://www.theblog.ca/peter-forum/peters-login-redirect/redirect-not-working
46
- * http://www.theblog.ca/peter-forum/peters-login-redirect/any-way-to-solve-re-direct-conflict-with-wp-affiliate-plugin
47
-
48
- Also see the instructions at the bottom of the settings on the "Settings &gt; Login/logout redirects" page in the WordPress admin panel that says:
49
 
50
- == How to Extend ==
51
 
52
- = Custom redirect rules =
53
 
54
- You can write your own code logic before any of this plugin's checks for user-specific, role-specific, and capability-specific redirects, as well as before the fallback redirect URL.
 
 
 
 
 
 
 
 
 
 
 
55
 
56
- An example of plugin code to redirect users on first login. See http://www.theblog.ca/wordpress-redirect-first-login for standalone functionality:
57
 
58
- `// Send new users to a special page
59
- function redirectOnFirstLogin( $custom_redirect_to, $redirect_to, $requested_redirect_to, $user )
60
- {
61
- // URL to redirect to
62
- $redirect_url = 'http://yoursite.com/firstloginpage';
63
- // How many times to redirect the user
64
- $num_redirects = 1;
65
- // If implementing this on an existing site, this is here so that existing users don't suddenly get the "first login" treatment
66
- // On a new site, you might remove this setting and the associated check
67
- // Alternative approach: run a script to assign the "already redirected" property to all existing users
68
- // Alternative approach: use a date-based check so that all registered users before a certain date are ignored
69
- // 172800 seconds = 48 hours
70
- $message_period = 172800;
71
 
72
- /*
73
- Cookie-based solution: captures users who registered within the last n hours
74
- The reason to set it as "last n hours" is so that if a user clears their cookies or logs in with a different browser,
75
- they don't get this same redirect treatment long after they're already a registered user
76
- */
77
- /*
78
 
79
- $key_name = 'redirect_on_first_login_' . $user->ID;
80
-
81
- if( strtotime( $user->user_registered ) > ( time() - $message_period )
82
- && ( !isset( $_COOKIE[$key_name] ) || intval( $_COOKIE[$key_name] ) < $num_redirects )
83
- )
84
- {
85
- if( isset( $_COOKIE[$key_name] ) )
86
- {
87
- $num_redirects = intval( $_COOKIE[$key_name] ) + 1;
88
- }
89
- setcookie( $key_name, $num_redirects, time() + $message_period, COOKIEPATH, COOKIE_DOMAIN );
90
- return $redirect_url;
91
- }
92
- */
93
- /*
94
- User meta value-based solution, stored in the database
95
- */
96
- $key_name = 'redirect_on_first_login';
97
- // Third parameter ensures that the result is a string
98
- $current_redirect_value = get_user_meta( $user->ID, $key_name, true );
99
- if( strtotime( $user->user_registered ) > ( time() - $message_period )
100
- && ( '' == $current_redirect_value || intval( $current_redirect_value ) < $num_redirects )
101
- )
102
- {
103
- if( '' != $current_redirect_value )
104
- {
105
- $num_redirects = intval( $current_redirect_value ) + 1;
106
- }
107
- update_user_meta( $user->ID, $key_name, $num_redirects );
108
- return $redirect_url;
109
- }
110
- else
111
- {
112
- return $custom_redirect_to;
113
- }
114
- }
115
-
116
- add_filter( 'rul_before_user', 'redirectOnFirstLogin', 10, 4 );`
117
-
118
- An example of plugin code to redirect to a specific URL for only a specific IP range as the first redirect check:
119
-
120
- `function redirectByIP( $custom_redirect_to, $redirect_to, $requested_redirect_to, $user )
121
- {
122
- $ip_check = '192.168.0';
123
- if( 0 === strpos( $_SERVER['REMOTE_ADDR'], $ip_check ) )
124
- {
125
- return '/secret_area';
126
- }
127
- else
128
- {
129
- return $custom_redirect_to;
130
- }
131
- }
132
-
133
- add_filter( 'rul_before_user', 'redirectByIP', 10, 4 );`
134
 
135
- It takes 3 parameters:
 
136
 
137
- * $custom_redirect_to: This is set as false in case you don't have any redirect URL to set. Return this instead of false in case you have multiple filters running.
138
- * $requested_redirect_to: A redirect parameter set via POST or GET.
139
- * $user: A PHP object representing the current user.
140
 
141
- = Custom variable parameters =
142
 
143
- There is an available filter "rul_replace_variable" for adding your own custom variable names. For example, to replace **[variable]month[/variable]** in the redirect URL with the numeric representation of the current month (with leading zeros):
 
 
 
144
 
145
- `function customRULVariableMonth( $custom_redirect_to, $variable, $user )
146
- {
147
- if( 'month' == $variable )
148
- {
149
- return date( 'm' );
150
- }
151
- else
152
- {
153
- return $custom_redirect_to;
154
- }
155
- }
156
 
157
- add_filter( 'rul_replace_variable', 'customRULVariableMonth', 10, 3 );`
158
 
159
- Be sure to rawurlencode the returned variable if necessary.
160
 
161
  == Changelog ==
162
 
163
- = 2.9.9 =
164
- * Fixed bug in multisite activation support.
165
-
166
- = 2.9.8 =
167
- * Added multisite support.
168
-
169
- = 2.9.7 =
170
- * Added option to redirect to any url specified.
171
-
172
- = 2.9.6 =
173
- * Added back php file url base redirect.
174
-
175
- = 2.9.5 =
176
- * Fixed: logout redirect not working.
177
- * Remove php file redirect option. No longer used by many or used at all.
178
- * Plugin redirection is only manageable by manage_categories capability. Removed option to change this.
179
-
180
- = 2.9.4 =
181
- * Fixed: Warning: is_readable(): open_basedir restriction.
182
-
183
- = 2.9.3 =
184
- * Move languages po/mo files into languages folder.
185
-
186
- = 2.9.2 =
187
- * 2019-02-23: Add CSRF protection (thanks RIPS!). Fixed translations for "username" variable instruction (thanks Jaime!).
188
-
189
- = 2.9.1 =
190
- * 2016-08-10: Support utf8mb4 encoding and prevent cross-site scripting when editing redirect URLs.
191
-
192
- = 2.9.0 =
193
- * 2015-09-25: Update translation text domain in order to support translate.wordpress.org translation system
194
-
195
- = 2.8.3 =
196
- * 2015-08-03: Add new URL variable "userslug" to match author URLs.
197
-
198
- = 2.8.2 =
199
- * 2014-09-06: Translation string fix.
200
-
201
- = 2.8.1 =
202
- * 2014-08-03: Support the deletion of rules referencing deleted user, roles, or levels.
203
-
204
- = 2.8.0 =
205
- * 2014-07-06: Improved management interface to add specific Edit and Delete buttons per rule, and removed limit around number of rules.
206
-
207
- = 2.7.2 =
208
- * 2013-10-07: Support PHP 5 static function calls, bumping WordPress requirement to 3.2+.
209
-
210
- = 2.7.1 =
211
- * 2013-07-05: Bug fix: Role-based login URLs weren't saving correctly.
212
-
213
- = 2.7.0 =
214
- * 2013-07-04: Add logout redirect URL control per-user, per-role, and per-level
215
-
216
- = 2.6.1 =
217
- * 2012-12-22: Allow editors to manage redirects in WordPress 3.5+ (required capability is now "manage_categories" instead of "manage_links").
218
-
219
- = 2.6.0 =
220
- * 2012-09-22: Added support for URL variable "http_referer" (note the single "r") to redirect the user back to the page that hosted the login form, as long as the login page isn't the standard wp-login.php. There are several caveats to this, such as: If you want to redirect only on certain forms and/or specify a redirect on the standard wp-login.php page, you should modify the form itself to use a "redirect_to" form variable instead.
221
-
222
- = 2.5.3 =
223
- * 2012-06-15: Bug fix: Fallback redirect rule wouldn't update properly if logout URL was blank on MySQL installs with strict mode enabled (thanks kvandekrol!)
224
-
225
- = 2.5.2 =
226
- * 2012-02-06: Bug fix: Fallback redirect rule updates were broken for non-English installs.
227
-
228
- = 2.5.1 =
229
- * 2012-01-17: Bug fix: Redirect after registration back-end code was missed in 2.5.0, and thus that feature wasn't actually working.
230
-
231
- = 2.5.0 =
232
- * 2012-01-15: Added redirect after registration option. Also made plugin settings editable in the WordPress admin panel.
233
-
234
- = 2.4.0 =
235
- * 2012-01-05: Added support for URL variable "postid-23". Also added documentation on how to set up redirect on first login.
236
-
237
- = 2.3.0 =
238
- * 2011-11-06: Added support for URL variable "siteurl" and "homeurl". Also added filter to support custom replacement variables in the URL. See Other Notes / How to Extend for documentation.
239
-
240
- = 2.2.0 =
241
- * 2011-09-21: Support basic custom logout redirect URL for all users only. Future versions will have the same framework for logout redirects as for login redirects.
242
-
243
- = 2.1.1 =
244
- * 2011-08-13: Minor code cleanup. Note: users now need "manage_links" permissions to edit redirect settings by default.
245
-
246
- = 2.1.0 =
247
- * 2011-06-06: Added hooks to facilitate adding your own extensions to the plugin. See Other Notes / How to Extend for documentation.
248
-
249
- = 2.0.0 =
250
- * 2011-03-03: Added option to allow a redirect_to POST or GET variable to take precedence over this plugin's rules.
251
-
252
- = 1.9.3 =
253
- * 2010-12-15: Made plugin translatable. (Thanks Anja!)
254
-
255
- = 1.9.2 =
256
- * 2010-08-20: Bug fix in code syntax.
257
-
258
- = 1.9.1 =
259
- * 2010-08-03: Bug fix for putting the username in the redirect URL.
260
-
261
- = 1.9.0 =
262
- * 2010-08-02: Added support for a separate redirect controller URL for compatibility with Gigya and similar plugins that bypass the regular WordPress login redirect mechanism. See the $rul_use_redirect_controller setting within this plugin.
263
-
264
- = 1.8.1 =
265
- * 2010-05-13: Added proper encoding of username in the redirect URL if the username has spaces.
266
-
267
- = 1.8.0 =
268
- * 2010-03-18: Added the ability to specify a username in the redirect URL for more dynamic URL generation.
269
-
270
- = 1.7.3 =
271
- * 2010-03-04: Minor tweak on settings page for better compatibility with different WordPress URL setups.
272
-
273
- = 1.7.2 =
274
- * 2010-01-11: Plugin now removes its database tables when it is uninstalled, instead of when it is deactivated. This prevents the redirect rules from being deleted when upgrading WordPress automatically.
275
-
276
- = 1.7.1 =
277
- * 2009-10-07: Minor database compatibility tweak. (Thanks KCP!)
278
-
279
- = 1.7.0 =
280
- * 2009-05-31: Added option $rul_local_only (in the plugin file itself) to bypass the WordPress default limitation of only redirecting to local URLs.
281
-
282
- = 1.6.1 =
283
- * 2009-02-06: Minor database table tweak for better compatibility with different setups. (Thanks David!)
284
-
285
- = 1.6.0 =
286
- * 2008-11-26: Added a function rul_register that acts the same as the wp_register function you see in templates, except that it will return the custom defined admin address
287
 
288
- = 1.5.1 =
289
- * 2008-09-17: Fixed compatibility for sites with a different table prefix setting in wp-config.php. (Thanks Eric!)
1
+ === LoginWP (Formerly Peter's Login Redirect) ===
2
  Contributors: properfraction, collizo4sky
3
+ Donate link: https://loginwp.com/pricing
4
+ Tags: login, logout, redirect, login form, user registration, admin, administration, dashboard, users, authentication
5
  Requires at least: 4.0
6
+ Requires PHP: 5.6
7
  Tested up to: 5.8
8
+ Stable tag: 3.0.0.0
9
  License: GPL-2.0+
10
 
11
+ Redirect users to different locations after they log in, log out and register based on different conditions.
12
 
13
  == Description ==
14
 
15
+ [LoginWP](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion) (formerly Peter's Login Redirect) lets you define a set of redirect rules for specific users, users with specific roles, users with specific capabilities, and a blanket rule for all other users. Also, set a redirect URL for post-registration.
16
 
17
+ You can use the following placeholders in your URLs so that the system will build a dynamic URL upon each login: **{{username}}**, **{{user_slug}}**, **{{website_url}}**.
18
 
19
+ Upgrade to [LoginWP PRO](https://loginwp.com/pricing/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion) to redirect users to the current page they are logging in from or back to the previous (or referrer) page after login using **{{current_page}}** and **{{previous_page}}** placeholders. [Learn more](https://loginwp.com/wordpress-redirect-referrer-page-after-login/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion)
20
 
21
+ You can add your own code logic before and between any of the plugin's normal redirect checks if needed. [See our documentation](https://loginwp.com/docs/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion). Some examples include: redirecting the user based on their IP address and redirecting users to a special page on the first login.
22
 
23
+ [Website](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion) | [Documentation](https://loginwp.com/docs/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion) | [Support](https://loginwp.com/support/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
24
 
25
+ ### Pro Integrations
26
 
27
+ This is the lite version that works with the default WordPress login page and limited other user registration and login form plugins. Upgrade to Pro to avail the support for the following plugins.
28
 
29
+ * [WooCommerce](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
30
+ * [Gravity Forms](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
31
+ * [WPForms](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
32
+ * [LearnDash](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
33
+ * [LifterLMS](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
34
+ * [MemberPress](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
35
+ * [Easy Digital Downloads](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
36
+ * [Restrict Content Pro](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
37
+ * [Ultimate Member](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
38
+ * [WP User Manager](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
39
+ * [Theme My Login](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
40
+ * [User Registration (WPEverest)](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion#pro-integrations)
41
 
42
+ = What's Next =
43
 
44
+ If you like this plugin, then consider checking out our other products:
 
 
 
 
 
 
 
 
 
 
 
 
45
 
46
+ * <a href="https://profilepress.net/?utm_source=wprepo&utm_medium=link&utm_campaign=loginwp">ProfilePress</a> - The perfect user registration, login form, user profile & membership plugin.
47
+ * <a href="https://mailoptin.io/?utm_source=wprepo&utm_medium=link&utm_campaign=loginwp" title="MailOptin">MailOptin</a> - Create popups and optin forms for capturing email newsletter subscribers. Integrates with Mailchimp, ConvertKit, Infusionsoft, ActiveCampaign, Campaign Monitor, Constant Contact & more.
 
 
 
 
48
 
49
+ == Installation ==
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
50
 
51
+ Installing this plugin is just like any other WordPress plugin.
52
+ Navigate to your WordPress “Plugins” page, inside of your WordPress dashboard, and follow these instructions:
53
 
54
+ 1. In the search field enter **LoginWP**. Click "Search Plugins", or hit Enter.
55
+ 1. Select **LoginWP** and click either "Details" or "Install Now".
56
+ 1. Once installed, click "Activate".
57
 
58
+ == Screenshots ==
59
 
60
+ 1. Redirection rules overview.
61
+ 2. Adding a redirection rule.
62
+ 3. Other settings.
63
+ 3. Redirect Placeholders.
64
 
65
+ == Frequently Asked Questions ==
 
 
 
 
 
 
 
 
 
 
66
 
67
+ Please visit the [plugin page](https://loginwp.com/?utm_source=wprepo&utm_medium=link&utm_campaign=liteversion) with any questions.
68
 
69
+ Login redirects not working? This plugin uses WordPress's standard login_redirect hook. The usual cause of problems is that another plugin is using the hook first, or there is a custom login form that isn't even running through the standard WordPress login functions.
70
 
71
  == Changelog ==
72
 
73
+ = 3.0.0.0 =
74
+ * Rebranded to LoginWP.
75
+ * UI revamp.
76
+ * [Pro plugin](https://loginwp.com/pricing/?utm_source=wprepo&utm_medium=changelog&utm_campaign=3-release) now available.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
77
 
78
+ See the [changelog file](https://plugins.svn.wordpress.org/peters-login-redirect/trunk/changelog.txt) for full changelog information.
 
screenshot-1.png DELETED
Binary file
src/core/.gitignore ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
1
+ build/
2
+ node_modules/*
3
+ vendor/*
4
+ composer.lock
5
+ .DS_Store
src/core/assets/css/admin.css ADDED
@@ -0,0 +1,287 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ .loginwp-data-listing .ptr-loginwp-condition-wrap,
2
+ .loginwp-admin ptr-loginwp-condition-wrap * {
3
+ box-sizing: border-box;
4
+ }
5
+
6
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-condition-wrap {
7
+ padding: 20px 15px 15px;
8
+ }
9
+
10
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-row {
11
+ box-sizing: border-box;
12
+ }
13
+
14
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-col {
15
+ width: 49.5%;
16
+ display: inline-block;
17
+ box-sizing: border-box;
18
+ }
19
+
20
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-col select {
21
+ width: 100%;
22
+ padding: 0 5px;
23
+ max-width: 100%;
24
+ }
25
+
26
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-redirect-wrap,
27
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-order-wrap {
28
+ padding: 0 10px 0 15px;
29
+ }
30
+
31
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-redirect-wrap input {
32
+ width: 100%;
33
+ }
34
+
35
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-order-wrap th {
36
+ width: 50px;
37
+ }
38
+
39
+ .loginwp-admin .loginwp-data-listing .ptr-loginwp-order-wrap input {
40
+ width: 60px;
41
+ padding-right: 0;
42
+ }
43
+
44
+ .loginwp-admin .loginwp-data-listing .handle-actions {
45
+ display: none
46
+ }
47
+
48
+ .loginwp-admin .loginwp-view-variables {
49
+ text-align: right;
50
+ padding: 15px 10px 0;
51
+ }
52
+
53
+ .loginwp-admin .loginwp-view-placeholders-wrap .loginwp-placeholder {
54
+ border-bottom: 1px solid #eee;
55
+ padding: 15px 0;
56
+ }
57
+
58
+ .loginwp-admin .loginwp-admin-banner {
59
+ background-color: #3C50FF;
60
+ -webkit-box-sizing: border-box;
61
+ box-sizing: border-box;
62
+ overflow: hidden;
63
+ position: relative;
64
+ top: 0;
65
+ width: 100%;
66
+ padding: 15px;
67
+ margin-bottom: 10px;
68
+ }
69
+
70
+ .loginwp-admin .loginwp-admin-banner.loginwp-pro {
71
+ padding: 15px 15px 0;
72
+ }
73
+
74
+ .loginwp-admin .loginwp-admin-banner.loginwp-pro.loginwp-no-submenu {
75
+ padding-bottom: 15px;
76
+ }
77
+
78
+ .loginwp-admin .wrap {
79
+ padding-left: 20px;
80
+ margin: 0 20px 0 2px;
81
+ }
82
+
83
+ .wp-admin.loginwp-admin #wpcontent {
84
+ padding: 0;
85
+ }
86
+
87
+ .loginwp-admin .loginwp-admin-banner__logo {
88
+ padding: 0 0 15px;
89
+ display: block;
90
+ }
91
+
92
+ .loginwp-admin .loginwp-admin-banner__logo img {
93
+ width: 140px;
94
+ height: auto;
95
+ float: left;
96
+ margin-top: 20px;
97
+ padding-left: 15px;
98
+ }
99
+
100
+ .loginwp-admin .loginwp-admin-banner__helplinks {
101
+ float: right;
102
+ padding: 10px 20px 20px;
103
+ }
104
+
105
+ .loginwp-admin .loginwp-admin-banner__helplinks a {
106
+ color: #ffffff;
107
+ text-decoration: none;
108
+ }
109
+
110
+ .loginwp-admin .loginwp-admin-banner__helplinks a.lwp-active {
111
+ background: #fff;
112
+ padding: 5px;
113
+ color: #3C50FF;
114
+ border-radius: 4px;
115
+ }
116
+
117
+ .loginwp-admin .loginwp-admin-banner__helplinks > span {
118
+ padding-right: 15px;
119
+ }
120
+
121
+ .loginwp-admin div#screen-meta-links {
122
+ position: absolute;
123
+ right: 0;
124
+ z-index: 9;
125
+ }
126
+
127
+ .loginwp-admin .loginwp-nav-tab-wrapper {
128
+ padding: 0;
129
+ margin: 0 16px;
130
+ border-bottom: 0;
131
+ }
132
+
133
+ .loginwp-admin .loginwp-nav-tab-wrapper .loginwp-nav-tab {
134
+ display: block;
135
+ font-weight: 500;
136
+ padding: 5px 25px;
137
+ text-decoration: none;
138
+ border: 1px solid transparent;
139
+ background-color: transparent;
140
+ color: #fff;
141
+ margin: 0;
142
+ }
143
+
144
+ .loginwp-admin .loginwp-nav-tab-wrapper .loginwp-nav-tab.loginwp-nav-active {
145
+ background-color: #fff;
146
+ color: #2d3559;
147
+ border-color: #fff;
148
+ border-radius: 4px 4px 0 0;
149
+ }
150
+
151
+ .loginwp-admin .loginwp_redirects th#rul_type {
152
+ width: 16%;
153
+ }
154
+
155
+ .loginwp-admin .loginwp_redirects th#rul_value {
156
+ width: 16%;
157
+ }
158
+
159
+ .loginwp-admin .postbox-container .inside ul {
160
+ margin-bottom: 20px;
161
+ }
162
+
163
+ .loginwp-admin .postbox-container .inside ul li {
164
+ position: relative;
165
+ padding-left: 22px;
166
+ font-weight: 600;
167
+ font-size: .9em;
168
+ }
169
+
170
+ .loginwp-admin .postbox-container .inside ul li:before {
171
+ content: "";
172
+ position: absolute;
173
+ top: 0;
174
+ right: 0;
175
+ bottom: 0;
176
+ left: 0;
177
+ z-index: 0;
178
+ background-color: #3C50FF;
179
+ mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M9 16.2L4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4L9 16.2z'/></svg>");
180
+ -webkit-mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'><path d='M9 16.2L4.8 12l-1.4 1.4L9 19 21 7l-1.4-1.4L9 16.2z'/></svg>");
181
+ mask-size: 16px;
182
+ -webkit-mask-size: 16px;
183
+ mask-repeat: no-repeat;
184
+ -webkit-mask-repeat: no-repeat;
185
+ mask-position: left;
186
+ -webkit-mask-position: left;
187
+ }
188
+
189
+ .loginwp-admin.wp-core-ui .wrap a {
190
+ color: #3d49b2;
191
+ }
192
+
193
+ .loginwp-admin.wp-core-ui .wrap .button-primary,
194
+ .loginwp-admin.wp-core-ui .loginwp-view-placeholders-wrap .button-primary {
195
+ background: #3C50FF;
196
+ border-color: #3C50FF;
197
+ color: #fff;
198
+ }
199
+
200
+ .loginwp-admin.wp-core-ui .wrap a.loginwp-link {
201
+ display: block;
202
+ margin-top: 10px;
203
+ font-size: 1em;
204
+
205
+ }
206
+
207
+ .loginwp-admin.wp-core-ui .wrap a.loginwp-link svg {
208
+ width: 1.2em;
209
+ margin: 0 .2em 0;
210
+ height: 1.4em;
211
+ vertical-align: middle;
212
+ fill: currentcolor;
213
+ }
214
+
215
+ .loginwp-admin .loginwp-rule-actions-wrap {
216
+ margin: 0 0 10px;
217
+ text-align: right;
218
+ }
219
+
220
+ .loginwp-admin .loginwp-delete-action,
221
+ .loginwp-admin .loginwp-save-action {
222
+ display: inline;
223
+ margin-left: 20px;
224
+ vertical-align: middle;
225
+ min-height: 32px;
226
+ line-height: 2.30769231;
227
+ }
228
+
229
+ .loginwp-admin .loginwp-delete-action a {
230
+ vertical-align: middle;
231
+ }
232
+
233
+ .loginwp-admin.wp-core-ui .wrap .loginwp-delete-action a {
234
+ color: #b32d2e;
235
+ }
236
+
237
+ .loginwp-admin .loginwp-banner {
238
+ position: absolute;
239
+ left: 10%;
240
+ display: block;
241
+ margin: 10px 5px 20px;
242
+ width: 600px;
243
+ height: 60px;
244
+ border: 1px solid #654dba;
245
+ font: 400 30px/60px Rye;
246
+ text-align: center;
247
+ color: #fff;
248
+ background: #3d49b2;
249
+ border-radius: 4px;
250
+ box-shadow: 0 0 30px rgba(0, 0, 0, .15) inset, 0 6px 10px rgba(0, 0, 0, .15);
251
+ }
252
+
253
+ .loginwp-admin .loginwp-banner::after,
254
+ .loginwp-admin .loginwp-banner::before {
255
+ content: '';
256
+ position: absolute;
257
+ left: -70px;
258
+ top: 24px;
259
+ display: block;
260
+ width: 40px;
261
+ height: 0;
262
+ border: 30px solid #4b57bc;
263
+ border-right: 20px solid #3d49b2;
264
+ border-bottom-color: #4b57bc;
265
+ border-left-color: transparent;
266
+ transform: rotate(-5deg);
267
+ }
268
+
269
+ .loginwp-admin .loginwp-banner::after {
270
+ left: auto;
271
+ right: -70px;
272
+ border-left: 20px solid #3d49b2;
273
+ border-right: 30px solid transparent;
274
+ transform: rotate(5deg)
275
+ }
276
+
277
+ .loginwp-admin .loginwp-banner-wrap {
278
+ height: 90px;
279
+ }
280
+
281
+ .remove_white_styling.loginwp_license #post-body-content .form-table th {
282
+ width: 150px;
283
+ }
284
+
285
+ .remove_white_styling.loginwp_license #post-body-content input.regular-text {
286
+ width: 30em;
287
+ }
src/core/assets/css/index.php ADDED
File without changes
src/core/assets/images/index.php ADDED
File without changes
src/core/assets/images/loginwp.png ADDED
Binary file
src/core/assets/images/loginwpXprofilepress.png ADDED
Binary file
src/core/assets/images/ppress-login-form.png ADDED
Binary file
src/core/assets/images/step-1.svg ADDED
@@ -0,0 +1 @@
 
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 100 100"><circle cx="50" cy="50" r="50" fill="#ccc"/><path data-name="1" d="M47.48 67.35v-22.7h-8.8V39.3a16.779 16.779 0 003.57-.27 9.344 9.344 0 003.1-1.15 7.565 7.565 0 002.33-2.18 7.737 7.737 0 001.25-3.35h5.65v35h-7.1z" fill="#fff" fill-rule="evenodd"/></svg>
src/core/assets/images/step-2.svg ADDED
@@ -0,0 +1 @@
 
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 100 100"><circle cx="50" cy="50" r="50" fill="#ccc"/><path data-name="2" d="M38.53 41.23a12.807 12.807 0 012.4-4.5 10.792 10.792 0 014.02-3 13.616 13.616 0 015.58-1.08 13.905 13.905 0 014.57.75 11.871 11.871 0 013.83 2.15A10.329 10.329 0 0161.55 39a10.589 10.589 0 01.98 4.6 11 11 0 01-.85 4.55 12.168 12.168 0 01-2.25 3.38 18.894 18.894 0 01-3.18 2.67c-1.18.8-2.37 1.59-3.57 2.38s-2.37 1.62-3.5 2.52a16.035 16.035 0 00-3 3.15h16.55v6.1h-25.7a14.681 14.681 0 01.87-5.3 14.2 14.2 0 012.38-4.02 20.5 20.5 0 013.52-3.28c1.35-1 2.78-2.01 4.28-3.05.77-.53 1.58-1.07 2.45-1.62a15.537 15.537 0 002.37-1.83A9.286 9.286 0 0054.7 47a5.5 5.5 0 00.73-2.85 5.006 5.006 0 00-5.25-5.4 4.569 4.569 0 00-2.63.73 5.345 5.345 0 00-1.72 1.9 9.023 9.023 0 00-.93 2.6 15.122 15.122 0 00-.27 2.82h-6.8a16.741 16.741 0 01.7-5.57z" fill="#fff" fill-rule="evenodd"/></svg>
src/core/assets/images/step-complete.svg ADDED
@@ -0,0 +1 @@
 
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" viewBox="0 0 56.18 56.18"><circle cx="28.09" cy="28.09" r="25" fill="#6fb05a" stroke="#6ab255" stroke-width="6"/><path d="M36.93 19.88L24.09 32.72 19.37 28a.6.6 0 00-.83 0l-1.38 1.39a.573.573 0 000 .82l6.52 6.52a.573.573 0 00.82 0l14.64-14.64a.585.585 0 000-.83l-1.38-1.38a.585.585 0 00-.83 0z" fill="#fff" fill-rule="evenodd"/></svg>
src/core/assets/index.php ADDED
File without changes
src/core/assets/js/admin.js ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ (function ($) {
2
+
3
+ $('.loginwp-delete-prompt').on('click', function (e) {
4
+ e.preventDefault();
5
+ if (confirm(loginwp_globals.confirm_delete)) {
6
+ window.location.href = $(this).attr('href');
7
+ }
8
+ });
9
+
10
+ $(document).on('ready', function () {
11
+
12
+ $('#ptr-loginwp-condition-wrap select').on('change', function () {
13
+
14
+ var template = wp.template('loginwp-condition-' + this.value);
15
+
16
+ $('#ptr-loginwp-condition-value-wrap').html(
17
+ template()
18
+ );
19
+
20
+ $('.ptr-loginwp-order-wrap').toggle(
21
+ $.inArray(this.value, rul_conditions_order_support) !== -1
22
+ );
23
+ })
24
+ });
25
+
26
+ })(jQuery);
src/core/assets/js/index.php ADDED
File without changes
src/core/assets/js/profilepress.js ADDED
@@ -0,0 +1,178 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* global loginwp_pluginlanding, loginwp_installer_globals */
2
+
3
+ 'use strict';
4
+
5
+ var LoginWPPagesProfilePress = window.LoginWPPagesProfilePress || (function (document, window, $) {
6
+
7
+ var el = {};
8
+
9
+ var app = {
10
+
11
+ init: function () {
12
+
13
+ $(document).ready(app.ready);
14
+ },
15
+
16
+ ready: function () {
17
+
18
+ app.initVars();
19
+ app.events();
20
+ },
21
+
22
+ initVars: function () {
23
+
24
+ el = {
25
+ $stepInstall: $('section.step-install'),
26
+ $stepInstallNum: $('section.step-install .num img'),
27
+ $stepSetup: $('section.step-setup'),
28
+ $stepSetupNum: $('section.step-setup .num img'),
29
+ };
30
+ },
31
+
32
+ events: function () {
33
+
34
+ // Step 'Install' button click.
35
+ el.$stepInstall.on('click', 'button', app.stepInstallClick);
36
+
37
+ // Step 'Setup' button click.
38
+ el.$stepSetup.on('click', 'button', app.gotoURL);
39
+ },
40
+
41
+ stepInstallClick: function () {
42
+
43
+ var $btn = $(this),
44
+ action = $btn.attr('data-action'),
45
+ plugin = $btn.attr('data-plugin'),
46
+ ajaxAction = '';
47
+
48
+ if ($btn.hasClass('disabled')) {
49
+ return;
50
+ }
51
+
52
+ switch (action) {
53
+ case 'activate':
54
+ ajaxAction = 'loginwp_activate_plugin';
55
+ $btn.text(loginwp_pluginlanding.activating);
56
+ break;
57
+
58
+ case 'install':
59
+ ajaxAction = 'loginwp_install_plugin';
60
+ $btn.text(loginwp_pluginlanding.installing);
61
+ break;
62
+
63
+ case 'goto-url':
64
+ window.location.href = $btn.attr('data-url');
65
+ return;
66
+
67
+ default:
68
+ return;
69
+ }
70
+
71
+ $btn.addClass('disabled');
72
+ app.showSpinner(el.$stepInstallNum);
73
+
74
+ var data = {
75
+ action: ajaxAction,
76
+ nonce: loginwp_installer_globals.nonce,
77
+ plugin: plugin,
78
+ type: 'plugin',
79
+ };
80
+
81
+ $.post(ajaxurl, data)
82
+ .done(function (res) {
83
+ app.stepInstallDone(res, $btn, action);
84
+ })
85
+ .always(function () {
86
+ app.hideSpinner(el.$stepInstallNum);
87
+ });
88
+ },
89
+
90
+ /**
91
+ * Done part of the 'Install' step.
92
+ */
93
+ stepInstallDone: function (res, $btn, action) {
94
+
95
+ if (res.success) {
96
+ el.$stepInstallNum.attr('src', el.$stepInstallNum.attr('src').replace('step-1.', 'step-complete.'));
97
+ $btn.addClass('grey').text(loginwp_pluginlanding.activated);
98
+ app.stepInstallPluginStatus();
99
+ } else {
100
+ var url = 'install' === action ? loginwp_pluginlanding.manual_install_url : loginwp_pluginlanding.manual_activate_url,
101
+ msg = 'install' === action ? loginwp_pluginlanding.error_could_not_install : loginwp_pluginlanding.error_could_not_activate,
102
+ btn = 'install' === action ? loginwp_pluginlanding.download_now : loginwp_pluginlanding.plugins_page;
103
+
104
+ $btn.removeClass('grey disabled').text(btn).attr('data-action', 'goto-url').attr('data-url', url);
105
+ $btn.after('<p class="error">' + msg + '</p>');
106
+ }
107
+ },
108
+
109
+ /**
110
+ * Callback for step 'Install' completion.
111
+ */
112
+ stepInstallPluginStatus: function () {
113
+
114
+ var data = {
115
+ action: 'loginwp_profilepress_page_check_plugin_status',
116
+ nonce: loginwp_installer_globals.nonce,
117
+ };
118
+ $.post(ajaxurl, data)
119
+ .done(app.stepInstallPluginStatusDone);
120
+ },
121
+
122
+ /**
123
+ * Done part of the callback for step 'Install' completion.
124
+ */
125
+ stepInstallPluginStatusDone: function (res) {
126
+
127
+ if (!res.success) {
128
+ return;
129
+ }
130
+
131
+ el.$stepSetup.removeClass('grey');
132
+ el.$stepSetupBtn = el.$stepSetup.find('button');
133
+ el.$stepSetupBtn.removeClass('grey disabled');
134
+
135
+ if (res.data.setup_status > 0) {
136
+ el.$stepSetupNum.attr('src', el.$stepSetupNum.attr('src').replace('step-2.svg', 'step-complete.svg'));
137
+ el.$stepSetupBtn.text(loginwp_pluginlanding.smtp_settings_button);
138
+ }
139
+ },
140
+
141
+ /**
142
+ * Go to URL by click on the button.
143
+ */
144
+ gotoURL: function () {
145
+
146
+ var $btn = $(this);
147
+
148
+ if ($btn.hasClass('disabled')) {
149
+ return;
150
+ }
151
+
152
+ window.location.href = $btn.attr('data-url');
153
+ },
154
+
155
+ /**
156
+ * Display spinner.
157
+ */
158
+ showSpinner: function ($el) {
159
+
160
+ $el.siblings('.loader').removeClass('hidden');
161
+ },
162
+
163
+ /**
164
+ * Hide spinner.
165
+ */
166
+ hideSpinner: function ($el) {
167
+
168
+ $el.siblings('.loader').addClass('hidden');
169
+ },
170
+ };
171
+
172
+ // Provide access to public functions/properties.
173
+ return app;
174
+
175
+ }(document, window, jQuery));
176
+
177
+ // Initialize.
178
+ LoginWPPagesProfilePress.init();
src/core/composer.json ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "loginwp/core",
3
+ "description": "Core lib for LoginWP",
4
+ "type": "wordpress-plugin",
5
+ "autoload": {
6
+ "psr-4": {
7
+ "LoginWP\\Core\\": "src/"
8
+ },
9
+ "files": [
10
+ "src/MoAdminNotice.php",
11
+ "src/Functions.php"
12
+ ]
13
+ },
14
+ "require": {
15
+ "composer/installers": "~1.0",
16
+ "collizo4sky/persist-admin-notices-dismissal": "^1.4"
17
+ },
18
+ "config": {
19
+ "platform": {
20
+ "php": "5.6"
21
+ }
22
+ }
23
+ }
src/core/src/Admin/AbstractSettingsPage.php ADDED
@@ -0,0 +1,178 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin;
4
+
5
+ abstract class AbstractSettingsPage
6
+ {
7
+ public function __construct()
8
+ {
9
+ add_action('loginwp_register_menu_page', array($this, 'register_menu_page'));
10
+ }
11
+
12
+ abstract function register_menu_page();
13
+
14
+ abstract function header_menu_tabs();
15
+
16
+ abstract function default_header_menu();
17
+
18
+ public function settings_page_header($active_menu)
19
+ {
20
+ $logo_url = PTR_LOGINWP_ASSETS_URL . 'images/loginwp.png';
21
+ $submenus_count = count($this->header_menu_tabs());
22
+ ?>
23
+ <div class="loginwp-admin-banner<?= defined('LOGINWP_DETACH_LIBSODIUM') ? ' loginwp-pro' : '' ?><?= $submenus_count < 2 ? ' loginwp-no-submenu' : '' ?>">
24
+ <div class="loginwp-admin-banner__logo">
25
+ <img src="<?= $logo_url ?>" alt="">
26
+ </div>
27
+ <div class="loginwp-admin-banner__helplinks">
28
+ <?php if (defined('LOGINWP_DETACH_LIBSODIUM')) : ?>
29
+ <span><a rel="noopener" href="https://loginwp.com/submit-ticket/" target="_blank">
30
+ <span class="dashicons dashicons-admin-users"></span> <?= __('Request Support', 'peters-login-redirect'); ?>
31
+ </a></span>
32
+ <?php else : ?>
33
+ <span><a class="lwp-active" rel="noopener" href="https://loginwp.com/pricing/?utm_source=wp_dashboard&utm_medium=upgrade&utm_campaign=loginwp_header_topright_menu" target="_blank">
34
+ <span class="dashicons dashicons-info"></span> <?= __('Pro Upgrade', 'peters-login-redirect'); ?>
35
+ </a></span>
36
+ <?php endif; ?>
37
+ <span><a rel="noopener" href="https://wordpress.org/support/plugin/peters-login-redirect/reviews/?filter=5#new-post" target="_blank">
38
+ <span class="dashicons dashicons-star-filled"></span> <?= __('Review', 'peters-login-redirect'); ?>
39
+ </a></span>
40
+ <span><a rel="noopener" href="https://loginwp.com/docs/" target="_blank">
41
+ <span class="dashicons dashicons-book"></span> <?= __('Documentation', 'peters-login-redirect'); ?>
42
+ </a></span>
43
+ </div>
44
+ <div class="clear"></div>
45
+ <?php $this->settings_page_header_menus($active_menu); ?>
46
+ </div>
47
+ <?php
48
+ }
49
+
50
+ public function settings_page_header_menus($active_menu)
51
+ {
52
+ $menus = $this->header_menu_tabs();
53
+
54
+ if (count($menus) < 2) return;
55
+ ?>
56
+ <div class="loginwp-header-menus">
57
+ <nav class="loginwp-nav-tab-wrapper nav-tab-wrapper">
58
+ <?php foreach ($menus as $id => $menu) : ?>
59
+ <a href="<?php echo esc_url(remove_query_arg(wp_removable_query_args(), add_query_arg('tab', $id))); ?>" class="loginwp-nav-tab nav-tab<?= $id == $active_menu ? ' loginwp-nav-active' : '' ?>">
60
+ <?php echo $menu ?>
61
+ </a>
62
+ <?php endforeach; ?>
63
+ </nav>
64
+ </div>
65
+ <?php
66
+ }
67
+
68
+ public function admin_page_callback()
69
+ {
70
+ $active_menu = isset($_GET['tab']) ? sanitize_text_field($_GET['tab']) : $this->default_header_menu();
71
+
72
+ $this->settings_page_header($active_menu);
73
+
74
+ do_action('loginwp_admin_settings_page_' . $active_menu);
75
+ }
76
+
77
+ public static function sidebar_args()
78
+ {
79
+ $sidebar_args = [
80
+ [
81
+ 'section_title' => esc_html__('Upgrade to Pro', 'peters-login-redirect'),
82
+ 'content' => self::pro_upsell(),
83
+ ],
84
+ [
85
+ 'section_title' => esc_html__('Need Support?', 'peters-login-redirect'),
86
+ 'content' => self::sidebar_support_docs(),
87
+ ]
88
+ ];
89
+
90
+ if (defined('LOGINWP_DETACH_LIBSODIUM')) {
91
+ unset($sidebar_args[0]);
92
+ }
93
+
94
+ return $sidebar_args;
95
+ }
96
+
97
+ public static function pro_upsell()
98
+ {
99
+ $integrations = [
100
+ 'WooCommerce',
101
+ 'Gravity Forms',
102
+ 'WPForms',
103
+ 'LearnDash',
104
+ 'ProfilePress',
105
+ 'MemberPress',
106
+ 'Restrict Content Pro',
107
+ 'LifterLMS',
108
+ 'Easy Digital Downloads',
109
+ 'Ultimate Member',
110
+ 'WP User Frontend',
111
+ 'WP User Manager',
112
+ 'Paid Membership Pro',
113
+ 'User Registration (WPEverest)',
114
+ 'Theme My Login'
115
+ ];
116
+
117
+ $upsell_url = 'https://loginwp.com/pricing/?utm_source=wp_dashboard&utm_medium=upgrade&utm_campaign=sidebar_upsell';
118
+
119
+ $content = '<p>';
120
+ $content .= sprintf(
121
+ esc_html__('Enhance the power of LoginWP with the Pro version featuring integrations with many plugins. %sLearn more%s', 'peters-login-redirect'),
122
+ '<a target="_blank" href="' . $upsell_url . '">', '</a>'
123
+ );
124
+ $content .= '</p>';
125
+
126
+ $content .= '<ul>';
127
+
128
+ $content .= sprintf('<li>%s</li>', esc_html__('Redirect to referrer or previous page', 'peters-login-redirect'));
129
+ $content .= sprintf('<li>%s</li>', esc_html__('Redirect to currently viewing page', 'peters-login-redirect'));
130
+
131
+ foreach ($integrations as $integration) :
132
+ $content .= sprintf('<li>%s</li>', $integration);
133
+ endforeach;
134
+
135
+ $content .= '</ul>';
136
+
137
+ $content .= '<a href="' . $upsell_url . '" target="__blank" class="button-primary">' . esc_html__('Get LoginWP Pro →', 'peters-login-redirect') . '</a>';
138
+
139
+ return $content;
140
+ }
141
+
142
+ public static function sidebar_support_docs()
143
+ {
144
+ $link_icon = '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" width="24" height="24" class="linkIcon"><path d="M18.2 17c0 .7-.6 1.2-1.2 1.2H7c-.7 0-1.2-.6-1.2-1.2V7c0-.7.6-1.2 1.2-1.2h3.2V4.2H7C5.5 4.2 4.2 5.5 4.2 7v10c0 1.5 1.2 2.8 2.8 2.8h10c1.5 0 2.8-1.2 2.8-2.8v-3.6h-1.5V17zM14.9 3v1.5h3.7l-6.4 6.4 1.1 1.1 6.4-6.4v3.7h1.5V3h-6.3z"></path></svg>';
145
+
146
+ $content = '<p>';
147
+
148
+ $support_url = 'https://wordpress.org/support/plugin/peters-login-redirect/';
149
+
150
+ if (defined('LOGINWP_DETACH_LIBSODIUM')) {
151
+ $support_url = 'https://loginwp.com/submit-ticket/';
152
+ }
153
+
154
+ $content .= sprintf(
155
+ esc_html__('Whether you need help or have a new feature request, let us know. %sRequest Support%s', 'peters-login-redirect'),
156
+ '<a class="loginwp-link" href="' . $support_url . '" target="_blank">', $link_icon . '</a>'
157
+ );
158
+
159
+ $content .= '</p>';
160
+
161
+ $content .= '<p>';
162
+ $content .= sprintf(
163
+ esc_html__('Detailed documentation is also available on the plugin website. %sView Knowledge Base%s', 'peters-login-redirect'),
164
+ '<a class="loginwp-link" href="https://loginwp.com/docs/" target="_blank">', $link_icon . '</a>'
165
+ );
166
+
167
+ $content .= '</p>';
168
+
169
+ $content .= '<p>';
170
+ $content .= sprintf(
171
+ esc_html__('If you are enjoying LoginWP and find it useful, please consider leaving a ★★★★★ review on WordPress.org. %sLeave a Review%s', 'peters-login-redirect'),
172
+ '<a class="loginwp-link" href="https://wordpress.org/support/plugin/peters-login-redirect/reviews/?filter=5#new-post" target="_blank">', $link_icon . '</a>'
173
+ );
174
+ $content .= '</p>';
175
+
176
+ return $content;
177
+ }
178
+ }
src/core/src/Admin/Admin.php ADDED
@@ -0,0 +1,245 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin;
4
+
5
+ use PAnD;
6
+
7
+ class Admin
8
+ {
9
+ public function __construct()
10
+ {
11
+ SettingsPage::get_instance();
12
+ RedirectionsPage::get_instance();
13
+
14
+ add_action('admin_enqueue_scripts', array($this, 'admin_assets'));
15
+
16
+ add_filter('admin_footer_text', [$this, 'custom_admin_footer']);
17
+
18
+ add_action('admin_menu', array($this, 'register_core_menu'));
19
+
20
+ $basename = plugin_basename(PTR_LOGINWP_SYSTEM_FILE_PATH);
21
+ $prefix = is_network_admin() ? 'network_admin_' : '';
22
+ add_filter("{$prefix}plugin_action_links_$basename", [$this, 'loginwp_action_links'], 10, 4);
23
+
24
+ add_filter('plugin_row_meta', array(__CLASS__, 'plugin_row_meta'), 10, 2);
25
+
26
+ add_filter('removable_query_args', array($this, 'removable_query_args'));
27
+
28
+ if (class_exists('PAnD')) {
29
+ // persist admin notice dismissal initialization
30
+ add_action('admin_init', array('PAnD', 'init'));
31
+ }
32
+
33
+ add_action('admin_init', array($this, 'act_on_request'));
34
+ }
35
+
36
+ public function register_core_menu()
37
+ {
38
+ add_menu_page(
39
+ __('Settings – LoginWP', 'peters-login-redirect'),
40
+ __('LoginWP', 'peters-login-redirect'),
41
+ 'manage_options',
42
+ PTR_LOGINWP_SETTINGS_PAGE_SLUG,
43
+ '',
44
+ $this->getMenuIcon(),
45
+ '80.0015'
46
+ );
47
+
48
+ do_action('loginwp_register_menu_page');
49
+
50
+ do_action('loginwp_admin_hooks');
51
+
52
+ add_filter('admin_body_class', [$this, 'add_admin_body_class']);
53
+
54
+ add_action('admin_notices', [$this, 'review_plugin_notice']);
55
+ add_action('admin_notices', [$this, 'ptlr_is_now_loginwp_notice']);
56
+ }
57
+
58
+ public function act_on_request()
59
+ {
60
+ if ( ! empty($_GET['loginwp_admin_action'])) {
61
+
62
+ if ($_GET['loginwp_admin_action'] == 'dismiss_leave_review_forever') {
63
+ PAnD::set_admin_notice_cache('loginwp-review-plugin-notice', 'forever');
64
+ }
65
+
66
+ if ($_GET['loginwp_admin_action'] == 'dismiss_ptlr_now_loginwp') {
67
+ PAnD::set_admin_notice_cache('ptlr_is_now_loginwp_notice', 'forever');
68
+ }
69
+
70
+ wp_safe_redirect(esc_url_raw(remove_query_arg('loginwp_admin_action')));
71
+ exit;
72
+ }
73
+ }
74
+
75
+ public function admin_assets()
76
+ {
77
+ if (isset(get_current_screen()->base) && strpos(get_current_screen()->base, 'loginwp') !== false) {
78
+ wp_enqueue_style('ptr-loginwp-admin', PTR_LOGINWP_ASSETS_URL . 'css/admin.css', [], PTR_LOGINWP_VERSION_NUMBER);
79
+ wp_enqueue_script('ptr-loginwp-admin', PTR_LOGINWP_ASSETS_URL . 'js/admin.js', ['jquery', 'wp-util'], PTR_LOGINWP_VERSION_NUMBER, true);
80
+
81
+ wp_localize_script('ptr-loginwp-admin', 'loginwp_globals', [
82
+ 'confirm_delete' => esc_html__('Are you sure?', 'peters-login-redirect')
83
+ ]);
84
+ }
85
+ }
86
+
87
+ public function add_admin_body_class($classes)
88
+ {
89
+ $current_screen = get_current_screen();
90
+
91
+ if (empty ($current_screen)) return $classes;
92
+
93
+ if (false !== strpos($current_screen->id, 'loginwp')) {
94
+ // Leave space on both sides so other plugins do not conflict.
95
+ $classes .= ' loginwp-admin ';
96
+ }
97
+
98
+ return $classes;
99
+ }
100
+
101
+ public function custom_admin_footer($text)
102
+ {
103
+ if (strpos(loginwpGET_var('page'), 'loginwp') !== false) {
104
+ $text = sprintf(
105
+ __('Thank you for using LoginWP. Please rate the plugin %1$s on %2$sWordPress.org%3$s to help us spread the word.', 'block-visibility'),
106
+ '<a href="https://wordpress.org/support/plugin/peters-login-redirect/reviews/?filter=5#new-post" target="_blank" rel="noopener noreferrer">★★★★★</a>',
107
+ '<a href="https://wordpress.org/support/plugin/peters-login-redirect/reviews/?filter=5#new-post" target="_blank" rel="noopener">',
108
+ '</a>'
109
+ );
110
+ }
111
+
112
+ return $text;
113
+ }
114
+
115
+ private function getMenuIcon()
116
+ {
117
+ return 'data:image/svg+xml;base64,' . base64_encode('<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" fill-rule="evenodd" image-rendering="optimizeQuality" shape-rendering="geometricPrecision" viewBox="0 0 58.78 58.78" xmlns:v="https://vecta.io/nano"><path d="M55.87 25.04c.81.76 1.31 1.84 1.31 3.03v25.57a4.19 4.19 0 0 1-4.17 4.17H32.35c-1-17.92 4.14-19.85 4.14-24.27 0-3.92-3.18-7.1-7.1-7.1s-7.1 3.18-7.1 7.1c0 4.42 5.14 6.34 4.14 24.27H5.77a4.19 4.19 0 0 1-4.17-4.17V28.07a4.14 4.14 0 0 1 1.42-3.12L26.69 2.1c.69-.69 1.65-1.12 2.71-1.12 1.08 0 1.94.4 2.71 1.12 3.79 3.55 7.52 7.26 11.26 10.87l12.52 12.08z" fill="#a6aaad"/></svg>');
118
+ }
119
+
120
+ /**
121
+ * Action links in plugin listing page.
122
+ */
123
+ public function loginwp_action_links($actions, $plugin_file, $plugin_data, $context)
124
+ {
125
+ $custom_actions = array(
126
+ 'loginwp_redirections' => sprintf('<a href="%s">%s</a>', PTR_LOGINWP_REDIRECTIONS_PAGE_URL, __('Settings', 'peters-login-redirect')),
127
+ );
128
+
129
+ if ( ! defined('LOGINWP_DETACH_LIBSODIUM')) {
130
+ $custom_actions['loginwp_upgrade'] = sprintf(
131
+ '<a style="color:#d54e21;font-weight:bold" href="%s" target="_blank">%s</a>', 'https://loginwp.com/pricing/?utm_source=wp_dashboard&utm_medium=upgrade&utm_campaign=action_link',
132
+ __('Go Premium', 'peters-login-redirect')
133
+ );
134
+ }
135
+
136
+ // add the links to the front of the actions list
137
+ return array_merge($custom_actions, $actions);
138
+ }
139
+
140
+ /**
141
+ * Show row meta on the plugin screen.
142
+ *
143
+ * @param mixed $links Plugin Row Meta
144
+ * @param mixed $file Plugin Base file
145
+ *
146
+ * @return array
147
+ */
148
+ public static function plugin_row_meta($links, $file)
149
+ {
150
+ if (strpos($file, 'wplogin_redirect.php') !== false) {
151
+ $row_meta = array(
152
+ 'docs' => '<a target="_blank" href="' . esc_url('https://loginwp.com/docs/') . '" aria-label="' . esc_attr__('View LoginWP documentation', 'peters-login-redirect') . '">' . esc_html__('Docs', 'peters-login-redirect') . '</a>',
153
+ 'support' => '<a target="_blank" href="' . esc_url('https://loginwp.com/support/') . '" aria-label="' . esc_attr__('Visit customer support', 'peters-login-redirect') . '">' . esc_html__('Support', 'peters-login-redirect') . '</a>',
154
+ );
155
+
156
+ if ( ! defined('LOGINWP_DETACH_LIBSODIUM')) {
157
+ $url = 'https://loginwp.com/pricing/?utm_source=wp_dashboard&utm_medium=upgrade&utm_campaign=row_meta';
158
+ $row_meta['upgrade_pro'] = '<a target="_blank" style="color:#d54e21;font-weight:bold" href="' . esc_url($url) . '" aria-label="' . esc_attr__('Upgrade to PRO', 'peters-login-redirect') . '">' . esc_html__('Go Premium', 'peters-login-redirect') . '</a>';
159
+ }
160
+
161
+ return array_merge($links, $row_meta);
162
+ }
163
+
164
+ return (array)$links;
165
+ }
166
+
167
+ public function ptlr_is_now_loginwp_notice()
168
+ {
169
+ if ( ! PAnD::is_admin_notice_active('ptlr_is_now_loginwp_notice-forever')) return;
170
+
171
+ if (get_option('loginwp_from_ab_initio', false) == 'true') return;
172
+
173
+ $dismiss_url = esc_url(add_query_arg('loginwp_admin_action', 'dismiss_ptlr_now_loginwp'));
174
+
175
+ $notice = sprintf(
176
+ __('Important news! %1$sPeters Login Redirect%2$s has been rebranded to %1$sLoginWP%2$s with a new UI. %3$sCheck It Out%5$s | %4$sDismiss Notice%5$s', 'peters-login-redirect'),
177
+ '<strong>', '</strong>',
178
+ '<a href="' . PTR_LOGINWP_REDIRECTIONS_PAGE_URL . '">', '<a href="' . $dismiss_url . '">', '</a>'
179
+ );
180
+
181
+ echo '<div data-dismissible="ptlr_is_now_loginwp_notice-forever" class="notice notice-warning is-dismissible">';
182
+ echo "<p>$notice</p>";
183
+ echo '</div>';
184
+ }
185
+
186
+ /**
187
+ * Display one-time admin notice to review plugin at least 7 days after installation
188
+ */
189
+ public function review_plugin_notice()
190
+ {
191
+ if ( ! PAnD::is_admin_notice_active('loginwp-review-plugin-notice-forever')) return;
192
+
193
+ $install_date = get_option('loginwp_install_date', '');
194
+
195
+ if (empty($install_date)) return;
196
+
197
+ $diff = round((time() - strtotime($install_date)) / 24 / 60 / 60);
198
+
199
+ if ($diff < 7) return;
200
+
201
+ $review_url = 'https://wordpress.org/support/plugin/peters-login-redirect/reviews/?filter=5#new-post';
202
+
203
+ $dismiss_url = esc_url_raw(add_query_arg('loginwp_admin_action', 'dismiss_leave_review_forever'));
204
+
205
+ $notice = sprintf(
206
+ __('Hey, I noticed you have been using LoginWP (Formerly Peter\'s Login Redirect) for a while now - that\'s awesome! Could you please do me a BIG favor and give it a %1$s5-star rating on WordPress?%2$s This will help us spread the word and boost our motivation - thanks!', 'peters-login-redirect'),
207
+ '<a href="' . $review_url . '" target="_blank">',
208
+ '</a>'
209
+ );
210
+ $label = __('Sure! I\'d love to give a review', 'peters-login-redirect');
211
+
212
+ $dismiss_label = __('Dismiss', 'peters-login-redirect');
213
+
214
+ $notice .= "<div style=\"margin:10px 0 0;\"><a href=\"$review_url\" target='_blank' class=\"button-primary\">$label</a></div>";
215
+ $notice .= "<div style=\"margin:10px 0 0;\"><a href=\"$dismiss_url\">$dismiss_label</a></div>";
216
+
217
+ echo '<div data-dismissible="loginwp-review-plugin-notice-forever" class="update-nag notice notice-warning is-dismissible">';
218
+ echo "<p>$notice</p>";
219
+ echo '</div>';
220
+ }
221
+
222
+
223
+
224
+ public function removable_query_args($args)
225
+ {
226
+ $args[] = 'license-settings-updated';
227
+ $args[] = 'license';
228
+
229
+ return $args;
230
+ }
231
+
232
+ /**
233
+ * @return self
234
+ */
235
+ public static function get_instance()
236
+ {
237
+ static $instance = null;
238
+
239
+ if (is_null($instance)) {
240
+ $instance = new self();
241
+ }
242
+
243
+ return $instance;
244
+ }
245
+ }
src/core/src/Admin/Installer/LoginWP_Install_Skin.php ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin\Installer;
4
+
5
+ /**
6
+ * Skin for on-the-fly addon installations.
7
+ *
8
+ * Extend PluginSilentUpgraderSkin and clean up the class.
9
+ */
10
+ class LoginWP_Install_Skin extends PluginSilentUpgraderSkin {
11
+
12
+ /**
13
+ * Instead of outputting HTML for errors, json_encode the errors and send them
14
+ * back to the Ajax script for processing.
15
+ *
16
+ * @since 1.0.0
17
+ *
18
+ * @param array $errors Array of errors with the install process.
19
+ */
20
+ public function error( $errors ) {
21
+
22
+ if ( ! empty( $errors ) ) {
23
+ wp_send_json_error( $errors );
24
+ }
25
+ }
26
+ }
src/core/src/Admin/Installer/PluginSilentUpgrader.php ADDED
@@ -0,0 +1,592 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin\Installer;
4
+
5
+ use WP_Error;
6
+ use WP_Upgrader;
7
+ use WP_Filesystem_Base;
8
+
9
+ /** \WP_Upgrader class */
10
+ require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php';
11
+
12
+ /** \Plugin_Upgrader class */
13
+ require_once ABSPATH . 'wp-admin/includes/class-plugin-upgrader.php';
14
+
15
+ /**
16
+ * In WP 5.3 a PHP 5.6 splat operator (...$args) was added to \WP_Upgrader_Skin::feedback().
17
+ * We need to remove all calls to *Skin::feedback() method, as we can't override it in own Skins
18
+ * without breaking support for PHP 5.3-5.5.
19
+ *
20
+ * @internal Please do not use this class outside of core ProfilePress development. May be removed at any time.
21
+ */
22
+ class PluginSilentUpgrader extends \Plugin_Upgrader {
23
+
24
+ /**
25
+ * Run an upgrade/installation.
26
+ *
27
+ * Attempt to download the package (if it is not a local file), unpack it, and
28
+ * install it in the destination folder.
29
+ *
30
+ * @param array $options {
31
+ * Array or string of arguments for upgrading/installing a package.
32
+ *
33
+ * @type string $package The full path or URI of the package to install.
34
+ * Default empty.
35
+ * @type string $destination The full path to the destination folder.
36
+ * Default empty.
37
+ * @type bool $clear_destination Whether to delete any files already in the
38
+ * destination folder. Default false.
39
+ * @type bool $clear_working Whether to delete the files form the working
40
+ * directory after copying to the destination.
41
+ * Default false.
42
+ * @type bool $abort_if_destination_exists Whether to abort the installation if the destination
43
+ * folder already exists. When true, `$clear_destination`
44
+ * should be false. Default true.
45
+ * @type bool $is_multi Whether this run is one of multiple upgrade/installation
46
+ * actions being performed in bulk. When true, the skin
47
+ * WP_Upgrader::header() and WP_Upgrader::footer()
48
+ * aren't called. Default false.
49
+ * @type array $hook_extra Extra arguments to pass to the filter hooks called by
50
+ * WP_Upgrader::run().
51
+ * }
52
+ * @return array|false|WP_error The result from self::install_package() on success, otherwise a WP_Error,
53
+ * or false if unable to connect to the filesystem.
54
+ */
55
+ public function run( $options ) {
56
+
57
+ $defaults = array(
58
+ 'package' => '', // Please always pass this.
59
+ 'destination' => '', // And this
60
+ 'clear_destination' => false,
61
+ 'abort_if_destination_exists' => true, // Abort if the Destination directory exists, Pass clear_destination as false please
62
+ 'clear_working' => true,
63
+ 'is_multi' => false,
64
+ 'hook_extra' => array(), // Pass any extra $hook_extra args here, this will be passed to any hooked filters.
65
+ );
66
+
67
+ $options = wp_parse_args( $options, $defaults );
68
+
69
+ /**
70
+ * Filter the package options before running an update.
71
+ *
72
+ * See also {@see 'upgrader_process_complete'}.
73
+ *
74
+ * @since 4.3.0
75
+ *
76
+ * @param array $options {
77
+ * Options used by the upgrader.
78
+ *
79
+ * @type string $package Package for update.
80
+ * @type string $destination Update location.
81
+ * @type bool $clear_destination Clear the destination resource.
82
+ * @type bool $clear_working Clear the working resource.
83
+ * @type bool $abort_if_destination_exists Abort if the Destination directory exists.
84
+ * @type bool $is_multi Whether the upgrader is running multiple times.
85
+ * @type array $hook_extra {
86
+ * Extra hook arguments.
87
+ *
88
+ * @type string $action Type of action. Default 'update'.
89
+ * @type string $type Type of update process. Accepts 'plugin', 'theme', or 'core'.
90
+ * @type bool $bulk Whether the update process is a bulk update. Default true.
91
+ * @type string $plugin Path to the plugin file relative to the plugins directory.
92
+ * @type string $theme The stylesheet or template name of the theme.
93
+ * @type string $language_update_type The language pack update type. Accepts 'plugin', 'theme',
94
+ * or 'core'.
95
+ * @type object $language_update The language pack update offer.
96
+ * }
97
+ * }
98
+ */
99
+ $options = apply_filters( 'upgrader_package_options', $options );
100
+
101
+ if ( ! $options['is_multi'] ) { // call $this->header separately if running multiple times
102
+ $this->skin->header();
103
+ }
104
+
105
+ // Connect to the Filesystem first.
106
+ $res = $this->fs_connect( array( WP_CONTENT_DIR, $options['destination'] ) );
107
+ // Mainly for non-connected filesystem.
108
+ if ( ! $res ) {
109
+ if ( ! $options['is_multi'] ) {
110
+ $this->skin->footer();
111
+ }
112
+ return false;
113
+ }
114
+
115
+ $this->skin->before();
116
+
117
+ if ( is_wp_error( $res ) ) {
118
+ $this->skin->error( $res );
119
+ $this->skin->after();
120
+ if ( ! $options['is_multi'] ) {
121
+ $this->skin->footer();
122
+ }
123
+ return $res;
124
+ }
125
+
126
+ /*
127
+ * Download the package (Note, This just returns the filename
128
+ * of the file if the package is a local file)
129
+ */
130
+ $download = $this->download_package( $options['package'], true );
131
+
132
+ // Allow for signature soft-fail.
133
+ // WARNING: This may be removed in the future.
134
+ if ( is_wp_error( $download ) && $download->get_error_data( 'softfail-filename' ) ) {
135
+
136
+ // Don't output the 'no signature could be found' failure message for now.
137
+ if ( 'signature_verification_no_signature' != $download->get_error_code() || WP_DEBUG ) {
138
+ // Outout the failure error as a normal feedback, and not as an error:
139
+ //$this->skin->feedback( $download->get_error_message() );
140
+
141
+ // Report this failure back to WordPress.org for debugging purposes.
142
+ wp_version_check(
143
+ array(
144
+ 'signature_failure_code' => $download->get_error_code(),
145
+ 'signature_failure_data' => $download->get_error_data(),
146
+ )
147
+ );
148
+ }
149
+
150
+ // Pretend this error didn't happen.
151
+ $download = $download->get_error_data( 'softfail-filename' );
152
+ }
153
+
154
+ if ( is_wp_error( $download ) ) {
155
+ $this->skin->error( $download );
156
+ $this->skin->after();
157
+ if ( ! $options['is_multi'] ) {
158
+ $this->skin->footer();
159
+ }
160
+ return $download;
161
+ }
162
+
163
+ $delete_package = ( $download != $options['package'] ); // Do not delete a "local" file
164
+
165
+ // Unzips the file into a temporary directory.
166
+ $working_dir = $this->unpack_package( $download, $delete_package );
167
+ if ( is_wp_error( $working_dir ) ) {
168
+ $this->skin->error( $working_dir );
169
+ $this->skin->after();
170
+ if ( ! $options['is_multi'] ) {
171
+ $this->skin->footer();
172
+ }
173
+ return $working_dir;
174
+ }
175
+
176
+ // With the given options, this installs it to the destination directory.
177
+ $result = $this->install_package(
178
+ array(
179
+ 'source' => $working_dir,
180
+ 'destination' => $options['destination'],
181
+ 'clear_destination' => $options['clear_destination'],
182
+ 'abort_if_destination_exists' => $options['abort_if_destination_exists'],
183
+ 'clear_working' => $options['clear_working'],
184
+ 'hook_extra' => $options['hook_extra'],
185
+ )
186
+ );
187
+
188
+ $this->skin->set_result( $result );
189
+ if ( is_wp_error( $result ) ) {
190
+ $this->skin->error( $result );
191
+ //$this->skin->feedback( 'process_failed' );
192
+ } else {
193
+ // Installation succeeded.
194
+ //$this->skin->feedback( 'process_success' );
195
+ }
196
+
197
+ $this->skin->after();
198
+
199
+ if ( ! $options['is_multi'] ) {
200
+
201
+ /**
202
+ * Fire when the upgrader process is complete.
203
+ *
204
+ * See also {@see 'upgrader_package_options'}.
205
+ *
206
+ * @since 3.6.0
207
+ * @since 3.7.0 Added to WP_Upgrader::run().
208
+ * @since 4.6.0 `$translations` was added as a possible argument to `$hook_extra`.
209
+ *
210
+ * @param WP_Upgrader $this WP_Upgrader instance. In other contexts, $this, might be a
211
+ * Theme_Upgrader, Plugin_Upgrader, Core_Upgrade, or Language_Pack_Upgrader instance.
212
+ * @param array $hook_extra {
213
+ * Array of bulk item update data.
214
+ *
215
+ * @type string $action Type of action. Default 'update'.
216
+ * @type string $type Type of update process. Accepts 'plugin', 'theme', 'translation', or 'core'.
217
+ * @type bool $bulk Whether the update process is a bulk update. Default true.
218
+ * @type array $plugins Array of the basename paths of the plugins' main files.
219
+ * @type array $themes The theme slugs.
220
+ * @type array $translations {
221
+ * Array of translations update data.
222
+ *
223
+ * @type string $language The locale the translation is for.
224
+ * @type string $type Type of translation. Accepts 'plugin', 'theme', or 'core'.
225
+ * @type string $slug Text domain the translation is for. The slug of a theme/plugin or
226
+ * 'default' for core translations.
227
+ * @type string $version The version of a theme, plugin, or core.
228
+ * }
229
+ * }
230
+ */
231
+ do_action( 'upgrader_process_complete', $this, $options['hook_extra'] );
232
+
233
+ $this->skin->footer();
234
+ }
235
+
236
+ return $result;
237
+ }
238
+
239
+ /**
240
+ * Toggle maintenance mode for the site.
241
+ *
242
+ * Create/delete the maintenance file to enable/disable maintenance mode.
243
+ *
244
+ * @since 2.8.0
245
+ *
246
+ * @global WP_Filesystem_Base $wp_filesystem Subclass
247
+ *
248
+ * @param bool $enable True to enable maintenance mode, false to disable.
249
+ */
250
+ public function maintenance_mode( $enable = false ) {
251
+ global $wp_filesystem;
252
+ $file = $wp_filesystem->abspath() . '.maintenance';
253
+ if ( $enable ) {
254
+ //$this->skin->feedback( 'maintenance_start' );
255
+ // Create maintenance file to signal that we are upgrading
256
+ $maintenance_string = '<?php $upgrading = ' . time() . '; ?>';
257
+ $wp_filesystem->delete( $file );
258
+ $wp_filesystem->put_contents( $file, $maintenance_string, FS_CHMOD_FILE );
259
+ } elseif ( ! $enable && $wp_filesystem->exists( $file ) ) {
260
+ //$this->skin->feedback( 'maintenance_end' );
261
+ $wp_filesystem->delete( $file );
262
+ }
263
+ }
264
+
265
+ /**
266
+ * Download a package.
267
+ *
268
+ * @since 2.8.0
269
+ * @since 5.5.0 Added the `$hook_extra` parameter.
270
+ *
271
+ * @param string $package The URI of the package. If this is the full path to an
272
+ * existing local file, it will be returned untouched.
273
+ * @param bool $check_signatures Whether to validate file signatures. Default false.
274
+ * @param array $hook_extra Extra arguments to pass to the filter hooks. Default empty array.
275
+ * @return string|WP_Error The full path to the downloaded package file, or a WP_Error object.
276
+ */
277
+ public function download_package( $package, $check_signatures = false, $hook_extra = array() ) {
278
+
279
+ /**
280
+ * Filters whether to return the package.
281
+ *
282
+ * @since 3.7.0
283
+ * @since 5.5.0 Added the `$hook_extra` parameter.
284
+ *
285
+ * @param bool $reply Whether to bail without returning the package.
286
+ * Default false.
287
+ * @param string $package The package file name.
288
+ * @param WP_Upgrader $this The WP_Upgrader instance.
289
+ * @param array $hook_extra Extra arguments passed to hooked filters.
290
+ */
291
+ $reply = apply_filters( 'upgrader_pre_download', false, $package, $this, $hook_extra );
292
+ if ( false !== $reply ) {
293
+ return $reply;
294
+ }
295
+
296
+ if ( ! preg_match( '!^(http|https|ftp)://!i', $package ) && file_exists( $package ) ) { // Local file or remote?
297
+ return $package; // Must be a local file.
298
+ }
299
+
300
+ if ( empty( $package ) ) {
301
+ return new WP_Error( 'no_package', $this->strings['no_package'] );
302
+ }
303
+
304
+ //$this->skin->feedback( 'downloading_package', $package );
305
+
306
+ $download_file = download_url( $package, 300, $check_signatures );
307
+
308
+ if ( is_wp_error( $download_file ) && ! $download_file->get_error_data( 'softfail-filename' ) ) {
309
+ return new WP_Error( 'download_failed', $this->strings['download_failed'], $download_file->get_error_message() );
310
+ }
311
+
312
+ return $download_file;
313
+ }
314
+
315
+ /**
316
+ * Unpack a compressed package file.
317
+ *
318
+ * @since 2.8.0
319
+ *
320
+ * @global WP_Filesystem_Base $wp_filesystem WordPress filesystem subclass.
321
+ *
322
+ * @param string $package Full path to the package file.
323
+ * @param bool $delete_package Optional. Whether to delete the package file after attempting
324
+ * to unpack it. Default true.
325
+ * @return string|WP_Error The path to the unpacked contents, or a WP_Error on failure.
326
+ */
327
+ public function unpack_package( $package, $delete_package = true ) {
328
+ global $wp_filesystem;
329
+
330
+ //$this->skin->feedback( 'unpack_package' );
331
+
332
+ $upgrade_folder = $wp_filesystem->wp_content_dir() . 'upgrade/';
333
+
334
+ //Clean up contents of upgrade directory beforehand.
335
+ $upgrade_files = $wp_filesystem->dirlist( $upgrade_folder );
336
+ if ( ! empty( $upgrade_files ) ) {
337
+ foreach ( $upgrade_files as $file ) {
338
+ $wp_filesystem->delete( $upgrade_folder . $file['name'], true );
339
+ }
340
+ }
341
+
342
+ // We need a working directory - Strip off any .tmp or .zip suffixes
343
+ $working_dir = $upgrade_folder . basename( basename( $package, '.tmp' ), '.zip' );
344
+
345
+ // Clean up working directory
346
+ if ( $wp_filesystem->is_dir( $working_dir ) ) {
347
+ $wp_filesystem->delete( $working_dir, true );
348
+ }
349
+
350
+ // Unzip package to working directory
351
+ $result = unzip_file( $package, $working_dir );
352
+
353
+ // Once extracted, delete the package if required.
354
+ if ( $delete_package ) {
355
+ unlink( $package );
356
+ }
357
+
358
+ if ( is_wp_error( $result ) ) {
359
+ $wp_filesystem->delete( $working_dir, true );
360
+ if ( 'incompatible_archive' == $result->get_error_code() ) {
361
+ return new WP_Error( 'incompatible_archive', $this->strings['incompatible_archive'], $result->get_error_data() );
362
+ }
363
+ return $result;
364
+ }
365
+
366
+ return $working_dir;
367
+ }
368
+
369
+ /**
370
+ * Install a package.
371
+ *
372
+ * Copies the contents of a package form a source directory, and installs them in
373
+ * a destination directory. Optionally removes the source. It can also optionally
374
+ * clear out the destination folder if it already exists.
375
+ *
376
+ * @since 2.8.0
377
+ *
378
+ * @global WP_Filesystem_Base $wp_filesystem WordPress filesystem subclass.
379
+ * @global array $wp_theme_directories
380
+ *
381
+ * @param array|string $args {
382
+ * Optional. Array or string of arguments for installing a package. Default empty array.
383
+ *
384
+ * @type string $source Required path to the package source. Default empty.
385
+ * @type string $destination Required path to a folder to install the package in.
386
+ * Default empty.
387
+ * @type bool $clear_destination Whether to delete any files already in the destination
388
+ * folder. Default false.
389
+ * @type bool $clear_working Whether to delete the files form the working directory
390
+ * after copying to the destination. Default false.
391
+ * @type bool $abort_if_destination_exists Whether to abort the installation if
392
+ * the destination folder already exists. Default true.
393
+ * @type array $hook_extra Extra arguments to pass to the filter hooks called by
394
+ * WP_Upgrader::install_package(). Default empty array.
395
+ * }
396
+ *
397
+ * @return array|WP_Error The result (also stored in `WP_Upgrader::$result`), or a WP_Error on failure.
398
+ */
399
+ public function install_package( $args = array() ) {
400
+ global $wp_filesystem, $wp_theme_directories;
401
+
402
+ $defaults = array(
403
+ 'source' => '', // Please always pass this
404
+ 'destination' => '', // and this
405
+ 'clear_destination' => false,
406
+ 'clear_working' => false,
407
+ 'abort_if_destination_exists' => true,
408
+ 'hook_extra' => array(),
409
+ );
410
+
411
+ $args = wp_parse_args( $args, $defaults );
412
+
413
+ // These were previously extract()'d.
414
+ $source = $args['source'];
415
+ $destination = $args['destination'];
416
+ $clear_destination = $args['clear_destination'];
417
+
418
+ if ( function_exists( 'set_time_limit' ) && false === strpos( ini_get( 'disable_functions' ), 'set_time_limit' ) && ! ini_get( 'safe_mode' ) ) {
419
+ @set_time_limit( 300 );
420
+ }
421
+
422
+ if ( empty( $source ) || empty( $destination ) ) {
423
+ return new WP_Error( 'bad_request', $this->strings['bad_request'] );
424
+ }
425
+ //$this->skin->feedback( 'installing_package' );
426
+
427
+ /**
428
+ * Filter the install response before the installation has started.
429
+ *
430
+ * Returning a truthy value, or one that could be evaluated as a WP_Error
431
+ * will effectively short-circuit the installation, returning that value
432
+ * instead.
433
+ *
434
+ * @since 2.8.0
435
+ *
436
+ * @param bool|WP_Error $response Response.
437
+ * @param array $hook_extra Extra arguments passed to hooked filters.
438
+ */
439
+ $res = apply_filters( 'upgrader_pre_install', true, $args['hook_extra'] );
440
+
441
+ if ( is_wp_error( $res ) ) {
442
+ return $res;
443
+ }
444
+
445
+ //Retain the Original source and destinations
446
+ $remote_source = $args['source'];
447
+ $local_destination = $destination;
448
+
449
+ $source_files = array_keys( $wp_filesystem->dirlist( $remote_source ) );
450
+ $remote_destination = $wp_filesystem->find_folder( $local_destination );
451
+
452
+ //Locate which directory to copy to the new folder, This is based on the actual folder holding the files.
453
+ if ( 1 == count( $source_files ) && $wp_filesystem->is_dir( trailingslashit( $args['source'] ) . $source_files[0] . '/' ) ) { //Only one folder? Then we want its contents.
454
+ $source = trailingslashit( $args['source'] ) . trailingslashit( $source_files[0] );
455
+ } elseif ( count( $source_files ) == 0 ) {
456
+ return new WP_Error( 'incompatible_archive_empty', $this->strings['incompatible_archive'], $this->strings['no_files'] ); // There are no files?
457
+ } else { // It's only a single file, the upgrader will use the folder name of this file as the destination folder. Folder name is based on zip filename.
458
+ $source = trailingslashit( $args['source'] );
459
+ }
460
+
461
+ /**
462
+ * Filter the source file location for the upgrade package.
463
+ *
464
+ * @since 2.8.0
465
+ * @since 4.4.0 The $hook_extra parameter became available.
466
+ *
467
+ * @param string $source File source location.
468
+ * @param string $remote_source Remote file source location.
469
+ * @param WP_Upgrader $this WP_Upgrader instance.
470
+ * @param array $hook_extra Extra arguments passed to hooked filters.
471
+ */
472
+ $source = apply_filters( 'upgrader_source_selection', $source, $remote_source, $this, $args['hook_extra'] );
473
+
474
+ if ( is_wp_error( $source ) ) {
475
+ return $source;
476
+ }
477
+
478
+ // Has the source location changed? If so, we need a new source_files list.
479
+ if ( $source !== $remote_source ) {
480
+ $source_files = array_keys( $wp_filesystem->dirlist( $source ) );
481
+ }
482
+
483
+ /*
484
+ * Protection against deleting files in any important base directories.
485
+ * Theme_Upgrader & Plugin_Upgrader also trigger this, as they pass the
486
+ * destination directory (WP_PLUGIN_DIR / wp-content/themes) intending
487
+ * to copy the directory into the directory, whilst they pass the source
488
+ * as the actual files to copy.
489
+ */
490
+ $protected_directories = array( ABSPATH, WP_CONTENT_DIR, WP_PLUGIN_DIR, WP_CONTENT_DIR . '/themes' );
491
+
492
+ if ( is_array( $wp_theme_directories ) ) {
493
+ $protected_directories = array_merge( $protected_directories, $wp_theme_directories );
494
+ }
495
+
496
+ if ( in_array( $destination, $protected_directories ) ) {
497
+ $remote_destination = trailingslashit( $remote_destination ) . trailingslashit( basename( $source ) );
498
+ $destination = trailingslashit( $destination ) . trailingslashit( basename( $source ) );
499
+ }
500
+
501
+ if ( $clear_destination ) {
502
+ // We're going to clear the destination if there's something there.
503
+ //$this->skin->feedback( 'remove_old' );
504
+
505
+ $removed = $this->clear_destination( $remote_destination );
506
+
507
+ /**
508
+ * Filter whether the upgrader cleared the destination.
509
+ *
510
+ * @param mixed $removed Whether the destination was cleared. true on success, WP_Error on failure
511
+ * @param string $local_destination The local package destination.
512
+ * @param string $remote_destination The remote package destination.
513
+ * @param array $hook_extra Extra arguments passed to hooked filters.
514
+ */
515
+ $removed = apply_filters( 'upgrader_clear_destination', $removed, $local_destination, $remote_destination, $args['hook_extra'] );
516
+
517
+ if ( is_wp_error( $removed ) ) {
518
+ return $removed;
519
+ }
520
+ } elseif ( $args['abort_if_destination_exists'] && $wp_filesystem->exists( $remote_destination ) ) {
521
+ //If we're not clearing the destination folder and something exists there already, Bail.
522
+ //But first check to see if there are actually any files in the folder.
523
+ $_files = $wp_filesystem->dirlist( $remote_destination );
524
+ if ( ! empty( $_files ) ) {
525
+ $wp_filesystem->delete( $remote_source, true ); //Clear out the source files.
526
+ return new WP_Error( 'folder_exists', $this->strings['folder_exists'], $remote_destination );
527
+ }
528
+ }
529
+
530
+ //Create destination if needed
531
+ if ( ! $wp_filesystem->exists( $remote_destination ) ) {
532
+ if ( ! $wp_filesystem->mkdir( $remote_destination, FS_CHMOD_DIR ) ) {
533
+ return new WP_Error( 'mkdir_failed_destination', $this->strings['mkdir_failed'], $remote_destination );
534
+ }
535
+ }
536
+ // Copy new version of item into place.
537
+ $result = copy_dir( $source, $remote_destination );
538
+ if ( is_wp_error( $result ) ) {
539
+ if ( $args['clear_working'] ) {
540
+ $wp_filesystem->delete( $remote_source, true );
541
+ }
542
+ return $result;
543
+ }
544
+
545
+ //Clear the Working folder?
546
+ if ( $args['clear_working'] ) {
547
+ $wp_filesystem->delete( $remote_source, true );
548
+ }
549
+
550
+ $destination_name = basename( str_replace( $local_destination, '', $destination ) );
551
+ if ( '.' == $destination_name ) {
552
+ $destination_name = '';
553
+ }
554
+
555
+ $this->result = compact( 'source', 'source_files', 'destination', 'destination_name', 'local_destination', 'remote_destination', 'clear_destination' );
556
+
557
+ /**
558
+ * Filter the installation response after the installation has finished.
559
+ *
560
+ * @param bool $response Installation response.
561
+ * @param array $hook_extra Extra arguments passed to hooked filters.
562
+ * @param array $result Installation result data.
563
+ */
564
+ $res = apply_filters( 'upgrader_post_install', true, $args['hook_extra'], $this->result );
565
+
566
+ if ( is_wp_error( $res ) ) {
567
+ $this->result = $res;
568
+ return $res;
569
+ }
570
+
571
+ //Bombard the calling function will all the info which we've just used.
572
+ return $this->result;
573
+ }
574
+
575
+ /**
576
+ * Install a plugin package.
577
+ *
578
+ * @param string $package The full local path or URI of the package.
579
+ * @param array $args Optional. Other arguments for installing a plugin package. Default empty array.
580
+ *
581
+ * @return bool|\WP_Error True if the installation was successful, false or a WP_Error otherwise.
582
+ */
583
+ public function install( $package, $args = array() ) {
584
+
585
+ $result = parent::install( $package, $args );
586
+ if ( true === $result ) {
587
+ do_action( 'loginwp_plugin_installed', $package );
588
+ }
589
+
590
+ return $result;
591
+ }
592
+ }
src/core/src/Admin/Installer/PluginSilentUpgraderSkin.php ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin\Installer;
4
+
5
+ /** \WP_Upgrader_Skin class */
6
+ require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader-skin.php';
7
+
8
+ /**
9
+ * Class PluginSilentUpgraderSkin.
10
+ *
11
+ * @internal Please do not use this class outside of core ProfilePress development. May be removed at any time.
12
+ */
13
+ class PluginSilentUpgraderSkin extends \WP_Upgrader_Skin {
14
+
15
+ /**
16
+ * Empty out the header of its HTML content and only check to see if it has
17
+ * been performed or not.
18
+ */
19
+ public function header() {
20
+ }
21
+
22
+ /**
23
+ * Empty out the footer of its HTML contents.
24
+ */
25
+ public function footer() {
26
+ }
27
+
28
+ /**
29
+ * Instead of outputting HTML for errors, just return them.
30
+ * Ajax request will just ignore it.
31
+ *
32
+ * @param array $errors Array of errors with the install process.
33
+ *
34
+ * @return array
35
+ */
36
+ public function error( $errors ) {
37
+ return $errors;
38
+ }
39
+
40
+ /**
41
+ * Empty out JavaScript output that calls function to decrement the update counts.
42
+ *
43
+ * @param string $type Type of update count to decrement.
44
+ */
45
+ public function decrement_update_count( $type ) {
46
+ }
47
+ }
src/core/src/Admin/Installer/index.php ADDED
@@ -0,0 +1,2 @@
 
 
1
+ <?php namespace ProfilePress\Core\Classes;
2
+ //
src/core/src/Admin/ProfilePress.php ADDED
@@ -0,0 +1,701 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin;
4
+
5
+ use LoginWP\Core\Admin\Installer\PluginSilentUpgrader;
6
+ use LoginWP\Core\Admin\Installer\LoginWP_Install_Skin;
7
+
8
+ class ProfilePress
9
+ {
10
+ const SLUG = 'loginwp-ppress';
11
+
12
+ private $config = array(
13
+ 'lite_plugin' => 'wp-user-avatar/wp-user-avatar.php',
14
+ 'lite_download_url' => 'https://downloads.wordpress.org/plugin/wp-user-avatar.latest-stable.zip',
15
+ 'ppress_settings' => 'admin.php?page=pp-forms',
16
+ );
17
+
18
+ private $output_data = array();
19
+
20
+ public function __construct()
21
+ {
22
+ add_action('loginwp_admin_hooks', function () {
23
+ $this->register_settings_page();
24
+ });
25
+
26
+ add_action('wp_ajax_loginwp_activate_plugin', [$this, 'loginwp_activate_plugin']);
27
+ add_action('wp_ajax_loginwp_install_plugin', [$this, 'loginwp_install_plugin']);
28
+
29
+ if (wp_doing_ajax()) {
30
+ add_action('wp_ajax_loginwp_profilepress_page_check_plugin_status', array($this, 'ajax_check_plugin_status'));
31
+ }
32
+
33
+ // Check what page we are on.
34
+ $page = isset($_GET['page']) ? \sanitize_key(\wp_unslash($_GET['page'])) : '';
35
+
36
+ if (self::SLUG !== $page) return;
37
+
38
+ add_action('admin_init', array($this, 'redirect_to_ppress_settings'));
39
+ add_action('admin_enqueue_scripts', array($this, 'enqueue_assets'));
40
+ }
41
+
42
+ public function loginwp_install_plugin()
43
+ {
44
+ // Run a security check.
45
+ check_ajax_referer('loginwp-admin-nonce', 'nonce');
46
+
47
+ $generic_error = esc_html__('There was an error while performing your request.', 'peters-login-redirect');
48
+ $type = ! empty($_POST['type']) ? sanitize_key($_POST['type']) : 'plugin';
49
+
50
+ if ( ! current_user_can('install_plugins')) {
51
+ wp_send_json_error($generic_error);
52
+ }
53
+
54
+ // Determine whether file modifications are allowed.
55
+ if ( ! wp_is_file_mod_allowed('loginwp_can_install')) {
56
+ wp_send_json_error($generic_error);
57
+ }
58
+
59
+ $error = $type === 'plugin' ? esc_html__('Could not install plugin. Please download and install manually.', 'peters-login-redirect') : esc_html__('Could not install addon. Please download from wpforms.com and install manually.', 'peters-login-redirect');
60
+
61
+ if (empty($_POST['plugin'])) {
62
+ wp_send_json_error($error);
63
+ }
64
+
65
+ // Set the current screen to avoid undefined notices.
66
+ set_current_screen('profilepress_page_loginwp-ppress');
67
+
68
+ // Prepare variables.
69
+ $url = esc_url_raw(
70
+ add_query_arg(
71
+ ['page' => 'loginwp-redirections'],
72
+ admin_url('admin.php')
73
+ )
74
+ );
75
+
76
+ ob_start();
77
+ $creds = request_filesystem_credentials($url, '', false, false, null);
78
+
79
+ // Hide the filesystem credentials form.
80
+ ob_end_clean();
81
+
82
+ // Check for file system permissions.
83
+ if ($creds === false) {
84
+ wp_send_json_error($error);
85
+ }
86
+
87
+ if ( ! WP_Filesystem($creds)) {
88
+ wp_send_json_error($error);
89
+ }
90
+
91
+ /*
92
+ * We do not need any extra credentials if we have gotten this far, so let's install the plugin.
93
+ */
94
+
95
+ // Do not allow WordPress to search/download translations, as this will break JS output.
96
+ remove_action('upgrader_process_complete', ['Language_Pack_Upgrader', 'async_upgrade'], 20);
97
+
98
+ // Create the plugin upgrader with our custom skin.
99
+ $installer = new PluginSilentUpgrader(new LoginWP_Install_Skin());
100
+
101
+ // Error check.
102
+ if ( ! method_exists($installer, 'install') || empty($_POST['plugin'])) {
103
+ wp_send_json_error($error);
104
+ }
105
+
106
+ $installer->install($_POST['plugin']); // phpcs:ignore
107
+
108
+ // Flush the cache and return the newly installed plugin basename.
109
+ wp_cache_flush();
110
+
111
+ $plugin_basename = $installer->plugin_info();
112
+
113
+ if (empty($plugin_basename)) {
114
+ wp_send_json_error($error);
115
+ }
116
+
117
+ $result = [
118
+ 'msg' => $generic_error,
119
+ 'is_activated' => false,
120
+ 'basename' => $plugin_basename,
121
+ ];
122
+
123
+ // Check for permissions.
124
+ if ( ! current_user_can('activate_plugins')) {
125
+ $result['msg'] = $type === 'plugin' ? esc_html__('Plugin installed.', 'peters-login-redirect') : esc_html__('Addon installed.', 'peters-login-redirect');
126
+
127
+ wp_send_json_success($result);
128
+ }
129
+
130
+ // Activate the plugin silently.
131
+ $activated = activate_plugin($plugin_basename);
132
+
133
+ if ( ! is_wp_error($activated)) {
134
+ $result['is_activated'] = true;
135
+ $result['msg'] = $type === 'plugin' ? esc_html__('Plugin installed & activated.', 'peters-login-redirect') : esc_html__('Addon installed & activated.', 'peters-login-redirect');
136
+
137
+ wp_send_json_success($result);
138
+ }
139
+
140
+ // Fallback error just in case.
141
+ wp_send_json_error($result);
142
+ }
143
+
144
+ public function loginwp_activate_plugin()
145
+ {
146
+ // Run a security check.
147
+ check_ajax_referer('loginwp-admin-nonce', 'nonce');
148
+
149
+ // Check for permissions.
150
+ if ( ! current_user_can('activate_plugins')) {
151
+ wp_send_json_error(esc_html__('Plugin activation is disabled for you on this site.', 'peters-login-redirect'));
152
+ }
153
+
154
+ if (isset($_POST['plugin'])) {
155
+
156
+ $plugin = sanitize_text_field(wp_unslash($_POST['plugin']));
157
+ $activate = activate_plugins($plugin);
158
+
159
+ if ( ! is_wp_error($activate)) {
160
+ wp_send_json_success(esc_html__('Plugin activated.', 'peters-login-redirect'));
161
+ }
162
+ }
163
+
164
+ wp_send_json_error(esc_html__('Could not activate plugin. Please activate from the Plugins page.', 'peters-login-redirect'));
165
+ }
166
+
167
+ public function register_settings_page()
168
+ {
169
+ add_submenu_page(
170
+ PTR_LOGINWP_SETTINGS_PAGE_SLUG,
171
+ 'Login Forms',
172
+ esc_html__('Login Forms', 'peters-login-redirect'),
173
+ 'manage_options',
174
+ self::SLUG,
175
+ array($this, 'output')
176
+ );
177
+ }
178
+
179
+ public function enqueue_assets()
180
+ {
181
+ wp_enqueue_script(
182
+ 'loginwp-admin-page-ppress',
183
+ PTR_LOGINWP_ASSETS_URL . "js/profilepress.js",
184
+ array('jquery'),
185
+ PTR_LOGINWP_VERSION_NUMBER,
186
+ true
187
+ );
188
+
189
+ \wp_localize_script(
190
+ 'loginwp-admin-page-ppress',
191
+ 'loginwp_pluginlanding',
192
+ $this->get_js_strings()
193
+ );
194
+
195
+ \wp_localize_script('loginwp-admin-page-ppress', 'loginwp_installer_globals', [
196
+ 'nonce' => wp_create_nonce('loginwp-admin-nonce')
197
+ ]);
198
+ }
199
+
200
+ /**
201
+ * JS Strings.
202
+ */
203
+ protected function get_js_strings()
204
+ {
205
+ $error_could_not_install = sprintf(
206
+ wp_kses( /* translators: %s - Lite plugin download URL. */
207
+ __('Could not install plugin. Please <a href="%s">download</a> and install manually.', 'peters-login-redirect'),
208
+ array(
209
+ 'a' => array(
210
+ 'href' => true,
211
+ ),
212
+ )
213
+ ),
214
+ esc_url_raw($this->config['lite_download_url'])
215
+ );
216
+
217
+ $error_could_not_activate = sprintf(
218
+ wp_kses( /* translators: %s - Lite plugin download URL. */
219
+ __('Could not activate plugin. Please activate from the <a href="%s">Plugins page</a>.', 'peters-login-redirect'),
220
+ array(
221
+ 'a' => array(
222
+ 'href' => true,
223
+ ),
224
+ )
225
+ ),
226
+ esc_url_raw(admin_url('plugins.php'))
227
+ );
228
+
229
+ return array(
230
+ 'installing' => esc_html__('Installing...', 'peters-login-redirect'),
231
+ 'activating' => esc_html__('Activating...', 'peters-login-redirect'),
232
+ 'activated' => esc_html__('ProfilePress Installed & Activated', 'peters-login-redirect'),
233
+ 'install_now' => esc_html__('Install Now', 'peters-login-redirect'),
234
+ 'activate_now' => esc_html__('Activate Now', 'peters-login-redirect'),
235
+ 'download_now' => esc_html__('Download Now', 'peters-login-redirect'),
236
+ 'plugins_page' => esc_html__('Go to Plugins page', 'peters-login-redirect'),
237
+ 'error_could_not_install' => $error_could_not_install,
238
+ 'error_could_not_activate' => $error_could_not_activate,
239
+ 'manual_install_url' => $this->config['lite_download_url'],
240
+ 'manual_activate_url' => admin_url('plugins.php'),
241
+ 'ppress_settings_button' => esc_html__('Go to ProfilePress Settings', 'peters-login-redirect'),
242
+ );
243
+ }
244
+
245
+ /**
246
+ * Generate and output page HTML.
247
+ */
248
+ public function output()
249
+ {
250
+ ?>
251
+ <style>
252
+ #loginwp-admin-ppress {
253
+ width: 700px;
254
+ margin: 0 auto;
255
+ }
256
+
257
+ #loginwp-admin-ppress .notice,
258
+ #loginwp-admin-ppress .error {
259
+ display: none
260
+ }
261
+
262
+ #loginwp-admin-ppress *, #loginwp-admin-ppress *::before, #loginwp-admin-ppress *::after {
263
+ -webkit-box-sizing: border-box;
264
+ -moz-box-sizing: border-box;
265
+ box-sizing: border-box;
266
+ }
267
+
268
+ #loginwp-admin-ppress section {
269
+ margin: 50px 0;
270
+ text-align: left;
271
+ clear: both;
272
+ }
273
+
274
+ #loginwp-admin-ppress section.screenshot {
275
+ text-align: center;
276
+ }
277
+
278
+ #loginwp-admin-ppress .top {
279
+ text-align: center;
280
+ }
281
+
282
+ #loginwp-admin-ppress .top img {
283
+ margin-bottom: 38px;
284
+ }
285
+
286
+ #loginwp-admin-ppress .top h1 {
287
+ font-size: 26px;
288
+ font-weight: 600;
289
+ margin-bottom: 0;
290
+ padding: 0;
291
+ }
292
+
293
+ #loginwp-admin-ppress .top p {
294
+ font-size: 17px;
295
+ color: #777777;
296
+ margin-top: .5em;
297
+ }
298
+
299
+ #loginwp-admin-ppress p {
300
+ font-size: 15px;
301
+ }
302
+
303
+ #loginwp-admin-ppress .cont {
304
+ display: inline-block;
305
+ position: relative;
306
+ width: 80%;
307
+ padding: 5px;
308
+ background-color: #ffffff;
309
+ -webkit-box-shadow: 0px 2px 5px 0px rgb(0 0 0 / 5%);
310
+ -moz-box-shadow: 0px 2px 5px 0px rgba(0, 0, 0, 0.05);
311
+ box-shadow: 0px 2px 5px 0px rgb(0 0 0 / 5%);
312
+ border-radius: 3px;
313
+ box-sizing: border-box;
314
+ }
315
+
316
+ #loginwp-admin-ppress .screenshot > * {
317
+ vertical-align: middle;
318
+ }
319
+
320
+ #loginwp-admin-ppress .screenshot .cont img {
321
+ max-width: 100%;
322
+ display: block;
323
+ }
324
+
325
+ #loginwp-admin-ppress .screenshot ul {
326
+ display: inline-block;
327
+ margin: 0 0 0 30px;
328
+ list-style-type: none;
329
+ max-width: 100%;
330
+ }
331
+
332
+ #loginwp-admin-ppress .screenshot li {
333
+ margin: 16px 0;
334
+ padding: 0 0 0 24px;
335
+ font-size: 15px;
336
+ color: #777777;
337
+ }
338
+
339
+ #loginwp-admin-ppress .step {
340
+ background-color: #F9F9F9;
341
+ -webkit-box-shadow: 0px 2px 5px 0px rgb(0 0 0 / 5%);
342
+ -moz-box-shadow: 0px 2px 5px 0px rgba(0, 0, 0, 0.05);
343
+ box-shadow: 0px 2px 5px 0px rgb(0 0 0 / 5%);
344
+ border: 1px solid #E5E5E5;
345
+ margin: 0 0 25px 0;
346
+ }
347
+
348
+ #loginwp-admin-ppress .step .num {
349
+ display: inline-block;
350
+ position: relative;
351
+ width: 100px;
352
+ height: 50px;
353
+ text-align: center;
354
+ }
355
+
356
+ .loginwp-admin-plugin-landing .loader {
357
+ margin: 0 auto;
358
+ position: relative;
359
+ text-indent: -9999em;
360
+ border-top: 4px solid #969696;
361
+ border-right: 4px solid #969696;
362
+ border-bottom: 4px solid #969696;
363
+ border-left: 4px solid #404040;
364
+ -webkit-transform: translateZ(0);
365
+ -ms-transform: translateZ(0);
366
+ transform: translateZ(0);
367
+ -webkit-animation: load8 1.1s infinite linear;
368
+ animation: load8 1.1s infinite linear;
369
+ background-color: transparent;
370
+ }
371
+
372
+ .loginwp-admin-plugin-landing .loader, .loginwp-admin-plugin-landing .loader:after {
373
+ display: block;
374
+ border-radius: 50%;
375
+ width: 50px;
376
+ height: 50px
377
+ }
378
+
379
+ @-webkit-keyframes load8 {
380
+ 0% {
381
+ -webkit-transform: rotate(0deg);
382
+ transform: rotate(0deg)
383
+ }
384
+
385
+ 100% {
386
+ -webkit-transform: rotate(360deg);
387
+ transform: rotate(360deg)
388
+ }
389
+ }
390
+
391
+ @keyframes load8 {
392
+ 0% {
393
+ -webkit-transform: rotate(0deg);
394
+ transform: rotate(0deg)
395
+ }
396
+
397
+ 100% {
398
+ -webkit-transform: rotate(360deg);
399
+ transform: rotate(360deg)
400
+ }
401
+ }
402
+
403
+ #loginwp-admin-ppress .step .loader {
404
+ margin-top: -54px;
405
+ transition: all .3s;
406
+ opacity: 1;
407
+ }
408
+
409
+ #loginwp-admin-ppress .step .hidden {
410
+ opacity: 0;
411
+ transition: all .3s;
412
+ }
413
+
414
+ #loginwp-admin-ppress .step div {
415
+ display: inline-block;
416
+ width: calc(100% - 104px);
417
+ background-color: #ffffff;
418
+ padding: 30px;
419
+ border-left: 1px solid #eeeeee;
420
+ }
421
+
422
+ #loginwp-admin-ppress .step h2 {
423
+ font-size: 24px;
424
+ line-height: 22px;
425
+ margin-top: 0;
426
+ margin-bottom: 15px;
427
+ }
428
+
429
+ #loginwp-admin-ppress .step p {
430
+ font-size: 16px;
431
+ color: #777777;
432
+ }
433
+
434
+
435
+ #loginwp-admin-ppress .step .button {
436
+ font-weight: 500;
437
+ box-shadow: none;
438
+ padding: 12px;
439
+ min-width: 200px;
440
+ height: auto;
441
+ line-height: 13px;
442
+ text-align: center;
443
+ font-size: 15px;
444
+ transition: all .3s;
445
+ }
446
+
447
+ #loginwp-admin-ppress .grey {
448
+ opacity: 0.5;
449
+ }
450
+ </style>
451
+ <?php
452
+ echo '<div id="loginwp-admin-ppress" class="wrap loginwp-admin-wrap loginwp-admin-plugin-landing">';
453
+
454
+ $this->output_section_heading();
455
+ $this->output_section_screenshot();
456
+ $this->output_section_step_install();
457
+ $this->output_section_step_setup();
458
+
459
+ echo '</div>';
460
+ }
461
+
462
+ /**
463
+ * Generate and output heading section HTML.
464
+ */
465
+ protected function output_section_heading()
466
+ {
467
+ // Heading section.
468
+ printf(
469
+ '<section class="top">
470
+ <img class="img-top" src="%1$s" alt="%2$s"/>
471
+ <h1>%3$s</h1>
472
+ <p>%4$s</p>
473
+ </section>',
474
+ esc_url(PTR_LOGINWP_ASSETS_URL . 'images/loginwpXprofilepress.png'),
475
+ esc_attr__('ProfilePress ♥ ProfilePress', 'peters-login-redirect'),
476
+ esc_html__('Modern Custom Login Forms & Membership Plugin', 'peters-login-redirect'),
477
+ esc_html__('ProfilePress lets you create beautiful frontend custom login forms, registration forms, member directories and user profiles. You can also protect sensitive contents and control user access.', 'peters-login-redirect')
478
+ );
479
+ }
480
+
481
+ /**
482
+ * Generate and output screenshot section HTML.
483
+ */
484
+ protected function output_section_screenshot()
485
+ {
486
+ printf(
487
+ '<section class="screenshot">
488
+ <div class="cont">
489
+ <img src="%1$s" alt="%2$s"/>
490
+ </div>
491
+ <ul style="text-align: left">
492
+ <li>%3$s</li>
493
+ <li>%4$s</li>
494
+ <li>%5$s</li>
495
+ <li>%6$s</li>
496
+ <li>%7$s</li>
497
+ </ul>
498
+ </section>',
499
+ PTR_LOGINWP_ASSETS_URL . 'images/ppress-login-form.png',
500
+ esc_attr__('ProfilePress screenshot', 'peters-login-redirect'),
501
+ esc_html__('Beautiful templates for login, registration, password reset & edit profile edit forms.', 'peters-login-redirect'),
502
+ esc_html__('Fine-grained control over what content your users can see based on your protection rules.', 'peters-login-redirect'),
503
+ esc_html__('Restrict access to pages, posts, custom post types, categories, tags and custom taxonomies.', 'peters-login-redirect'),
504
+ esc_html__('Add beautiful user profiles to your site that can be customised to your specific requirements.', 'peters-login-redirect'),
505
+ esc_html__('Create searchable and filterable member directories with avatars and user info allowing users to find each other.', 'peters-login-redirect')
506
+ );
507
+ }
508
+
509
+ /**
510
+ * Generate and output step 'Install' section HTML.
511
+ */
512
+ protected function output_section_step_install()
513
+ {
514
+ $step = $this->get_data_step_install();
515
+
516
+ if (empty($step)) {
517
+ return;
518
+ }
519
+
520
+ printf(
521
+ '<section class="step step-install">
522
+ <aside class="num">
523
+ <img src="%1$s" alt="%2$s" />
524
+ <i class="loader hidden"></i>
525
+ </aside>
526
+ <div>
527
+ <h2>%3$s</h2>
528
+ <p>%4$s</p>
529
+ <button class="button %5$s" data-plugin="%6$s" data-action="%7$s">%8$s</button>
530
+ </div>
531
+ </section>',
532
+ esc_url(PTR_LOGINWP_ASSETS_URL . 'images/' . $step['icon']),
533
+ esc_attr__('Step 1', 'peters-login-redirect'),
534
+ esc_html__('Install and Activate ProfilePress', 'peters-login-redirect'),
535
+ esc_html__('Install ProfilePress from the WordPress.org plugin repository.', 'peters-login-redirect'),
536
+ esc_attr($step['button_class']),
537
+ esc_attr($step['plugin']),
538
+ esc_attr($step['button_action']),
539
+ esc_html($step['button_text'])
540
+ );
541
+ }
542
+
543
+ /**
544
+ * Generate and output step 'Setup' section HTML.
545
+ */
546
+ protected function output_section_step_setup()
547
+ {
548
+ $step = $this->get_data_step_setup();
549
+
550
+ if (empty($step)) {
551
+ return;
552
+ }
553
+
554
+ printf(
555
+ '<section class="step step-setup %1$s">
556
+ <aside class="num">
557
+ <img src="%2$s" alt="%3$s" />
558
+ <i class="loader hidden"></i>
559
+ </aside>
560
+ <div>
561
+ <h2>%4$s</h2>
562
+ <p>%5$s</p>
563
+ <button class="button %6$s" data-url="%7$s">%8$s</button>
564
+ </div>
565
+ </section>',
566
+ esc_attr($step['section_class']),
567
+ esc_url(PTR_LOGINWP_ASSETS_URL . 'images/' . $step['icon']),
568
+ esc_attr__('Step 2', 'peters-login-redirect'),
569
+ esc_html__('Set Up ProfilePress', 'peters-login-redirect'),
570
+ esc_html__('Configure and create your first login form.', 'peters-login-redirect'),
571
+ esc_attr($step['button_class']),
572
+ esc_url(admin_url($this->config['ppress_settings'])),
573
+ esc_html($step['button_text'])
574
+ );
575
+ }
576
+
577
+ /**
578
+ * Step 'Install' data.
579
+ */
580
+ protected function get_data_step_install()
581
+ {
582
+ $step = array();
583
+
584
+ $this->output_data['all_plugins'] = get_plugins();
585
+ $this->output_data['plugin_installed'] = array_key_exists($this->config['lite_plugin'], $this->output_data['all_plugins']);
586
+ $this->output_data['plugin_activated'] = false;
587
+ $this->output_data['plugin_setup'] = false;
588
+
589
+ if ( ! $this->output_data['plugin_installed']) {
590
+ $step['icon'] = 'step-1.svg';
591
+ $step['button_text'] = esc_html__('Install ProfilePress', 'peters-login-redirect');
592
+ $step['button_class'] = '';
593
+ $step['button_action'] = 'install';
594
+ $step['plugin'] = $this->config['lite_download_url'];
595
+ } else {
596
+ $this->output_data['plugin_activated'] = $this->is_activated();
597
+ $this->output_data['plugin_setup'] = $this->is_configured();
598
+ $step['icon'] = $this->output_data['plugin_activated'] ? 'step-complete.svg' : 'step-1.svg';
599
+ $step['button_text'] = $this->output_data['plugin_activated'] ? esc_html__('ProfilePress Installed & Activated', 'peters-login-redirect') : esc_html__('Activate ProfilePress', 'peters-login-redirect');
600
+ $step['button_class'] = $this->output_data['plugin_activated'] ? 'grey disabled' : '';
601
+ $step['button_action'] = $this->output_data['plugin_activated'] ? '' : 'activate';
602
+ $step['plugin'] = $this->config['lite_plugin'];
603
+ }
604
+
605
+ return $step;
606
+ }
607
+
608
+ /**
609
+ * Step 'Setup' data.
610
+ */
611
+ protected function get_data_step_setup()
612
+ {
613
+ $step = array();
614
+
615
+ $step['icon'] = 'step-2.svg';
616
+ $step['section_class'] = $this->output_data['plugin_activated'] ? '' : 'grey';
617
+ $step['button_text'] = esc_html__('Start Setup', 'peters-login-redirect');
618
+ $step['button_class'] = 'grey disabled';
619
+
620
+ if ($this->output_data['plugin_setup']) {
621
+ $step['icon'] = 'step-complete.svg';
622
+ $step['section_class'] = '';
623
+ $step['button_text'] = esc_html__('Go to ProfilePress settings', 'peters-login-redirect');
624
+ } else {
625
+ $step['button_class'] = $this->output_data['plugin_activated'] ? '' : 'grey disabled';
626
+ }
627
+
628
+ return $step;
629
+ }
630
+
631
+ /**
632
+ * Ajax endpoint. Check plugin setup status.
633
+ * Used to properly init step 'Setup' section after completing step 'Install'.
634
+ */
635
+ public function ajax_check_plugin_status()
636
+ {
637
+ // Security checks.
638
+ if (
639
+ ! check_ajax_referer('loginwp-admin-nonce', 'nonce', false) ||
640
+ ! current_user_can('activate_plugins')
641
+ ) {
642
+ wp_send_json_error(
643
+ array(
644
+ 'error' => esc_html__('You do not have permission.', 'peters-login-redirect'),
645
+ )
646
+ );
647
+ }
648
+
649
+ $result = array();
650
+
651
+ if ( ! $this->is_activated()) {
652
+ wp_send_json_error(
653
+ array(
654
+ 'error' => esc_html__('Plugin unavailable.', 'peters-login-redirect'),
655
+ )
656
+ );
657
+ }
658
+
659
+ $result['setup_status'] = (int)$this->is_configured();
660
+
661
+ wp_send_json_success($result);
662
+ }
663
+
664
+ /**
665
+ * Whether ProfilePress plugin configured or not.
666
+ */
667
+ protected function is_configured()
668
+ {
669
+ return $this->is_activated();
670
+ }
671
+
672
+ /**
673
+ * Whether ProfilePress plugin active or not.
674
+ */
675
+ protected function is_activated()
676
+ {
677
+ return class_exists('ProfilePress\Core\Base');
678
+ }
679
+
680
+ public function redirect_to_ppress_settings()
681
+ {
682
+ if ($this->is_configured()) {
683
+ wp_safe_redirect(admin_url($this->config['ppress_settings']));
684
+ exit;
685
+ }
686
+ }
687
+
688
+ /**
689
+ * @return self
690
+ */
691
+ public static function get_instance()
692
+ {
693
+ static $instance = null;
694
+
695
+ if (is_null($instance)) {
696
+ $instance = new self();
697
+ }
698
+
699
+ return $instance;
700
+ }
701
+ }
src/core/src/Admin/RedirectWPList.php ADDED
@@ -0,0 +1,334 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin;
4
+
5
+ use LoginWP\Core\Helpers;
6
+
7
+ if ( ! class_exists('WP_List_Table')) {
8
+ require_once(ABSPATH . 'wp-admin/includes/class-wp-list-table.php');
9
+ }
10
+
11
+ class RedirectWPList extends \WP_List_Table
12
+ {
13
+ private $table;
14
+
15
+ /** @var \wpdb */
16
+ private $wpdb;
17
+
18
+ public function __construct($wpdb)
19
+ {
20
+ $this->wpdb = $wpdb;
21
+ $this->table = PTR_LOGINWP_DB_TABLE;
22
+
23
+ parent::__construct(array(
24
+ 'singular' => __('loginwp_redirect', 'peters-login-redirect'),
25
+ 'plural' => __('loginwp_redirects', 'peters-login-redirect'),
26
+ 'ajax' => false
27
+ )
28
+ );
29
+
30
+ $this->process_actions();
31
+ }
32
+
33
+ public function hash_map($key = '')
34
+ {
35
+ $map = [
36
+ 'user' => esc_html__('Username', 'peters-login-redirect'),
37
+ 'role' => esc_html__('User Role', 'peters-login-redirect'),
38
+ 'level' => esc_html__('User Capability', 'peters-login-redirect'),
39
+ ];
40
+
41
+ if ( ! empty($key)) return $map[$key];
42
+
43
+ return $map;
44
+ }
45
+
46
+ /**
47
+ * Retrieve campaigns data from the database
48
+ *
49
+ * @param int $per_page
50
+ * @param int $current_page
51
+ *
52
+ * @return mixed
53
+ */
54
+ public function get_redirect_rules($per_page, $current_page = 1)
55
+ {
56
+ $per_page = absint($per_page);
57
+ $current_page = absint($current_page);
58
+
59
+ $offset = ($current_page - 1) * $per_page;
60
+
61
+ $sql = "SELECT * FROM {$this->table} WHERE rul_type NOT IN ('all','register')";
62
+
63
+ $sql .= " LIMIT %d";
64
+ $args[] = $per_page;
65
+
66
+ if ($current_page > 1) {
67
+ $sql .= " OFFSET %d";
68
+ $args[] = $offset;
69
+ }
70
+
71
+ return $this->wpdb->get_results(
72
+ $this->wpdb->prepare($sql, $args),
73
+ 'ARRAY_A'
74
+ );
75
+ }
76
+
77
+ /**
78
+ * Returns the count of records in the database.
79
+ *
80
+ * @return null|string
81
+ */
82
+ public function record_count()
83
+ {
84
+ global $wpdb;
85
+
86
+ $sql = "SELECT COUNT(*) FROM {$this->table} WHERE rul_type NOT IN ('all','register')";
87
+
88
+ return $wpdb->get_var($sql);
89
+ }
90
+
91
+ /** Text displayed when no email campaign is available */
92
+ public function no_items()
93
+ {
94
+ printf(
95
+ __('No redirection rule found. %sConsider creating one%s', 'peters-login-redirect'),
96
+ '<a href="' . add_query_arg('new', '1', PTR_LOGINWP_REDIRECTIONS_PAGE_URL) . '">',
97
+ '</a>'
98
+ );
99
+ }
100
+
101
+ /**
102
+ * Render the bulk edit checkbox
103
+ *
104
+ * @param array $item
105
+ *
106
+ * @return string
107
+ */
108
+ public function column_cb($item)
109
+ {
110
+ return sprintf(
111
+ '<input type="checkbox" name="redirect_rule_ids[]" value="%s" />', $item['id']
112
+ );
113
+ }
114
+
115
+ /**
116
+ * @param int $id
117
+ *
118
+ * @return string
119
+ */
120
+ public static function edit_rule_url($id)
121
+ {
122
+ return add_query_arg(['action' => 'edit', 'id' => absint($id)], PTR_LOGINWP_REDIRECTIONS_PAGE_URL);
123
+ }
124
+
125
+ /**
126
+ * @param int $id
127
+ *
128
+ * @return string
129
+ */
130
+ public static function delete_rule_url($id)
131
+ {
132
+ return wp_nonce_url(
133
+ add_query_arg(['action' => 'delete', 'id' => absint($id)], PTR_LOGINWP_REDIRECTIONS_PAGE_URL),
134
+ 'loginwp-delete-rule'
135
+ );
136
+ }
137
+
138
+ /**
139
+ * @param mixed $item
140
+ *
141
+ * @return string
142
+ */
143
+ public function column_rul_url($item)
144
+ {
145
+ $rule_id = absint($item['id']);
146
+
147
+ $edit_url = self::edit_rule_url($rule_id);
148
+
149
+ $label = ! empty($item['rul_url']) ? sanitize_text_field($item['rul_url']) : esc_html__('[Not Set]', 'peters-login-redirect');
150
+
151
+ $name = "<strong><a href=\"$edit_url\">" . $label . '</a></strong>';
152
+
153
+ $actions = [
154
+ 'edit' => sprintf('<a href="%s">%s</a>', $edit_url, __('Edit', 'peters-login-redirect')),
155
+ 'delete' => sprintf('<a class="loginwp-delete-prompt delete" href="%s">%s</a>', esc_url(self::delete_rule_url($rule_id)), __('Delete', 'peters-login-redirect')),
156
+ ];
157
+
158
+ return $name . $this->row_actions($actions);
159
+ }
160
+
161
+ /**
162
+ * @param mixed $item
163
+ *
164
+ * @return string
165
+ */
166
+ public function column_rul_url_logout($item)
167
+ {
168
+ $rule_id = absint($item['id']);
169
+
170
+ $edit_url = self::edit_rule_url($rule_id);
171
+
172
+ $label = ! empty($item['rul_url_logout']) ? sanitize_text_field($item['rul_url_logout']) : esc_html__('[Not Set]', 'peters-login-redirect');
173
+
174
+ return "<strong><a href=\"$edit_url\">" . $label . '</a></strong>';
175
+ }
176
+
177
+ /**
178
+ * @param mixed $item
179
+ *
180
+ * @return string
181
+ */
182
+ public function column_rul_type($item)
183
+ {
184
+ return $this->hash_map($item['rul_type']);
185
+ }
186
+
187
+ /**
188
+ * @param mixed $item
189
+ *
190
+ * @return string
191
+ */
192
+ public function column_rul_value($item)
193
+ {
194
+ $value = sanitize_text_field($item['rul_value']);
195
+
196
+ if ($item['rul_type'] == 'role') {
197
+ $value = loginwp_var(Helpers::user_role_list(), $item['rul_value']);
198
+ }
199
+
200
+ return $value;
201
+ }
202
+
203
+ /**
204
+ * @param object $item
205
+ * @param string $column_name
206
+ *
207
+ * @return string
208
+ */
209
+ public function column_default($item, $column_name)
210
+ {
211
+ return sanitize_text_field($item[$column_name]);
212
+ }
213
+
214
+ /**
215
+ * Associative array of columns
216
+ *
217
+ * @return array
218
+ */
219
+ public function get_columns()
220
+ {
221
+ $columns = array(
222
+ 'cb' => '<input type="checkbox">',
223
+ 'rul_url' => __('Login URL', 'peters-login-redirect'),
224
+ 'rul_url_logout' => __('Logout URL', 'peters-login-redirect'),
225
+ 'rul_type' => __('Condition', 'peters-login-redirect'),
226
+ 'rul_value' => __('Condition Value', 'peters-login-redirect')
227
+ );
228
+
229
+ return $columns;
230
+ }
231
+
232
+ /**
233
+ * Columns to make sortable.
234
+ *
235
+ * @return array
236
+ */
237
+ public function get_sortable_columns()
238
+ {
239
+ $sortable_columns = array(
240
+ 'name' => array('name', true),
241
+ );
242
+
243
+ return $sortable_columns;
244
+ }
245
+
246
+ /**
247
+ * Returns an associative array containing the bulk action
248
+ *
249
+ * @return array
250
+ */
251
+ public function get_bulk_actions()
252
+ {
253
+ $actions = array(
254
+ 'bulk-delete' => __('Delete', 'peters-login-redirect'),
255
+ );
256
+
257
+ return $actions;
258
+ }
259
+
260
+ /**
261
+ * Handles data query and filter, sorting, and pagination.
262
+ */
263
+ public function prepare_items()
264
+ {
265
+ $this->_column_headers = $this->get_column_info();
266
+ $per_page = $this->get_items_per_page('redirections_per_page', 10);
267
+ $current_page = $this->get_pagenum();
268
+ $total_items = $this->record_count();
269
+ $this->set_pagination_args(array(
270
+ 'total_items' => $total_items, //WE have to calculate the total number of items
271
+ 'per_page' => $per_page //WE have to determine how many items to show on a page
272
+ )
273
+ );
274
+
275
+ $this->items = $this->get_redirect_rules($per_page, $current_page);
276
+ }
277
+
278
+ public static function delete_rule($rule_id)
279
+ {
280
+ global $wpdb;
281
+
282
+ $wpdb->delete(
283
+ PTR_LOGINWP_DB_TABLE,
284
+ ['id' => $rule_id],
285
+ ['%d']
286
+ );
287
+ }
288
+
289
+ public function process_actions()
290
+ {
291
+ // bail if user is not an admin or without admin privileges.
292
+ if ( ! current_user_can('manage_options')) {
293
+ return;
294
+ }
295
+
296
+ if ('delete' === $this->current_action() && ! empty($_GET['id'])) {
297
+
298
+ check_admin_referer('loginwp-delete-rule');
299
+
300
+ self::delete_rule(absint($_GET['id']));
301
+
302
+ wp_safe_redirect(add_query_arg('deleted', 'true', PTR_LOGINWP_REDIRECTIONS_PAGE_URL));
303
+ exit;
304
+ }
305
+
306
+ if ('bulk-delete' === $this->current_action()) {
307
+
308
+ check_admin_referer('bulk-' . $this->_args['plural']);
309
+
310
+ $delete_ids = array_map('absint', $_POST['redirect_rule_ids']);
311
+
312
+ foreach ($delete_ids as $id) {
313
+ self::delete_rule($id);
314
+ }
315
+
316
+ wp_safe_redirect(add_query_arg('deleted', 'true', PTR_LOGINWP_REDIRECTIONS_PAGE_URL));
317
+ exit;
318
+ }
319
+ }
320
+
321
+ /**
322
+ * @return self
323
+ */
324
+ public static function get_instance()
325
+ {
326
+ static $instance = null;
327
+
328
+ if (is_null($instance)) {
329
+ $instance = new self($GLOBALS['wpdb']);
330
+ }
331
+
332
+ return $instance;
333
+ }
334
+ }
src/core/src/Admin/RedirectionsPage.php ADDED
@@ -0,0 +1,468 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin;
4
+
5
+ use LoginWP\Core\Helpers;
6
+
7
+ class RedirectionsPage extends AbstractSettingsPage
8
+ {
9
+ /**
10
+ * @var RedirectWPList
11
+ */
12
+ protected $wplist_instance;
13
+
14
+ public function __construct()
15
+ {
16
+ ProfilePress::get_instance();
17
+
18
+ parent::__construct();
19
+
20
+ add_action('admin_init', [$this, 'save_redirect_rule_changes']);
21
+ add_action('admin_init', [$this, 'save_other_settings_changes']);
22
+ add_action('loginwp_admin_settings_page_rules', [$this, 'redirections_admin_page_callback']);
23
+ }
24
+
25
+ public function register_menu_page()
26
+ {
27
+ $menus = $this->header_menu_tabs();
28
+
29
+ $active_menu = isset($_GET['tab']) ? sanitize_text_field($_GET['tab']) : 'rules';
30
+
31
+ $page_title = __('Redirections - LoginWP', 'peters-login-redirect');
32
+
33
+ if (isset($menus[$active_menu])) {
34
+ $page_title = __('Redirection ', 'peters-login-redirect') . $menus[$active_menu];
35
+ }
36
+
37
+ $hook = add_submenu_page(
38
+ PTR_LOGINWP_SETTINGS_PAGE_SLUG,
39
+ $page_title,
40
+ __('Redirections', 'peters-login-redirect'),
41
+ 'manage_options',
42
+ PTR_LOGINWP_REDIRECTION_PAGE_SLUG,
43
+ [$this, 'admin_page_callback']
44
+ );
45
+
46
+ add_action("load-$hook", array($this, 'screen_option'));
47
+ }
48
+
49
+ public function default_header_menu()
50
+ {
51
+ return 'rules';
52
+ }
53
+
54
+ public function header_menu_tabs()
55
+ {
56
+ $tabs['rules'] = esc_html__('Rules', 'peters-login-redirect');
57
+
58
+ return apply_filters('loginwp_redirections_header_menu_tabs', $tabs);
59
+ }
60
+
61
+ public static function get_rule_conditions()
62
+ {
63
+ return apply_filters('rul_rule_conditions', [
64
+ [
65
+ 'id' => 'user',
66
+ 'label' => esc_html__('Username', 'peters-login-redirect'),
67
+ 'options' => Helpers::username_list(),
68
+ 'order_support' => false
69
+ ],
70
+ [
71
+ 'id' => 'role',
72
+ 'label' => esc_html__('User Role', 'peters-login-redirect'),
73
+ 'options' => Helpers::user_role_list(),
74
+ 'order_support' => true
75
+ ],
76
+ [
77
+ 'id' => 'level',
78
+ 'label' => esc_html__('User Capability', 'peters-login-redirect'),
79
+ 'options' => Helpers::capability_list(),
80
+ 'order_support' => true
81
+ ]
82
+ ]);
83
+ }
84
+
85
+ /**
86
+ * Screen options
87
+ */
88
+ public function screen_option()
89
+ {
90
+ if (loginwp_var($_GET, 'page') != PTR_LOGINWP_REDIRECTION_PAGE_SLUG || (isset($_GET['tab']) && $_GET['tab'] != 'rules')) {
91
+ add_filter('screen_options_show_screen', '__return_false');
92
+ }
93
+
94
+ $option = 'per_page';
95
+
96
+ $args = array(
97
+ 'label' => __('Rules', 'peters-login-redirect'),
98
+ 'default' => 10,
99
+ 'option' => 'redirections_per_page',
100
+ );
101
+
102
+ if ( ! isset($_GET['new'], $_GET['action'])) {
103
+ add_screen_option($option, $args);
104
+ }
105
+
106
+ $this->wplist_instance = RedirectWPList::get_instance();
107
+ }
108
+
109
+ public function add_new_button()
110
+ {
111
+ $url = add_query_arg('new', '1', PTR_LOGINWP_REDIRECTIONS_PAGE_URL);
112
+ $label = __('Add New', 'peters-login-redirect');
113
+
114
+ if (isset($_GET['new']) || isset($_GET['action'])) {
115
+ $url = PTR_LOGINWP_REDIRECTIONS_PAGE_URL;
116
+ $label = __('Go Back', 'peters-login-redirect');
117
+ }
118
+
119
+ printf('<a class="add-new-h2" style=:margin-left:15px;" href="%s">%s</a>', esc_url($url), $label);
120
+ }
121
+
122
+ public function redirections_admin_page_callback()
123
+ {
124
+ add_action('wp_cspa_before_closing_header', [$this, 'add_new_button']);
125
+ add_action('wp_cspa_main_content_area', array($this, 'wp_list_table'), 10, 2);
126
+
127
+ $instance = SettingsPageApi::instance();
128
+ $instance->option_name('loginwp_redirection_settings');
129
+ $instance->page_header(__('Redirection Rules', 'peters-login-redirect'));
130
+ $instance->sidebar(self::sidebar_args());
131
+ echo '<div class="loginwp-data-listing">';
132
+ $instance->build();
133
+ echo '</div>';
134
+ }
135
+
136
+ public function bottom_admin_page_settings()
137
+ {
138
+ require dirname(__FILE__) . '/views/view.bottom-settings.php';
139
+ }
140
+
141
+ /**
142
+ * Callback to output content of OptinCampaign_List table.
143
+ *
144
+ * @param string $content
145
+ * @param string $option_name settings Custom_Settings_Page_Api option name.
146
+ *
147
+ * @return string|void
148
+ */
149
+ public function wp_list_table($content, $option_name)
150
+ {
151
+ if ($option_name != 'loginwp_redirection_settings') {
152
+ return $content;
153
+ }
154
+
155
+ add_thickbox();
156
+
157
+ if ((isset($_GET['new']) && $_GET['new'] == '1') || (isset($_GET['action']) && $_GET['action'] == 'edit')) {
158
+ add_action('admin_footer', [$this, 'js_template']);
159
+ require_once dirname(__FILE__) . '/views/include.view.php';
160
+ self::available_placeholders_structure();
161
+
162
+ return;
163
+ }
164
+
165
+ ob_start();
166
+
167
+ $this->wplist_instance->prepare_items();
168
+
169
+ $this->wplist_instance->display();
170
+
171
+ $this->bottom_admin_page_settings();
172
+
173
+ self::available_placeholders_structure();
174
+
175
+ return ob_get_clean();
176
+ }
177
+
178
+ public static function condition_value_dropdown($condition_id, $db_condition_value = '')
179
+ {
180
+ $condition = wp_list_filter(self::get_rule_conditions(), ['id' => $condition_id]);
181
+
182
+ if ( ! empty($condition)) : $condition = array_values($condition)[0]; ?>
183
+ <label>
184
+ <select name="rul_condition_value">
185
+ <option value=""><?php esc_html_e('Select...', 'peters-login-redirect'); ?></option>
186
+ <?php foreach ($condition['options'] as $key => $label) : ?>
187
+ <option value="<?= esc_attr($key) ?>" <?php selected($key, $db_condition_value) ?>><?= $label ?></option>
188
+ <?php endforeach; ?>
189
+ </select>
190
+ </label>
191
+ <?php
192
+ endif;
193
+ }
194
+
195
+ public static function order_support_conditions()
196
+ {
197
+ $order_support_conditions = wp_list_filter(self::get_rule_conditions(), ['order_support' => true]);
198
+
199
+ if ( ! empty($order_support_conditions)) {
200
+ $order_support_conditions = array_reduce($order_support_conditions, function ($carry, $item) {
201
+ $carry[] = $item['id'];
202
+
203
+ return $carry;
204
+ });
205
+ }
206
+
207
+ return $order_support_conditions;
208
+ }
209
+
210
+ public function js_template()
211
+ {
212
+ foreach (self::get_rule_conditions() as $condition) : ?>
213
+ <script type="text/html" id="tmpl-loginwp-condition-<?php echo esc_attr($condition['id']) ?>">
214
+ <?php self::condition_value_dropdown($condition['id']); ?>
215
+ </script>
216
+ <?php endforeach; ?>
217
+
218
+ <script>
219
+ var rul_conditions_order_support = <?php echo json_encode(self::order_support_conditions()) ?>;
220
+ </script>
221
+ <?php
222
+ }
223
+
224
+ public function save_redirect_rule_changes()
225
+ {
226
+ if (isset($_GET['page'], $_GET['saved']) && PTR_LOGINWP_REDIRECTION_PAGE_SLUG == $_GET['page']) {
227
+
228
+ $message = esc_html__('Redirect rule saved successfully', 'peters-login-redirect');
229
+
230
+ if ('settings' == $_GET['saved']) {
231
+ $message = esc_html__('Changes saved', 'peters-login-redirect');
232
+ }
233
+
234
+ $this->trigger_admin_notices($message, 'success');
235
+ }
236
+
237
+ if (isset($_GET['page'], $_GET['deleted']) && PTR_LOGINWP_REDIRECTION_PAGE_SLUG == $_GET['page']) {
238
+
239
+ $this->trigger_admin_notices(
240
+ esc_html__('Redirect rule deleted', 'peters-login-redirect'),
241
+ 'success');
242
+ }
243
+
244
+ if (empty($_POST['loginwp_save_rule'])) return;
245
+
246
+ if ( ! $this->security_check('loginwp_save_rule', 'rul-loginwp-nonce')) return;
247
+
248
+ global $wpdb;
249
+
250
+ $type = sanitize_text_field(loginwpPOST_var('rul_condition'));
251
+ $typeValue = sanitize_text_field(loginwpPOST_var('rul_condition_value'));
252
+ $order = absint(loginwpPOST_var('rul_order'));
253
+
254
+ $error_message = '';
255
+
256
+ if (empty($_POST['rul_login_url']) && empty($_POST['rul_logout_url'])) {
257
+ $error_message = __('ERROR: No Login or Logout URL specified', 'peters-login-redirect');
258
+ }
259
+
260
+ if ($type == 'user' && ! username_exists($typeValue)) {
261
+ $error_message = __('ERROR: Non-existent username submitted', 'peters-login-redirect');
262
+ }
263
+
264
+ if ($type == 'role' && ! in_array($typeValue, array_keys(Helpers::user_role_list()))) {
265
+ $error_message = __('ERROR: Non-existent role submitted', 'peters-login-redirect');
266
+ }
267
+
268
+ if ($type == 'level' && ! in_array($typeValue, Helpers::capability_list())) {
269
+ $error_message = __('ERROR: Non-existent level submitted', 'peters-login-redirect');
270
+ }
271
+
272
+ if ( ! empty($error_message)) {
273
+
274
+ $this->trigger_admin_notices($error_message);
275
+
276
+ return;
277
+ }
278
+
279
+ if ($order > 99) $order = 0;
280
+
281
+ if ( ! empty($_GET['id'])) {
282
+
283
+ $result = $wpdb->update(
284
+ PTR_LOGINWP_DB_TABLE,
285
+ [
286
+ 'rul_type' => $type,
287
+ 'rul_value' => $typeValue,
288
+ 'rul_order' => $order,
289
+ 'rul_url' => sanitize_text_field($_POST['rul_login_url']),
290
+ 'rul_url_logout' => sanitize_text_field($_POST['rul_logout_url'])
291
+ ],
292
+ [
293
+ 'id' => absint($_GET['id'])
294
+ ],
295
+ ['%s', '%s', '%d', '%s', '%s'],
296
+ ['%d']
297
+ );
298
+
299
+ if (false === $result) {
300
+
301
+ $this->trigger_admin_notices(
302
+ esc_html__('ERROR: Unknown error editing redirect rule', 'peters-login-redirect')
303
+ );
304
+
305
+ return;
306
+ }
307
+ }
308
+
309
+ if ( ! isset($_GET['id'])) {
310
+
311
+ $result = $wpdb->insert(
312
+ PTR_LOGINWP_DB_TABLE,
313
+ [
314
+ 'rul_url' => sanitize_text_field($_POST['rul_login_url']),
315
+ 'rul_url_logout' => sanitize_text_field($_POST['rul_logout_url']),
316
+ 'rul_type' => $type,
317
+ 'rul_value' => $typeValue,
318
+ 'rul_order' => $order
319
+ ],
320
+ ['%s', '%s', '%s', '%s', '%d']
321
+ );
322
+
323
+ if (false === $result) {
324
+
325
+ $this->trigger_admin_notices(
326
+ __('ERROR: Unknown error when adding the redirect rule', 'peters-login-redirect')
327
+ );
328
+ }
329
+
330
+ wp_safe_redirect(add_query_arg('saved', 'true', RedirectWPList::edit_rule_url($wpdb->insert_id)));
331
+ exit;
332
+ }
333
+
334
+ wp_safe_redirect(esc_url_raw(add_query_arg('saved', 'true')));
335
+ exit;
336
+ }
337
+
338
+ public function save_other_settings_changes()
339
+ {
340
+ if ( ! empty($_POST['rul_allupdatesubmit'])) {
341
+
342
+ if ( ! $this->security_check('rul_allupdatesubmit')) return;
343
+
344
+ global $wpdb;
345
+
346
+ $address = esc_url_raw($_POST['rul_all']);
347
+ $address_logout = esc_url_raw($_POST['rul_all_logout']);
348
+
349
+ $update = $wpdb->update(
350
+ PTR_LOGINWP_DB_TABLE,
351
+ ['rul_url' => $address, 'rul_url_logout' => $address_logout],
352
+ ['rul_type' => 'all']
353
+ );
354
+
355
+ if ($update === false) {
356
+ $this->trigger_admin_notices(
357
+ __('ERROR: Unknown problem updating URL', 'peters-login-redirect')
358
+ );
359
+ }
360
+
361
+ wp_safe_redirect(esc_url_raw(add_query_arg('saved', 'true')));
362
+ exit;
363
+ }
364
+
365
+ if ( ! empty($_POST['rul_registerupdatesubmit'])) {
366
+
367
+ if ( ! $this->security_check('rul_registerupdatesubmit')) return;
368
+
369
+ global $wpdb;
370
+
371
+ $update = $wpdb->update(
372
+ PTR_LOGINWP_DB_TABLE,
373
+ ['rul_url' => esc_url_raw($_POST['rul_register'])],
374
+ ['rul_type' => 'register']
375
+ );
376
+
377
+ if ($update === false) {
378
+
379
+ $this->trigger_admin_notices(
380
+ __('ERROR: Unknown problem updating URL', 'peters-login-redirect')
381
+ );
382
+ }
383
+
384
+ wp_safe_redirect(esc_url_raw(add_query_arg('saved', 'true')));
385
+ exit;
386
+ }
387
+
388
+ if ( ! empty($_POST['rul_settingssubmit'])) {
389
+
390
+ if ( ! $this->security_check('rul_settingssubmit')) return;
391
+
392
+ $rul_settings = Helpers::redirectFunctionCollection_get_settings();
393
+
394
+ foreach ($rul_settings as $key => $value) {
395
+ if (isset($_POST[$key])) {
396
+ $rul_settings[$key] = sanitize_text_field($_POST[$key]);
397
+ }
398
+ }
399
+
400
+ update_option('rul_settings', $rul_settings);
401
+
402
+ wp_safe_redirect(esc_url_raw(add_query_arg('saved', 'settings')));
403
+ exit;
404
+ }
405
+ }
406
+
407
+ public function trigger_admin_notices($message, $type = 'error')
408
+ {
409
+ $class = "notice-$type";
410
+ add_action('admin_notices', function () use ($message, $class) {
411
+ printf('<div class="notice %2$s is-dismissible"><p>%1$s</p></div>', $message, $class);
412
+ });
413
+ }
414
+
415
+ public function security_check($nonce_action, $query_arg = 'rul-security')
416
+ {
417
+ if ( ! current_user_can('manage_options')) return false;
418
+
419
+ check_admin_referer($nonce_action, $query_arg);
420
+
421
+ return true;
422
+ }
423
+
424
+ public static function available_placeholders_structure()
425
+ {
426
+ $available_placeholders = apply_filters('loginwp_login_redirection_placeholders', [
427
+ 'username' => esc_html__('Username of user', 'peters-login-redirect'),
428
+ 'user_slug' => esc_html__('Author URL slug or user nicename', 'peters-login-redirect'),
429
+ 'website_url' => esc_html__('Website URL', 'peters-login-redirect')
430
+ ]);
431
+ ?>
432
+ <div id="loginwp-view-placeholders" style="display:none;">
433
+ <div class="loginwp-view-placeholders-wrap">
434
+ <?php foreach ($available_placeholders as $placeholder => $description) : ?>
435
+ <div class="loginwp-placeholder">
436
+ <strong>{{<?= esc_html($placeholder) ?>}}:</strong> <?= esc_html($description) ?>
437
+ </div>
438
+ <?php endforeach; ?>
439
+ <?php if ( ! defined('LOGINWP_DETACH_LIBSODIUM')) : ?>
440
+ <?php $upsell_url = 'https://loginwp.com/pricing/?utm_source=wp_dashboard&utm_medium=upgrade&utm_campaign=login_redirect_placeholder_modal'; ?>
441
+ <div class="loginwp-placeholder-upsell">
442
+ <p>
443
+ <?php printf(
444
+ esc_html__('With %sLoginWP PRO%s, you can redirect users to the current page they are logging in from or the previous page before they are redirected to the login page.', 'peters-login-redirect'),
445
+ '<a target="_blank" href="' . $upsell_url . '">', '</a>'
446
+ ); ?>
447
+ </p>
448
+ <div>
449
+ <a class="button-primary" href="<?= $upsell_url ?>" target="_blank"><?php esc_html_e('Upgrade to PRO', 'peters-login-redirect') ?></a>
450
+ </div>
451
+ </div>
452
+ <?php endif; ?>
453
+ </div>
454
+ </div>
455
+ <?php
456
+ }
457
+
458
+ public static function get_instance()
459
+ {
460
+ static $instance = null;
461
+
462
+ if (is_null($instance)) {
463
+ $instance = new self();
464
+ }
465
+
466
+ return $instance;
467
+ }
468
+ }
src/core/src/Admin/SettingsPage.php ADDED
@@ -0,0 +1,90 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Admin;
4
+
5
+ class SettingsPage extends AbstractSettingsPage
6
+ {
7
+ protected $settings_page_instance;
8
+
9
+ public function __construct()
10
+ {
11
+ parent::__construct();
12
+
13
+ add_action('loginwp_admin_settings_page_general', [$this, 'settings_page_callback']);
14
+
15
+ $this->settings_page_instance = SettingsPageApi::instance();
16
+ $this->settings_page_instance->option_name('loginwp_settings');
17
+ add_action('admin_init', [$this->settings_page_instance, 'persist_plugin_settings']);
18
+ }
19
+
20
+ public function register_menu_page()
21
+ {
22
+ $menus = $this->header_menu_tabs();
23
+
24
+ $active_menu = isset($_GET['tab']) ? sanitize_text_field($_GET['tab']) : 'general';
25
+
26
+ $page_title = __('Settings - LoginWP', 'peters-login-redirect');
27
+
28
+ if (isset($menus[$active_menu])) {
29
+ $page_title = $menus[$active_menu] . ' ' . __('Settings', 'peters-login-redirect');
30
+ }
31
+
32
+ add_submenu_page(
33
+ PTR_LOGINWP_SETTINGS_PAGE_SLUG,
34
+ $page_title,
35
+ __('Settings', 'peters-login-redirect'),
36
+ 'manage_options',
37
+ PTR_LOGINWP_SETTINGS_PAGE_SLUG,
38
+ [$this, 'admin_page_callback']
39
+ );
40
+ }
41
+
42
+ public function default_header_menu()
43
+ {
44
+ return 'general';
45
+ }
46
+
47
+ public function header_menu_tabs()
48
+ {
49
+ $tabs['general'] = esc_html__('General', 'peters-login-redirect');
50
+
51
+ return apply_filters('loginwp_settings_header_menu_tabs', $tabs);
52
+ }
53
+
54
+ public function save_redirect_rule_changes()
55
+ {
56
+
57
+ }
58
+
59
+ public function settings_page_callback()
60
+ {
61
+ $settings = [
62
+ [
63
+ 'remove_plugin_data' => [
64
+ 'label' => esc_html__('Remove Data on Uninstall', 'peters-login-redirect'),
65
+ 'checkbox_label' => esc_html__('Activate', 'peters-login-redirect'),
66
+ 'description' => esc_html__('Check this box if you would like LoginWP to completely remove all of its data when uninstalled.', 'peters-login-redirect'),
67
+ 'type' => 'checkbox',
68
+ ]
69
+ ]
70
+ ];
71
+
72
+ $this->settings_page_instance->page_header(esc_html__('General', 'peters-login-redirect'));
73
+ $this->settings_page_instance->sidebar(AbstractSettingsPage::sidebar_args());
74
+ $this->settings_page_instance->remove_white_design();
75
+ $this->settings_page_instance->header_without_frills();
76
+ $this->settings_page_instance->main_content($settings);
77
+ $this->settings_page_instance->build();
78
+ }
79
+
80
+ public static function get_instance()
81
+ {
82
+ static $instance = null;
83
+
84
+ if (is_null($instance)) {
85
+ $instance = new self();
86
+ }
87
+
88
+ return $instance;
89
+ }
90
+ }
src/core/src/Admin/SettingsPageApi.php ADDED
@@ -0,0 +1,1239 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * WordPress Custom Settings API Library.
4
+ *
5
+ * Copyright (C) 2017 Agbonghama Collins
6
+ *
7
+ * This program is free software: you can redistribute it and/or modify
8
+ * it under the terms of the GNU General Public License as published by
9
+ * the Free Software Foundation, either version 3 of the License, or
10
+ * (at your option) any later version.
11
+ *
12
+ * This program is distributed in the hope that it will be useful,
13
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
+ * GNU General Public License for more details.
16
+ *
17
+ * You should have received a copy of the GNU General Public License
18
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
19
+ *
20
+ * @package WordPress Custom Settings API
21
+ * @version 1.0
22
+ * @author Agbonghama Collins
23
+ * @link to be decided
24
+ * @license http://www.gnu.org/licenses GNU General Public License
25
+ */
26
+
27
+ namespace LoginWP\Core\Admin;
28
+
29
+ class SettingsPageApi
30
+ {
31
+ /** @var mixed|void database saved data. */
32
+ private $db_options = [];
33
+
34
+ /** @var string option name for database saving. */
35
+ private $option_name = '';
36
+
37
+ /** @var array config of settings page tabs */
38
+ private $tabs_config = [];
39
+
40
+ /** @var array config of main settings page */
41
+ private $main_content_config = [];
42
+
43
+ private $remove_white_design = false;
44
+ private $header_without_frills = false;
45
+
46
+ /** @var array config of settings page sidebar */
47
+ private $sidebar_config = [];
48
+
49
+ /** @var string header title of the page */
50
+ private $page_header = '';
51
+
52
+ private $view_classes = '';
53
+
54
+ private $wrap_classes = '';
55
+
56
+ private $exclude_top_tav_nav = false;
57
+
58
+ protected function __construct($main_content_config = [], $option_name = '', $page_header = '')
59
+ {
60
+ $this->db_options = get_option($option_name, []);
61
+ $this->db_options = empty($this->db_options) ? [] : $this->db_options;
62
+ $this->option_name = $option_name;
63
+ $this->main_content_config = $main_content_config;
64
+ $this->page_header = $page_header;
65
+ }
66
+
67
+ /**
68
+ * set this as late as possible.
69
+ *
70
+ * @param $db_options
71
+ */
72
+ public function set_db_options($db_options)
73
+ {
74
+ $this->db_options = $db_options;
75
+ }
76
+
77
+ public function option_name($val)
78
+ {
79
+ $this->db_options = get_option($val, []);
80
+ $this->db_options = empty($this->db_options) ? [] : $this->db_options;
81
+ $this->option_name = $val;
82
+ }
83
+
84
+ public function tab($val)
85
+ {
86
+ $this->tabs_config = $val;
87
+ }
88
+
89
+ public function main_content($val)
90
+ {
91
+ $this->main_content_config = $val;
92
+ }
93
+
94
+ public function add_view_classes($classes)
95
+ {
96
+ $this->view_classes = $classes;
97
+ }
98
+
99
+ public function add_wrap_classes($classes)
100
+ {
101
+ $this->wrap_classes = $classes;
102
+ }
103
+
104
+ public function remove_white_design()
105
+ {
106
+ $this->remove_white_design = true;
107
+ }
108
+
109
+ public function header_without_frills()
110
+ {
111
+ $this->header_without_frills = true;
112
+ }
113
+
114
+ public function sidebar($val)
115
+ {
116
+ $this->sidebar_config = $val;
117
+ }
118
+
119
+ public function page_header($val)
120
+ {
121
+ $this->page_header = $val;
122
+ }
123
+
124
+ /**
125
+ * Construct the settings page tab.
126
+ *
127
+ * array(
128
+ * array('url' => '', 'label' => ''),
129
+ * array('url' => '', 'label' => ''),
130
+ * );
131
+ *
132
+ */
133
+ public function settings_page_tab()
134
+ {
135
+ if ($this->exclude_top_tav_nav === true) return;
136
+
137
+ $args = $this->tabs_config;
138
+
139
+ $html = '';
140
+ if ( ! empty($args)) {
141
+ $html .= '<h2 class="nav-tab-wrapper">';
142
+ foreach ($args as $arg) {
143
+ $url = esc_url_raw(@$arg['url']);
144
+ $label = esc_html(@$arg['label']);
145
+ $class = esc_attr(@$arg['class']);
146
+ $style = esc_attr(@$arg['style']);
147
+ $active = remove_query_arg(array_merge(['type', 'settings-updated', 'ppsc', 'license', 'mc-audience', 'cm-email-list', 'id', 'contact-info', 'edit']), $this->current_page_url()) == $url ? ' nav-tab-active' : null;
148
+ $html .= "<a href=\"$url\" class=\"$class nav-tab{$active}\" style='$style'>$label</a>";
149
+ }
150
+
151
+ $html .= '</h2>';
152
+ }
153
+
154
+ echo apply_filters('wp_cspa_settings_page_tab', $html);
155
+
156
+ do_action('wp_cspa_settings_after_tab');
157
+ }
158
+
159
+
160
+ /**
161
+ * Construct the settings page sidebar.
162
+ *
163
+ * array(
164
+ * array(
165
+ * 'section_title' => 'Documentation',
166
+ * 'content' => '',
167
+ *` );
168
+ * );
169
+ *
170
+ */
171
+ public function setting_page_sidebar()
172
+ {
173
+ $custom_sidebar = apply_filters('wp_cspa_settings_page_sidebar', '');
174
+
175
+ if ( ! empty($custom_sidebar)) {
176
+ echo $custom_sidebar;
177
+
178
+ return;
179
+ }
180
+ ?>
181
+ <div id="postbox-container-1" class="postbox-container">
182
+ <div class="meta-box-sortables">
183
+ <?php if ( ! empty($this->sidebar_config)): ?>
184
+ <?php foreach ($this->sidebar_config as $arg) : ?>
185
+ <div class="postbox">
186
+ <div class="postbox-header">
187
+ <h3 class="hndle is-non-sortable">
188
+ <span><?=$arg['section_title']; ?></span>
189
+ </h3>
190
+ </div>
191
+
192
+ <div class="inside">
193
+ <?=$arg['content']; ?>
194
+ </div>
195
+ </div>
196
+ <?php endforeach; ?>
197
+ <?php endif; ?>
198
+ </div>
199
+ </div>
200
+ <?php
201
+ }
202
+
203
+ /**
204
+ * Helper function to recursively sanitize POSTed data.
205
+ *
206
+ * @param $data
207
+ *
208
+ * @return string|array
209
+ */
210
+ public static function sanitize_data($data)
211
+ {
212
+ if (is_string($data)) {
213
+ return esc_html($data);
214
+ }
215
+
216
+ $sanitized_data = [];
217
+ foreach ($data as $key => $value) {
218
+ // skip sanitation. useful for fields that expects html
219
+ if (($cValue = apply_filters('wp_cspa_sanitize_skip', false, $key, $value))) {
220
+ $sanitized_data[$key] = stripslashes($cValue);
221
+ continue;
222
+ }
223
+
224
+ if (is_array($data[$key])) {
225
+ $sanitized_data[$key] = self::sanitize_data($data[$key]);
226
+ } else {
227
+ $sanitized_data[$key] = esc_html(stripslashes($data[$key]));
228
+ }
229
+ }
230
+
231
+ return $sanitized_data;
232
+ }
233
+
234
+ /**
235
+ * Persist the form data to database.
236
+ *
237
+ * @return \WP_Error|Void
238
+ */
239
+ public function persist_plugin_settings($option_name = '')
240
+ {
241
+ if ( ! current_user_can('manage_options')) {
242
+ return;
243
+ }
244
+
245
+ $option_name = !empty($option_name) ? $option_name : $this->option_name;
246
+
247
+ if (empty($_POST['save_' . $option_name])) {
248
+ return;
249
+ }
250
+
251
+ check_admin_referer('wp-csa-nonce', 'wp_csa_nonce');
252
+
253
+ /**
254
+ * Use add_settings_error() to create/generate an errors add_settings_error('wp_csa_notice', '', 'an error');
255
+ * in your validation function/class method hooked to this action.
256
+ */
257
+ do_action('wp_cspa_validate_data', $_POST[$option_name]);
258
+
259
+ $settings_error = get_settings_errors('wp_csa_notice');
260
+ if ( ! empty($settings_error)) {
261
+ return;
262
+ }
263
+
264
+ $sanitize_callable = apply_filters('wp_cspa_sanitize_callback', 'self::sanitize_data');
265
+
266
+ $sanitized_data = apply_filters(
267
+ 'wp_cspa_santized_data',
268
+ call_user_func($sanitize_callable, $_POST[$option_name]),
269
+ $option_name
270
+ );
271
+
272
+ // skip unchanged (with asterisk ** in its data) api key/token values.
273
+ foreach ($sanitized_data as $key => $value) {
274
+ if (is_string($value) && strpos($value, '**') !== false) {
275
+ unset($sanitized_data[$key]);
276
+ }
277
+ }
278
+
279
+ do_action('wp_cspa_persist_settings', $sanitized_data, $option_name, $this);
280
+
281
+ if ( ! apply_filters('wp_cspa_disable_default_persistence', false)) {
282
+
283
+ update_option($option_name, array_replace($this->db_options, $sanitized_data));
284
+
285
+ do_action('wp_cspa_after_persist_settings', $sanitized_data, $option_name);
286
+
287
+ wp_safe_redirect(esc_url_raw(add_query_arg('settings-updated', 'true')));
288
+ exit;
289
+ }
290
+ }
291
+
292
+ /**
293
+ * Do settings page error
294
+ */
295
+ public function do_settings_errors()
296
+ {
297
+ $success_notice = apply_filters('wp_cspa_success_notice', 'Settings saved.', $this->option_name);
298
+ if (isset($_GET['settings-updated']) && ($_GET['settings-updated'] == 'true')) : ?>
299
+ <?php add_settings_error('wp_csa_notice', 'wp_csa_settings_updated', $success_notice, 'updated'); ?>
300
+ <?php endif; ?>
301
+ <?php
302
+ }
303
+
304
+ public function metabox_toggle_script()
305
+ {
306
+ ?>
307
+ <script type="text/javascript">
308
+ jQuery(document).ready(function ($) {
309
+ $('.wp_csa_view .handlediv').click(function () {
310
+ $(this).parent().toggleClass("closed").addClass('postbox');
311
+ });
312
+ });
313
+ </script>
314
+ <?php
315
+
316
+ do_action('wp_cspa_scripts');
317
+ }
318
+
319
+ private function remove_white_styling_css()
320
+ {
321
+ ?>
322
+ <style>
323
+ .remove_white_styling #post-body-content .postbox {
324
+ background: inherit;
325
+ border: 0;
326
+ box-shadow: none;
327
+ }
328
+ .remove_white_styling #post-body-content .handlediv.button-link {
329
+ display: none;
330
+ }
331
+
332
+ .remove_white_styling #post-body-content .postbox .hndle {
333
+ border: 0;
334
+ }
335
+
336
+ .remove_white_styling #post-body-content .CodeMirror {
337
+ width: 100%;
338
+ max-width: 900px;
339
+ border: 0;
340
+ }
341
+
342
+ .remove_white_styling #post-body-content .pp-email-editor-tabcontent {
343
+ background: #fff;
344
+ max-width: 900px;
345
+ }
346
+
347
+ .remove_white_styling #post-body-content .pp-email-editor-tab {
348
+ border: 0;
349
+ }
350
+
351
+ .remove_white_styling #post-body-content .pp-email-editor-tablinks {
352
+ background: #f1f1f1;
353
+ }
354
+
355
+ .remove_white_styling #post-body-content .pp-email-editor-tablinks.eactive {
356
+ background: #ffffff;
357
+ }
358
+
359
+ .remove_white_styling #post-body-content .pp-email-editor-tabcontent.epreview {
360
+ max-height: 650px;
361
+ }
362
+
363
+ .remove_white_styling #post-body-content input.regular-text {
364
+ width: 100%;
365
+ max-width: 900px;
366
+ }
367
+
368
+ .remove_white_styling #post-body-content textarea{
369
+ width: 100%;
370
+ min-height: 200px;
371
+ }
372
+
373
+ .remove_white_styling #post-body-content .form-table th{
374
+ width: 250px;
375
+ }
376
+
377
+ .remove_white_styling #post-body-content tr .description {
378
+ max-width: 630px;
379
+ width: 100%;
380
+ }
381
+
382
+ .remove_white_styling #post-body-content .postbox .inside {
383
+ padding-left: 0;
384
+ }
385
+ </style>
386
+ <?php
387
+ }
388
+
389
+ public function settings_page_heading()
390
+ {
391
+ echo '<h2>';
392
+ echo $this->page_header;
393
+ do_action('wp_cspa_before_closing_header');
394
+ echo '</h2>';
395
+ do_action('wp_cspa_after_header');
396
+ }
397
+
398
+ public function nonce_field()
399
+ {
400
+ printf('<input id="wp_csa_nonce" type="hidden" name="wp_csa_nonce" value="%s">', wp_create_nonce('wp-csa-nonce'));
401
+ }
402
+
403
+ /**
404
+ * Get current page URL.
405
+ *
406
+ * @return string
407
+ */
408
+ public function current_page_url()
409
+ {
410
+ $pageURL = 'http';
411
+ if (isset($_SERVER["HTTPS"])) {
412
+ if ($_SERVER["HTTPS"] == "on") {
413
+ $pageURL .= "s";
414
+ }
415
+ }
416
+ $pageURL .= "://";
417
+ if ($_SERVER["SERVER_PORT"] != "80") {
418
+ $pageURL .= $_SERVER["SERVER_NAME"] . $_SERVER["REQUEST_URI"];
419
+ } else {
420
+ $pageURL .= $_SERVER["SERVER_NAME"] . $_SERVER["REQUEST_URI"];
421
+ }
422
+
423
+ return apply_filters('wp_cspa_main_current_page_url', esc_url_raw($pageURL));
424
+ }
425
+
426
+
427
+ /**
428
+ * Main settings page markup.
429
+ *
430
+ * @param bool $return_output
431
+ */
432
+ public function _settings_page_main_content_area($return_output = false)
433
+ {
434
+ $args_arrays = $this->main_content_config;
435
+
436
+ // variable declaration
437
+ $html = '';
438
+
439
+ if ( ! empty($args_arrays)) {
440
+ foreach ($args_arrays as $args_array) {
441
+ $html .= $this->metax_box_instance($args_array);
442
+ }
443
+ }
444
+
445
+ if ($return_output) {
446
+ return $html;
447
+ }
448
+
449
+ echo $html;
450
+ }
451
+
452
+ /**
453
+ * @param $args
454
+ *
455
+ * @return string
456
+ */
457
+ public function metax_box_instance($args)
458
+ {
459
+ $db_options = $this->db_options;
460
+
461
+ $html = '';
462
+
463
+ if($this->header_without_frills === true) {
464
+ $html .= $this->_header_without_frills($args);
465
+ }
466
+ else {
467
+ $html .= $this->_header($args);
468
+ }
469
+
470
+ $disable_submit_button = isset($args['disable_submit_button']) ? true : false;
471
+
472
+ // remove section title from array to make the argument keys be arrays so it can work with foreach loop
473
+ if (isset($args['section_title'])) {
474
+ unset($args['section_title']);
475
+ }
476
+
477
+ if (isset($args['disable_submit_button'])) {
478
+ unset($args['disable_submit_button']);
479
+ }
480
+
481
+ foreach ($args as $key => $value) {
482
+ $field_type = '_' . $args[$key]['type'];
483
+ $html .= $this->{$field_type}($db_options, $key, $args[$key]);
484
+ }
485
+
486
+ if ($disable_submit_button) {
487
+ $html .= $this->_footer_without_button();
488
+ } else {
489
+ $html .= $this->_footer();
490
+ }
491
+
492
+ return $html;
493
+ }
494
+
495
+ /**
496
+ * @param int $id
497
+ * @param string $name
498
+ * @param string $value
499
+ * @param string $class
500
+ * @param string $placeholder
501
+ * @param string $data_key
502
+ */
503
+ public function _text_field($id, $name, $value, $class = 'regular-text', $placeholder = '', $data_key = '')
504
+ {
505
+ $id = ! empty($id) ? $id : '';
506
+ $data_key = ! empty($data_key) ? "data-index='$data_key'" : null;
507
+ $value = ! empty($value) ? $value : null;
508
+ ?>
509
+ <input type="text" placeholder="<?=$placeholder; ?>" id="<?=$id; ?>" name="<?=$name; ?>" class="<?=$class; ?>" value="<?=$value; ?>" <?=$data_key; ?>/>
510
+ <?php
511
+ do_action('wp_cspa_field_before_text_field', $id);
512
+ }
513
+
514
+ /**
515
+ * Useful if u wanna use any text/html in the settings page.
516
+ *
517
+ * @param mixed $data
518
+ *
519
+ * @return string
520
+ */
521
+ public function _arbitrary($db_options, $key, $args)
522
+ {
523
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
524
+ $data = @$args['data'];
525
+ $description = @$args['description'];
526
+
527
+ return "<tr id=\"$tr_id\"><td colspan=\"5\" style='margin:0;padding:0;'>" . $data . $description . '</td></tr>';
528
+ }
529
+
530
+ /**
531
+ * Renders the text field
532
+ *
533
+ * @param array $db_options addons DB options
534
+ * @param string $key array key of class argument
535
+ * @param array $args class args
536
+ *
537
+ * @return string
538
+ */
539
+ public function _text($db_options, $key, $args)
540
+ {
541
+ $key = str_replace('-', '_', sanitize_key($key));
542
+ $label = esc_attr($args['label']);
543
+ $defvalue = sanitize_text_field(@$args['value']);
544
+ $description = @$args['description'];
545
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
546
+ $option_name = $this->option_name;
547
+ $name_attr = $option_name . '[' . $key . ']';
548
+ $value = ! empty($db_options[$key]) ? $db_options[$key] : $defvalue;
549
+
550
+ if (isset($args['obfuscate_val']) && in_array($args['obfuscate_val'], [true, 'true'])) {
551
+ $value = $this->obfuscate_string($value);
552
+ }
553
+
554
+ ob_start(); ?>
555
+ <tr id="<?=$tr_id; ?>">
556
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
557
+ <td>
558
+ <?php do_action('wp_cspa_before_text_field', $db_options, $option_name, $key, $args); ?>
559
+ <?php $this->_text_field($key, $name_attr, $value); ?>
560
+ <?php do_action('wp_cspa_after_text_field', $db_options, $option_name, $key, $args); ?>
561
+ <p class="description"><?=$description; ?></p>
562
+ </td>
563
+ </tr>
564
+ <?php
565
+ return ob_get_clean();
566
+ }
567
+
568
+ public function obfuscate_string($string)
569
+ {
570
+ $length = strlen($string);
571
+ $obfuscated_length = ceil($length / 2);
572
+ $string = str_repeat('*', $obfuscated_length) . substr($string, $obfuscated_length);
573
+
574
+ return $string;
575
+ }
576
+
577
+ /**
578
+ * Renders the custom field block
579
+ *
580
+ * @param array $db_options addons DB options
581
+ * @param string $key array key of class argument
582
+ * @param array $args class args
583
+ *
584
+ * @return string
585
+ */
586
+ public function _custom_field_block($db_options, $key, $args)
587
+ {
588
+ $key = str_replace('-', '_', sanitize_key($key));
589
+ $label = esc_attr(@$args['label']);
590
+ $description = @$args['description'];
591
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
592
+ $option_name = $this->option_name;
593
+
594
+ $data = @$args['data'];
595
+
596
+ ob_start(); ?>
597
+ <tr id="<?=$tr_id; ?>">
598
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
599
+ <td>
600
+ <?php do_action('wp_cspa_before_custom_field_block', $db_options, $option_name, $key, $args); ?>
601
+ <?=$data; ?>
602
+ <?php do_action('wp_cspa_after_custom_field_block', $db_options, $option_name, $key, $args); ?>
603
+ <p class="description"><?=$description; ?></p>
604
+ </td>
605
+ </tr>
606
+ <?php
607
+ return ob_get_clean();
608
+ }
609
+
610
+ /**
611
+ * Renders the number field
612
+ *
613
+ * @param array $db_options addons DB options
614
+ * @param string $key array key of class argument
615
+ * @param array $args class args
616
+ *
617
+ * @return string
618
+ */
619
+ public function _number($db_options, $key, $args)
620
+ {
621
+ $key = esc_attr($key);
622
+ $label = esc_attr($args['label']);
623
+ $defvalue = sanitize_text_field(@$args['value']);
624
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
625
+ $description = @$args['description'];
626
+ $option_name = $this->option_name;
627
+ $value = ! empty($db_options[$key]) ? $db_options[$key] : $defvalue;
628
+ ob_start(); ?>
629
+ <tr id="<?=$tr_id; ?>">
630
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
631
+ <td>
632
+ <?php do_action('wp_cspa_before_number_field', $db_options, $option_name, $key, $args); ?>
633
+ <input type="number" id="<?=$key; ?>" name="<?=$option_name, '[', $key, ']'; ?>"
634
+ class="regular-text" value="<?=$value; ?>"/>
635
+ <?php do_action('wp_cspa_after_number_field', $db_options, $option_name, $key, $args); ?>
636
+
637
+ <p class="description"><?=$description; ?></p>
638
+ </td>
639
+ </tr>
640
+ <?php
641
+ return ob_get_clean();
642
+ }
643
+
644
+ /**
645
+ * Renders the password field
646
+ *
647
+ * @param array $db_options addons DB options
648
+ * @param string $key array key of class argument
649
+ * @param array $args class args
650
+ *
651
+ * @return string
652
+ */
653
+ public function _password($db_options, $key, $args)
654
+ {
655
+ $key = esc_attr($key);
656
+ $label = esc_attr($args['label']);
657
+ $defvalue = sanitize_text_field(@$args['value']);
658
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
659
+ $disabled = isset($args['disabled']) && $args['disabled'] === true ? 'disabled="disabled"' : '';
660
+ $description = @$args['description'];
661
+ $option_name = $this->option_name;
662
+ $value = ! empty($db_options[$key]) ? $db_options[$key] : $defvalue;
663
+ ob_start(); ?>
664
+ <tr id="<?=$tr_id; ?>">
665
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
666
+ <td>
667
+ <?php do_action('wp_cspa_before_password_field', $db_options, $option_name, $key, $args); ?>
668
+ <input type="password" id="<?=$key; ?>" name="<?=$option_name, '[', $key, ']'; ?>"
669
+ class="regular-text" value="<?=$value; ?>" <?=$disabled; ?>/>
670
+ <?php do_action('wp_cspa_after_password_field', $db_options, $option_name, $key, $args); ?>
671
+
672
+ <p class="description"><?=$description; ?></p>
673
+ </td>
674
+ </tr>
675
+ <?php
676
+ return ob_get_clean();
677
+ }
678
+
679
+ /**
680
+ * Renders the number text field
681
+ *
682
+ * @param array $db_options addons DB options
683
+ * @param string $key array key of class argument
684
+ * @param array $args class args
685
+ *
686
+ * @return string
687
+ */
688
+ public function _hidden($db_options, $key, $args)
689
+ {
690
+ $key = esc_attr($key);
691
+ $label = esc_attr($args['label']);
692
+ $description = @$args['description'];
693
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
694
+ $option_name = $this->option_name;
695
+ /**
696
+ * @todo add default value support to other field types.
697
+ */
698
+ $value = ! empty($db_options[$key]) ? $db_options[$key] : @$args['value'];
699
+ ob_start(); ?>
700
+ <tr id="<?=$tr_id; ?>">
701
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
702
+ <td>
703
+ <?php do_action('wp_cspa_before_hidden_field', $db_options, $option_name, $key, $args); ?>
704
+ <input type="hidden" id="<?=$key; ?>" name="<?=$option_name, '[', $key, ']'; ?>"
705
+ class="regular-text" value="<?=$value; ?>"/>
706
+ <?php do_action('wp_cspa_after_hidden_field', $db_options, $option_name, $key, $args); ?>
707
+ <p class="description"><?=$description; ?></p>
708
+ </td>
709
+ </tr>
710
+ <?php
711
+ return ob_get_clean();
712
+ }
713
+
714
+ /**
715
+ * Renders the textarea field
716
+ *
717
+ * @param array $db_options addons DB options
718
+ * @param string $key array key of class argument
719
+ * @param array $args class args
720
+ *
721
+ * @return string
722
+ */
723
+ public function _textarea($db_options, $key, $args)
724
+ {
725
+ $key = esc_attr($key);
726
+ $label = esc_attr($args['label']);
727
+ $description = @$args['description'];
728
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
729
+ $rows = ! empty($args['rows']) ? $args['rows'] : 5;
730
+ $cols = ! empty($args['column']) ? $args['column'] : '';
731
+ $option_name = $this->option_name;
732
+ $value = ! empty($db_options[$key]) ? stripslashes($db_options[$key]) : @$args['value'];
733
+ ob_start();
734
+ ?>
735
+ <tr id="<?=$tr_id; ?>">
736
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
737
+ <td>
738
+ <?php do_action('wp_cspa_before_textarea_field', $db_options, $option_name, $key, $args); ?>
739
+ <textarea rows="<?=$rows; ?>" cols="<?=$cols; ?>"
740
+ name="<?=$option_name, '[', $key, ']'; ?>"
741
+ id="<?=$key; ?>"><?=$value; ?></textarea>
742
+ <?php do_action('wp_cspa_after_textarea_field', $db_options, $option_name, $key, $args); ?>
743
+
744
+ <p class="description"><?=$description; ?></p>
745
+ </td>
746
+ </tr>
747
+ <?php
748
+ return ob_get_clean();
749
+ }
750
+
751
+ /**
752
+ * Renders the textarea field
753
+ *
754
+ * @param array $db_options addons DB options
755
+ * @param string $key array key of class argument
756
+ * @param array $args class args
757
+ *
758
+ * @return string
759
+ */
760
+ public function _codemirror($db_options, $key, $args)
761
+ {
762
+ $key = esc_attr($key);
763
+ $label = esc_attr($args['label']);
764
+ $description = @$args['description'];
765
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
766
+ $option_name = $this->option_name;
767
+ $value = ! empty($db_options[$key]) ? stripslashes($db_options[$key]) : @$args['value'];
768
+ $name_attr = isset($args['skip_name']) ? '' : 'name="' . $option_name . '[' . $key . ']"';
769
+ ob_start();
770
+ ?>
771
+ <tr id="<?=$tr_id; ?>">
772
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
773
+ <td>
774
+ <?php do_action('wp_cspa_before_codemirror_field', $db_options, $option_name, $key, $args); ?>
775
+ <textarea class="pp-codemirror-editor-textarea" <?= $name_attr ?> id="<?=$key; ?>"><?=$value; ?></textarea>
776
+ <?php do_action('wp_cspa_after_codemirror_field', $db_options, $option_name, $key, $args); ?>
777
+ <p class="description"><?=$description; ?></p>
778
+ </td>
779
+ </tr>
780
+ <?php
781
+ return ob_get_clean();
782
+ }
783
+
784
+ /**
785
+ * Renders the textarea field
786
+ *
787
+ * @param array $db_options addons DB options
788
+ * @param string $key array key of class argument
789
+ * @param array $args class args
790
+ *
791
+ * @return string
792
+ */
793
+ public function _wp_editor($db_options, $key, $args)
794
+ {
795
+ // Remove all TinyMCE plugins.
796
+ remove_all_filters('mce_buttons', 10);
797
+ remove_all_filters('mce_external_plugins', 10);
798
+
799
+ remove_all_actions('media_buttons');
800
+ // add core media button back.
801
+ add_action('media_buttons', 'media_buttons');
802
+
803
+ do_action('wp_cspa_media_button');
804
+
805
+ $key = esc_attr($key);
806
+ $label = esc_attr($args['label']);
807
+ $description = @$args['description'];
808
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
809
+ $option_name = $this->option_name;
810
+ $value = ! empty($db_options[$key]) ? stripslashes($db_options[$key]) : @$args['value'];
811
+ $settings = ! empty($args['settings']) ? $args['settings'] : ['wpautop'=> false];
812
+
813
+ $settings = array_replace(['textarea_name' => $option_name . '[' . $key . ']'], $settings);
814
+ ob_start();
815
+ ?>
816
+ <tr id="<?=$tr_id; ?>">
817
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
818
+ <td>
819
+ <?php do_action('wp_cspa_before_wp_editor_field', $db_options, $option_name, $key, $args); ?>
820
+ <?php wp_editor($value, $key, $settings); ?>
821
+ <?php do_action('wp_cspa_after_wp_editor_field', $db_options, $option_name, $key, $args); ?>
822
+
823
+ <p class="description"><?=$description; ?></p>
824
+ </td>
825
+ </tr>
826
+ <?php
827
+ return ob_get_clean();
828
+ }
829
+
830
+ /**
831
+ * Renders the email field
832
+ *
833
+ * @param array $db_options addons DB options
834
+ * @param string $key array key of class argument
835
+ * @param array $args class args
836
+ *
837
+ * @return string
838
+ */
839
+ public function _email_editor($db_options, $key, $args)
840
+ {
841
+ $key = esc_attr($key);
842
+ $label = esc_attr($args['label']);
843
+ $description = @$args['description'];
844
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
845
+ $option_name = $this->option_name;
846
+ $value = ! empty($db_options[$key]) ? stripslashes($db_options[$key]) : @$args['value'];
847
+
848
+ ob_start();
849
+ ?>
850
+ <tr id="<?=$tr_id; ?>">
851
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
852
+ <td>
853
+ <?php do_action('wp_cspa_before_email_editor_field', $db_options, $option_name, $key, $args); ?>
854
+
855
+ <div class="loginwp-email-editor-wrap">
856
+ <div class="pp-email-editor-tab">
857
+ <button class="pp-email-editor-tablinks ecode"><?= esc_html__('Code', 'peters-login-redirect'); ?></button>
858
+ <button class="pp-email-editor-tablinks epreview eactive"><?= esc_html__('Preview', 'peters-login-redirect'); ?></button>
859
+ </div>
860
+
861
+ <div class="pp-email-editor-tabcontent ecode">
862
+ <textarea class="pp-email-editor-textarea" style="width:100%!important;" rows="20" name="<?=$option_name, '[', $key, ']'; ?>" id="<?=$key; ?>"><?=$value; ?></textarea>
863
+ </div>
864
+
865
+ <div id="<?= $key ?>_preview_tabcontent" class="pp-email-editor-tabcontent epreview"><?=$value; ?></div>
866
+ </div>
867
+
868
+ <?php do_action('wp_cspa_after_email_editor_field', $db_options, $option_name, $key, $args); ?>
869
+
870
+ <p class="description"><?=$description; ?></p>
871
+ </td>
872
+ </tr>
873
+ <?php
874
+ return ob_get_clean();
875
+ }
876
+
877
+ /**
878
+ * Renders the select dropdown
879
+ *
880
+ * @param array $db_options addons DB options
881
+ * @param string $key array key of class argument
882
+ * @param array $args class args
883
+ *
884
+ * @return string
885
+ */
886
+ public function _select($db_options, $key, $args)
887
+ {
888
+ $key = esc_attr($key);
889
+ $label = esc_attr($args['label']);
890
+ $description = @$args['description'];
891
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
892
+ $disabled = isset($args['disabled']) && $args['disabled'] === true ? 'disabled="disabled"' : '';
893
+ $options = $args['options'];
894
+ $default_select_value = @$args['value'];
895
+ $option_name = $this->option_name;
896
+ $attributes = @$args['attributes'];
897
+ $attributes_output = '';
898
+ if(is_array($attributes) && !empty($attributes)) {
899
+ foreach ($attributes as $attr => $val) {
900
+ $attributes_output .= sprintf(' %s = "%s"', $attr, $val);
901
+ }
902
+ }
903
+ ob_start() ?>
904
+ <tr id="<?=$tr_id; ?>">
905
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
906
+ <td>
907
+ <?php do_action('wp_cspa_before_select_dropdown', $db_options, $option_name, $key, $args); ?>
908
+ <select id="<?=$key; ?>" name="<?=$option_name, '[', $key, ']'; ?>" <?=$disabled; ?><?=$attributes_output?>>
909
+ <?php foreach ($options as $option_key => $option_value) : ?>
910
+ <?php if(is_array($option_value)) : ?>
911
+ <optgroup label="<?=$option_key?>">
912
+ <?php foreach ($option_value as $key2 => $value2) : ?>
913
+ <option value="<?=$key2; ?>" <?php ! empty($db_options[$key]) ? selected($db_options[$key], $key2) : selected($key2, $default_select_value); ?>><?=esc_attr($value2); ?></option>
914
+ <?php endforeach; ?>
915
+ </optgroup>
916
+ <?php endif;?>
917
+
918
+ <?php if(!is_array($option_value)) : ?>
919
+ <option value="<?=$option_key; ?>" <?php ! empty($db_options[$key]) ? selected($db_options[$key], $option_key) : selected($option_key, $default_select_value); ?>><?=esc_attr($option_value); ?></option>
920
+ <?php endif;?>
921
+
922
+ <?php endforeach; ?>
923
+ </select>
924
+ <?php do_action('wp_cspa_after_select_dropdown', $db_options, $option_name, $key, $args); ?>
925
+
926
+ <p class="description"><?=$description; ?></p>
927
+ </td>
928
+ </tr>
929
+ <?php
930
+ return ob_get_clean();
931
+ }
932
+
933
+ protected function select2_selected($db_options, $field_key, $option_value, $default_values = [])
934
+ {
935
+ $bucket = $default_values;
936
+
937
+ if (! empty($db_options[$field_key])) {
938
+ $bucket = $db_options[$field_key];
939
+ }
940
+
941
+ return in_array($option_value, $bucket) ? 'selected' : '';
942
+ }
943
+
944
+ /**
945
+ * Renders the select2 dropdown
946
+ *
947
+ * @param array $db_options addons DB options
948
+ * @param string $key array key of class argument
949
+ * @param array $args class args
950
+ *
951
+ * @return string
952
+ */
953
+ public function _select2($db_options, $key, $args)
954
+ {
955
+ $key = esc_attr($key);
956
+ $label = esc_attr($args['label']);
957
+ $description = @$args['description'];
958
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
959
+ $disabled = isset($args['disabled']) && $args['disabled'] === true ? 'disabled="disabled"' : '';
960
+ $options = $args['options'];
961
+ $default_select_value = isset($args['value']) ? $args['value'] : [];
962
+ $option_name = $this->option_name;
963
+ ob_start() ?>
964
+ <tr id="<?=$tr_id; ?>">
965
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
966
+ <td>
967
+ <?php do_action('wp_cspa_before_select2_dropdown', $db_options, $option_name, $key, $args); ?>
968
+ <input type="hidden" name="<?=$option_name, '[', $key, '][]'; ?>" value="">
969
+ <select class="wp-csa-select2" id="<?=$key; ?>" name="<?=$option_name, '[', $key, '][]'; ?>" <?=$disabled; ?> multiple>
970
+ <?php foreach ($options as $option_key => $option_value) : ?>
971
+ <?php if(is_array($option_value)) : ?>
972
+ <optgroup label="<?=$option_key?>">
973
+ <?php foreach ($option_value as $key2 => $value2) : ?>
974
+ <option value="<?=$key2; ?>" <?= $this->select2_selected($db_options,$key,$key2,$default_select_value);?>><?=esc_attr($value2); ?></option>
975
+ <?php endforeach; ?>
976
+ </optgroup>
977
+ <?php endif;?>
978
+
979
+ <?php if(!is_array($option_value)) : ?>
980
+ <option value="<?=$option_key; ?>" <?= $this->select2_selected($db_options,$key,$option_key,$default_select_value);?>><?=esc_attr($option_value); ?></option>
981
+ <?php endif;?>
982
+
983
+ <?php endforeach; ?>
984
+ </select>
985
+ <?php do_action('wp_cspa_after_select2_dropdown', $db_options, $option_name, $key, $args); ?>
986
+
987
+ <p class="description"><?=$description; ?></p>
988
+ </td>
989
+ </tr>
990
+ <?php
991
+ return ob_get_clean();
992
+ }
993
+
994
+ /**
995
+ * Renders the checkbox field
996
+ *
997
+ * @param array $db_options addons DB options
998
+ * @param string $key array key of class argument
999
+ * @param array $args class args
1000
+ *
1001
+ * @return string
1002
+ */
1003
+ public function _checkbox($db_options, $key, $args)
1004
+ {
1005
+ $key = esc_attr($key);
1006
+ $label = esc_attr($args['label']);
1007
+ $description = @$args['description'];
1008
+ $tr_id = isset($args['tr_id']) ? $args['tr_id'] : "{$key}_row";
1009
+ $checkbox_label = ! empty($args['checkbox_label']) ? sanitize_text_field($args['checkbox_label']) : esc_html__('Activate', 'peters-login-redirect');
1010
+ $value = ! empty($args['value']) ? esc_attr($args['value']) : 'true';
1011
+ $default_value = isset($db_options[$key]) && ! empty($db_options[$key]) ? $db_options[$key] : @$args['default_value'];
1012
+ $option_name = $this->option_name;
1013
+ $is_disabled = isset($args['disabled']) && $args['disabled'] == 'true';
1014
+ ob_start();
1015
+ ?>
1016
+ <tr id="<?=$tr_id; ?>">
1017
+ <th scope="row"><label for="<?=$key; ?>"><?=$label; ?></label></th>
1018
+ <td>
1019
+ <?php do_action('wp_cspa_before_checkbox_field', $db_options, $option_name, $key, $args); ?>
1020
+ <strong><label for="<?=$key; ?>"><?=$checkbox_label; ?></label></strong>
1021
+ <input type="hidden" name="<?=$option_name, '[', $key, ']'; ?>" value="false">
1022
+ <input type="checkbox" id="<?=$key; ?>" name="<?=$option_name, '[', $key, ']'; ?>" value="<?=$value; ?>"<?= $is_disabled ? ' disabled' : ''?> <?php checked($default_value, $value); ?> />
1023
+ <?php do_action('wp_cspa_after_checkbox_field', $db_options, $option_name, $key, $args); ?>
1024
+
1025
+ <p class="description"><?=$description; ?></p>
1026
+ </td>
1027
+ </tr>
1028
+ <?php
1029
+ return ob_get_clean();
1030
+ }
1031
+
1032
+ /**
1033
+ * Section header
1034
+ *
1035
+ * @param string $section_title
1036
+ * @param mixed $args
1037
+ *
1038
+ * @return string
1039
+ */
1040
+ public function _header($args)
1041
+ {
1042
+ $section_title = $args['section_title'];
1043
+ ob_start();
1044
+ ?>
1045
+ <div class="postbox">
1046
+ <?php do_action('wp_cspa_header', $args, $this->option_name); ?>
1047
+ <div class="postbox-header"><h3 class="hndle is-non-sortable"><span><?=$section_title; ?></span></h3></div>
1048
+ <div class="inside">
1049
+ <table class="form-table">
1050
+ <?php
1051
+ return ob_get_clean();
1052
+ }
1053
+
1054
+
1055
+ /**
1056
+ * Section header without the frills (title and toggle button).
1057
+ *
1058
+ * @return string
1059
+ */
1060
+ public function _header_without_frills($args)
1061
+ {
1062
+ ob_start();
1063
+ ?>
1064
+ <div class="postbox">
1065
+ <?php do_action('wp_cspa_header', $args, $this->option_name); ?>
1066
+ <div class="inside">
1067
+ <table class="form-table">
1068
+ <?php
1069
+ return ob_get_clean();
1070
+ }
1071
+
1072
+ /**
1073
+ * Section footer.
1074
+ *
1075
+ * @return string
1076
+ */
1077
+ public function _footer($disable_submit_button = null)
1078
+ {
1079
+ return '</table>
1080
+ <p><input class="button-primary" type="submit" name="save_' . $this->option_name . '" value="'. esc_html__('Save Changes', 'peters-login-redirect'). '"></p>
1081
+ </div>
1082
+ </div>';
1083
+ }
1084
+
1085
+ /**
1086
+ * Section footer without "save changes" button.
1087
+ *
1088
+ * @return string
1089
+ */
1090
+ public function _footer_without_button()
1091
+ {
1092
+ return '</table>
1093
+ </div>
1094
+ </div>';
1095
+ }
1096
+
1097
+ public function header_tab_menus()
1098
+ {
1099
+
1100
+ }
1101
+
1102
+ /**
1103
+ * Build the settings page.
1104
+ *
1105
+ * @param bool $exclude_sidebar set to true to remove sidebar markup (.column-2)
1106
+ *
1107
+ * @return mixed|void
1108
+ */
1109
+ public function build($exclude_sidebar = false, $exclude_top_tav_nav = false)
1110
+ {
1111
+ $this->exclude_top_tav_nav = $exclude_top_tav_nav;
1112
+
1113
+ $columns2_class = ! $exclude_sidebar ? ' columns-2' : null;
1114
+
1115
+ $view_classes = '';
1116
+ if(!empty($this->view_classes)) {
1117
+ $view_classes = ' '. $this->view_classes;
1118
+ }
1119
+
1120
+ $wrap_classes = '';
1121
+ if(!empty($this->wrap_classes)) {
1122
+ $wrap_classes = ' '. $this->wrap_classes;
1123
+ }
1124
+
1125
+ if($this->remove_white_design === true) {
1126
+ $this->remove_white_styling_css();
1127
+ $view_classes .= ' remove_white_styling';
1128
+ }
1129
+
1130
+ do_action('wp_cspa_before_settings_page_build',$this->option_name);
1131
+ ?>
1132
+ <div class="wrap<?=$wrap_classes?>">
1133
+ <?php $this->settings_page_heading(); ?>
1134
+ <?php $this->do_settings_errors(); ?>
1135
+ <?php settings_errors('wp_csa_notice'); ?>
1136
+ <?php $this->settings_page_tab(); ?>
1137
+ <?php do_action('wp_cspa_after_settings_tab', $this->option_name); ?>
1138
+ <div id="poststuff" class="wp_csa_view <?=$this->option_name; ?><?=$view_classes;?>">
1139
+ <?php do_action('wp_cspa_before_metabox_holder_column'); ?>
1140
+ <div id="post-body" class="metabox-holder<?=$columns2_class; ?>">
1141
+ <div id="post-body-content">
1142
+ <?php do_action('wp_cspa_before_post_body_content', $this->option_name, $this->db_options); ?>
1143
+ <div class="meta-box-sortables ui-sortable">
1144
+ <form method="post" <?php do_action('wp_cspa_form_tag', $this->option_name); ?>>
1145
+ <?php $this->nonce_field(); ?>
1146
+ <?php ob_start(); ?>
1147
+ <?php $this->_settings_page_main_content_area(); ?>
1148
+ <?=apply_filters('wp_cspa_main_content_area', ob_get_clean(), $this->option_name); ?>
1149
+ </form>
1150
+ </div>
1151
+ </div>
1152
+ <?php $this->setting_page_sidebar(); ?>
1153
+ </div>
1154
+ </div>
1155
+ </div>
1156
+
1157
+ <?php $this->metabox_toggle_script(); ?>
1158
+ <?php
1159
+ }
1160
+
1161
+ /**
1162
+ * For building settings page with vertical sidebar tab menus.
1163
+ */
1164
+ public function build_sidebar_tab_style()
1165
+ {
1166
+ $settings_args = $this->main_content_config;
1167
+ $option_name = $this->option_name;
1168
+
1169
+ do_action('loginwp_before_settings_page', $option_name);
1170
+ $nav_tabs = '';
1171
+ $tab_content_area = '';
1172
+
1173
+ if ( ! empty($settings_args)) {
1174
+ foreach ($settings_args as $key => $settings_arg) {
1175
+ $tab_title = @$settings_arg['tab_title'];
1176
+ $section_title = @$settings_arg['section_title'];
1177
+ $dashicon = isset($settings_arg['dashicon']) ? $settings_arg['dashicon'] : 'dashicons-admin-generic';
1178
+ unset($settings_arg['tab_title']);
1179
+ unset($settings_arg['section_title']);
1180
+ unset($settings_arg['dashicon']);
1181
+
1182
+ $dashicon_html = '';
1183
+ if(!empty($dashicon)) {
1184
+ $dashicon_html = sprintf('<span class="dashicons %s"></span>', $dashicon);
1185
+ }
1186
+
1187
+ $nav_tabs .= sprintf('<a href="#%1$s" class="nav-tab" id="%1$s-tab">%3$s %2$s</a>', $key, $tab_title, $dashicon_html);
1188
+
1189
+ if (isset($settings_arg[0]['section_title'])) {
1190
+ $tab_content_area .= sprintf('<div id="%s" class="pp-group-wrapper">', $key);
1191
+ foreach ($settings_arg as $single_arg) {
1192
+ $tab_content_area .= $this->metax_box_instance($single_arg);
1193
+ }
1194
+ $tab_content_area .= '</div>';
1195
+ } else {
1196
+ $settings_arg['section_title'] = $section_title;
1197
+ $tab_content_area .= sprintf('<div id="%s" class="pp-group-wrapper">', $key);
1198
+ $tab_content_area .= $this->metax_box_instance($settings_arg);
1199
+ $tab_content_area .= '</div>';
1200
+ }
1201
+ }
1202
+
1203
+ echo '<div class="wrap ppview">';
1204
+ $this->settings_page_heading();
1205
+ $this->do_settings_errors();
1206
+ settings_errors('wp_csa_notice');
1207
+ $this->settings_page_tab();
1208
+
1209
+ echo '<div class="pp-settings-wrap" data-option-name="' . $option_name . '">';
1210
+ echo '<h2 class="nav-tab-wrapper">' . $nav_tabs . '</h2>';
1211
+ echo '<div class="metabox-holder pp-tab-settings">';
1212
+ echo '<form method="post">';
1213
+ ob_start();
1214
+ $this->nonce_field();
1215
+ echo $tab_content_area;
1216
+ echo apply_filters('wp_cspa_main_content_area', ob_get_clean(), $this->option_name);
1217
+ echo '</form>';
1218
+ echo '</div>';
1219
+ echo '</div>';
1220
+ echo '</div>';
1221
+
1222
+ do_action('loginwp_after_settings_page', $option_name);
1223
+ }
1224
+ }
1225
+
1226
+ /**
1227
+ * Do not make this a singleton
1228
+ *
1229
+ * @param array $main_content_config
1230
+ * @param string $option_name
1231
+ * @param string $page_header
1232
+ *
1233
+ * @return self
1234
+ */
1235
+ public static function instance($main_content_config = [], $option_name = '', $page_header = '')
1236
+ {
1237
+ return new self($main_content_config, $option_name, $page_header);
1238
+ }
1239
+ }
src/core/src/Admin/index.php ADDED
File without changes
src/core/src/Admin/views/include.view.php ADDED
@@ -0,0 +1,63 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ use LoginWP\Core\Admin\RedirectWPList;
4
+ use LoginWP\Core\Helpers;
5
+
6
+ $ruleData = [];
7
+
8
+ if (isset($_GET['id'])) {
9
+ $ruleData = Helpers::get_rule_by_id(absint($_GET['id']));
10
+ }
11
+
12
+ add_action('add_meta_boxes', function () use ($ruleData) {
13
+ add_meta_box(
14
+ 'ptr-loginwp-redirection-rule-condition',
15
+ esc_html__('Rule Condition', 'peters-login-redirect'),
16
+ function () use ($ruleData) {
17
+ require dirname(__FILE__) . '/view.condition-rule.php';
18
+ },
19
+ 'ptrloginwpredirection'
20
+ );
21
+ });
22
+
23
+ add_action('add_meta_boxes', function () use ($ruleData) {
24
+ add_meta_box(
25
+ 'ptr-loginwp-redirection-rule-urls',
26
+ esc_html__('Redirect URLs', 'peters-login-redirect'),
27
+ function () use ($ruleData) {
28
+ require dirname(__FILE__) . '/view.redirect-urls.php';
29
+ },
30
+ 'ptrloginwpredirection'
31
+ );
32
+ });
33
+
34
+ do_action('add_meta_boxes', 'ptrloginwpredirection', '');
35
+
36
+ ?>
37
+ <div style="padding-top: 0">
38
+ <div id="post-body" class="metabox-holder">
39
+
40
+ <div class="loginwp-rule-actions-wrap">
41
+
42
+ <div class="loginwp-delete-action">
43
+ <?php if (isset($_GET['action']) && 'edit' == $_GET['action']) : ?>
44
+ <a class="loginwp-delete-prompt" href="<?php echo esc_url(RedirectWPList::delete_rule_url(absint($_GET['id']))); ?>"><?= esc_html__('Delete', 'peters-login-redirect') ?></a>
45
+ <?php endif; ?>
46
+ </div>
47
+
48
+ <div class="loginwp-save-action">
49
+ <?php wp_nonce_field('loginwp_save_rule', 'rul-loginwp-nonce') ?>
50
+ <input style="min-height: 35px;padding: 0 15px;" type="submit" name="loginwp_save_rule" class="button button-primary button-large" value="<?= esc_html__('Save Rule', 'peters-login-redirect') ?>">
51
+ </div>
52
+ <div class="clear"></div>
53
+ </div>
54
+
55
+ <div id="postbox-container-1" class="postbox-container">
56
+ <?php do_meta_boxes('ptrloginwpredirection', 'sidebar', ''); ?>
57
+ </div>
58
+ <div id="postbox-container-2" class="postbox-container">
59
+ <?php do_meta_boxes('ptrloginwpredirection', 'advanced', ''); ?>
60
+ </div>
61
+ </div>
62
+ <br class="clear">
63
+ </div>
src/core/src/Admin/views/view.bottom-settings.php ADDED
@@ -0,0 +1,119 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ use LoginWP\Core\Helpers;
4
+
5
+ $other_users_rule = Helpers::get_other_users_rule();
6
+
7
+ $rul_allvalue = $other_users_rule['rul_url'];
8
+ $rul_allvalue_logout = $other_users_rule['rul_url_logout'];
9
+ $after_registration = Helpers::get_after_registration_rule();
10
+
11
+ $rul_settings = Helpers::redirectFunctionCollection_get_settings();
12
+ $rul_allow_post_redirect_override = $rul_settings['rul_allow_post_redirect_override'];
13
+ $rul_allow_post_redirect_override_logout = $rul_settings['rul_allow_post_redirect_override_logout'];
14
+
15
+ $modal_title = esc_html__('View Available Placeholders', 'peters-login-redirect');
16
+ ?>
17
+
18
+ <div style="margin: 30px 0 10px;padding:0 12px 12px;">
19
+
20
+ <h3><?php _e('All Other Users', 'peters-login-redirect'); ?></h3>
21
+
22
+ <a href="#TB_inline?&width=600&height=400&inlineId=loginwp-view-placeholders" class="thickbox" title="<?= $modal_title ?>">
23
+ <?php echo $modal_title; ?>
24
+ </a>
25
+
26
+ <form name="rul_allform" method="post">
27
+ <table class="form-table">
28
+ <tbody>
29
+ <tr>
30
+ <th scope="row"><label for="rul_all"><?php _e('Login URL:', 'peters-login-redirect') ?></label>
31
+ </th>
32
+ <td>
33
+ <input id="rul_all" class="regular-text" type="text" size="90" maxlength="500" name="rul_all" value="<?php echo esc_url($rul_allvalue); ?>"/>
34
+ </td>
35
+ </tr>
36
+ <tr>
37
+ <th scope="row">
38
+ <label for="rul_all_logout"><?php _e('Logout URL:', 'peters-login-redirect') ?></label>
39
+ </th>
40
+ <td>
41
+ <input id="rul_all_logout" class="regular-text" type="text" size="90" maxlength="500" name="rul_all_logout" value="<?php echo esc_url($rul_allvalue_logout); ?>"/>
42
+ </td>
43
+ </tr>
44
+ </tbody>
45
+ </table>
46
+ <?php wp_nonce_field('rul_allupdatesubmit', 'rul-security'); ?>
47
+ <p>
48
+ <input class="button-primary" type="submit" name="rul_allupdatesubmit" value="<?php _e('Save Changes', 'peters-login-redirect'); ?>">
49
+ </p>
50
+ </form>
51
+ </div>
52
+
53
+ <hr>
54
+
55
+ <div style="margin: 15px 0;padding:0 12px 12px;">
56
+
57
+ <h3><?php _e('After Registration', 'peters-login-redirect'); ?></h3>
58
+
59
+ <form name="rul_registerform" method="post">
60
+ <table class="form-table">
61
+ <tbody>
62
+ <tr>
63
+ <th scope="row">
64
+ <label for="rul_register"><?php _e('URL:', 'peters-login-redirect') ?></label>
65
+ </th>
66
+ <td>
67
+ <input id="rul_register" class="regular-text" type="text" size="90" maxlength="500" name="rul_register" value="<?php echo esc_url($after_registration); ?>"/>
68
+ </td>
69
+ </tr>
70
+ </tbody>
71
+ </table>
72
+ <?php wp_nonce_field('rul_registerupdatesubmit', 'rul-security'); ?>
73
+ <p>
74
+ <input class="button-primary" type="submit" name="rul_registerupdatesubmit" value="<?php _e('Save Changes', 'peters-login-redirect'); ?>">
75
+ </p>
76
+ </form>
77
+ </div>
78
+ <hr>
79
+ <div style="margin: 15px 0;padding:0 12px 12px;">
80
+ <h3><?php _e('Redirect Settings', 'peters-login-redirect'); ?></h3>
81
+ <form name="rul_settingsform" method="post">
82
+ <table class="widefat">
83
+ <tr>
84
+ <td>
85
+ <p>
86
+ <strong><?php _e('Allow a POST or GET &#34;redirect_to&#34; variable to take redirect precedence', 'peters-login-redirect'); ?></strong>
87
+ </p>
88
+ </td>
89
+ <td>
90
+ <label>
91
+ <select name="rul_allow_post_redirect_override">
92
+ <option value="1" <?php selected($rul_allow_post_redirect_override, '1'); ?>><?php _e('Yes', 'peters-login-redirect'); ?></option>
93
+ <option value="0" <?php selected($rul_allow_post_redirect_override, '0'); ?>><?php _e('No', 'peters-login-redirect'); ?></option>
94
+ </select>
95
+ </label>
96
+ </td>
97
+ </tr>
98
+ <tr>
99
+ <td>
100
+ <p>
101
+ <strong><?php _e('Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect precedence', 'peters-login-redirect'); ?></strong>
102
+ </p>
103
+ </td>
104
+ <td>
105
+ <label>
106
+ <select name="rul_allow_post_redirect_override_logout">
107
+ <option value="1" <?php selected($rul_allow_post_redirect_override_logout, '1'); ?>><?php _e('Yes', 'peters-login-redirect'); ?></option>
108
+ <option value="0" <?php selected($rul_allow_post_redirect_override_logout, '0'); ?>><?php _e('No', 'peters-login-redirect'); ?></option>
109
+ </select>
110
+ </label>
111
+ </td>
112
+ </tr>
113
+ </table>
114
+ <?php wp_nonce_field('rul_settingssubmit', 'rul-security'); ?>
115
+ <p class="submit">
116
+ <input class="button button-primary" name="rul_settingssubmit" type="submit" value="<?php _e('Save Changes', 'peters-login-redirect'); ?>"/>
117
+ </p>
118
+ </form>
119
+ </div>
src/core/src/Admin/views/view.condition-rule.php ADDED
@@ -0,0 +1,43 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ use LoginWP\Core\Admin\RedirectionsPage;
4
+
5
+ $db_condition = sanitize_text_field(loginwpPOST_var('rul_condition', loginwp_var($ruleData, 'rul_type', '')));
6
+ $db_condition_value = sanitize_text_field(loginwpPOST_var('rul_condition_value', loginwp_var($ruleData, 'rul_value', '')));
7
+ $db_condition_order = absint(loginwpPOST_var('rul_order', loginwp_var($ruleData, 'rul_order', 0)));
8
+
9
+ ?>
10
+ <div class="ptr-loginwp-condition-wrap">
11
+ <div class="ptr-loginwp-row">
12
+ <div id="ptr-loginwp-condition-wrap" class="ptr-loginwp-col">
13
+ <label>
14
+ <select name="rul_condition">
15
+ <option value=""><?php esc_html_e('Select a condition', 'peters-login-redirect'); ?></option>
16
+ <?php foreach (RedirectionsPage::get_rule_conditions() as $condition) : ?>
17
+ <option value="<?php echo esc_attr($condition['id']) ?>" <?php selected($db_condition, $condition['id']) ?>>
18
+ <?php echo esc_html($condition['label']) ?>
19
+ </option>
20
+ <?php endforeach; ?>
21
+ </select>
22
+ </label>
23
+ </div>
24
+ <div id="ptr-loginwp-condition-value-wrap" class="ptr-loginwp-col">
25
+ <?php RedirectionsPage::condition_value_dropdown($db_condition, $db_condition_value); ?>
26
+ </div>
27
+ </div>
28
+ </div>
29
+
30
+ <div class="ptr-loginwp-order-wrap"<?php echo ! in_array($db_condition, RedirectionsPage::order_support_conditions()) ? 'style="display:none"' : ''; ?>>
31
+ <table class="form-table">
32
+ <tbody>
33
+ <tr>
34
+ <th>
35
+ <label for="loginwp-login-url"><?= esc_html__('Order', 'peters-login-redirect') ?></label>
36
+ </th>
37
+ <td>
38
+ <input name="rul_order" type="number" id="loginwp-login-url" value="<?php echo $db_condition_order; ?>" class="regular-text">
39
+ </td>
40
+ </tr>
41
+ </tbody>
42
+ </table>
43
+ </div>
src/core/src/Admin/views/view.redirect-urls.php ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ $login_url = loginwpPOST_var('rul_login_url', loginwp_var($ruleData, 'rul_url', ''));
4
+ $logout_url = loginwpPOST_var('rul_logout_url', loginwp_var($ruleData, 'rul_url_logout', ''));
5
+
6
+ $modal_title = esc_html__('View Available Placeholders', 'peters-login-redirect');
7
+ ?>
8
+ <div class="ptr-loginwp-redirect-wrap">
9
+ <div class="loginwp-view-variables">
10
+ <a href="#TB_inline?&width=600&height=400&inlineId=loginwp-view-placeholders" class="thickbox" title="<?= $modal_title ?>">
11
+ <?php echo $modal_title; ?>
12
+ </a>
13
+ </div>
14
+ <table class="form-table">
15
+ <tbody>
16
+ <tr>
17
+ <th>
18
+ <label for="rul_login_url"><?= esc_html__('Login URL', 'peters-login-redirect') ?></label>
19
+ </th>
20
+ <td>
21
+ <input name="rul_login_url" type="text" id="rul_login_url" value="<?php echo $login_url; ?>" class="regular-text">
22
+ </td>
23
+ </tr>
24
+ <tr>
25
+ <th>
26
+ <label for="rul_logout_url"><?= esc_html__('Logout URL', 'peters-login-redirect') ?></label>
27
+ </th>
28
+ <td>
29
+ <input name="rul_logout_url" type="text" id="rul_logout_url" value="<?php echo $logout_url; ?>" class="regular-text">
30
+ </td>
31
+ </tr>
32
+ </tbody>
33
+ </table>
34
+ </div>
src/core/src/Core.php ADDED
@@ -0,0 +1,179 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core;
4
+
5
+ global $wpdb;
6
+
7
+ use LoginWP\Core\Redirections\Redirections;
8
+
9
+ define('PTR_LOGINWP_DB_TABLE', $wpdb->prefix . 'login_redirects');
10
+ define('PTR_LOGINWP_SETTINGS_PAGE_SLUG', 'loginwp-settings');
11
+ define('PTR_LOGINWP_REDIRECTION_PAGE_SLUG', 'loginwp-redirections');
12
+ define('PTR_LOGINWP_REDIRECTIONS_PAGE_URL', admin_url('admin.php?page=' . PTR_LOGINWP_REDIRECTION_PAGE_SLUG));
13
+
14
+ define('PTR_LOGINWP_URL', plugin_dir_url(PTR_LOGINWP_SYSTEM_FILE_PATH));
15
+ define('PTR_LOGINWP_ASSETS_DIR', wp_normalize_path(dirname(PTR_LOGINWP_SYSTEM_FILE_PATH) . '/assets/'));
16
+
17
+ if (strpos(__FILE__, 'peters-login-redirect/' . DIRECTORY_SEPARATOR . 'src') !== false) {
18
+ // production url path to assets folder.
19
+ define('PTR_LOGINWP_ASSETS_URL', PTR_LOGINWP_URL . 'src/core/assets/');
20
+ } else {
21
+ // dev url path to assets folder.
22
+ define('PTR_LOGINWP_ASSETS_URL', PTR_LOGINWP_URL . '../' . dirname(dirname(substr(__FILE__, strpos(__FILE__, 'peters-login-redirect')))) . '/assets/');
23
+ }
24
+
25
+ class Core
26
+ {
27
+ public function __construct()
28
+ {
29
+ register_activation_hook(PTR_LOGINWP_SYSTEM_FILE_PATH, [__CLASS__, 'rul_activate_plugin']);
30
+ add_filter('wpmu_drop_tables', [$this, 'rul_drop_tables']);
31
+ add_action('activate_blog', [$this, 'rul_site_added']);
32
+
33
+ // Wpmu_new_blog has been deprecated in 5.1 and replaced by wp_insert_site.
34
+ global $wp_version;
35
+ if (version_compare($wp_version, '5.1', '<')) {
36
+ add_action('wpmu_new_blog', [$this, 'rul_site_added']);
37
+ } else {
38
+ add_action('wp_initialize_site', [$this, 'rul_site_added'], 99);
39
+ }
40
+
41
+ add_action('admin_init', [$this, 'rul_upgrade']);
42
+
43
+ Redirections::get_instance();
44
+ Admin\Admin::get_instance();
45
+ }
46
+
47
+ public static function rul_install()
48
+ {
49
+ global $wpdb;
50
+
51
+ $rul_db_addresses = PTR_LOGINWP_DB_TABLE;
52
+
53
+ // Add the table to hold group information and moderator rules
54
+ if ($rul_db_addresses != $wpdb->get_var("SHOW TABLES LIKE '$rul_db_addresses'")) {
55
+ $sql = "CREATE TABLE $rul_db_addresses (
56
+ `id` BIGINT(20) NOT NULL AUTO_INCREMENT,
57
+ `rul_type` enum('user','role','level','all','register') NOT NULL,
58
+ `rul_value` varchar(191) NULL default NULL,
59
+ `rul_url` LONGTEXT NULL default NULL,
60
+ `rul_url_logout` LONGTEXT NULL default NULL,
61
+ `rul_order` int(2) NOT NULL default '0',
62
+ PRIMARY KEY (id),
63
+ UNIQUE KEY `rul_type` (`rul_type`,`rul_value`)
64
+ )";
65
+
66
+ $wpdb->query($sql);
67
+
68
+ // Insert the "all" redirect entry
69
+ $wpdb->insert($rul_db_addresses,
70
+ array('rul_type' => 'all')
71
+ );
72
+
73
+ // Insert the "on-register" redirect entry
74
+ $wpdb->insert($rul_db_addresses,
75
+ array('rul_type' => 'register')
76
+ );
77
+
78
+ // Set the version number in the database
79
+ add_option('rul_version', PTR_LOGINWP_VERSION_NUMBER, '', 'no');
80
+ }
81
+
82
+ add_option('loginwp_from_ab_initio', 'true');
83
+ add_option('loginwp_install_date', current_time('mysql'));
84
+
85
+ self::rul_upgrade();
86
+ }
87
+
88
+ public static function rul_activate_plugin($networkwide)
89
+ {
90
+ // Executes when plugin is activated
91
+ global $wpdb;
92
+
93
+ if (function_exists('is_multisite') && is_multisite() && $networkwide) {
94
+ $blogs = $wpdb->get_col("SELECT blog_id FROM $wpdb->blogs");
95
+ foreach ($blogs as $blog) {
96
+ switch_to_blog($blog);
97
+ self::rul_install();
98
+ restore_current_blog();
99
+ }
100
+ } else {
101
+ self::rul_install();
102
+ }
103
+ }
104
+
105
+ public function rul_site_added($blog)
106
+ {
107
+ if ( ! is_int($blog)) {
108
+ $blog = $blog->id;
109
+ }
110
+
111
+ switch_to_blog($blog);
112
+ self::rul_install();
113
+ restore_current_blog();
114
+ }
115
+
116
+ public function rul_drop_tables($tables)
117
+ {
118
+ $tables[] = PTR_LOGINWP_DB_TABLE;
119
+
120
+ return $tables;
121
+ }
122
+
123
+ // Perform upgrade functions
124
+ // Some newer operations are duplicated from rul_install() as there's no guarantee that the user will follow a specific upgrade procedure
125
+ public static function rul_upgrade()
126
+ {
127
+ global $wpdb;
128
+
129
+ $rul_db_addresses = PTR_LOGINWP_DB_TABLE;
130
+
131
+ // Turn version into an integer for comparisons
132
+ $current_version = intval(str_replace('.', '', get_option('rul_version')));
133
+ // necessary cos pro starts with version 4.
134
+ $cmp_current_version = str_replace('4.', '3.', $current_version);
135
+
136
+ if ($cmp_current_version < 220) {
137
+ $wpdb->query("ALTER TABLE `$rul_db_addresses` ADD `rul_url_logout` LONGTEXT NOT NULL default '' AFTER `rul_url`");
138
+ }
139
+
140
+ if ($cmp_current_version < 250) {
141
+
142
+ $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_type` `rul_type` ENUM( 'user', 'role', 'level', 'all', 'register' ) NOT NULL");
143
+ $wpdb->insert($rul_db_addresses,
144
+ array('rul_type' => 'register')
145
+ );
146
+ }
147
+
148
+ if ($cmp_current_version < 253) {
149
+ // Allow NULL values for non-essential fields
150
+ $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_value` `rul_value` varchar(255) NULL default NULL");
151
+ $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_url` `rul_url` LONGTEXT NULL default NULL");
152
+ $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_url_logout` `rul_url_logout` LONGTEXT NULL default NULL");
153
+ }
154
+
155
+ if ($cmp_current_version < 291) {
156
+ // Reduce size of rul_value field to support utf8mb4 character encoding
157
+ $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_value` `rul_value` varchar(191) NULL default NULL");
158
+ }
159
+
160
+ if ($cmp_current_version < 3000) {
161
+ $wpdb->query("ALTER TABLE $rul_db_addresses ADD id BIGINT NOT NULL PRIMARY KEY AUTO_INCREMENT FIRST");
162
+ }
163
+
164
+ update_option('rul_version', PTR_LOGINWP_VERSION_NUMBER, 'no');
165
+
166
+ add_option('loginwp_install_date', current_time('mysql'));
167
+ }
168
+
169
+ public static function get_instance()
170
+ {
171
+ static $instance = null;
172
+
173
+ if (is_null($instance)) {
174
+ $instance = new self();
175
+ }
176
+
177
+ return $instance;
178
+ }
179
+ }
src/core/src/Functions.php ADDED
@@ -0,0 +1,122 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ use LoginWP\Core\Helpers;
4
+ use LoginWP\Core\Redirections\Redirections;
5
+
6
+ // Typically this function is used in templates, similarly to the wp_register function
7
+ // It returns a link to the administration panel or the one that was custom defined
8
+ // If no user is logged in, it returns the "Register" link
9
+ // You can specify tags to go around the returned link (or wrap it with no tags); by default this is a list item
10
+ // You can also specify whether to print out the link or just return it
11
+ function rul_register($before = '<li>', $after = '</li>', $give_echo = true)
12
+ {
13
+ global $current_user;
14
+
15
+ if ( ! is_user_logged_in()) {
16
+ if (get_option('users_can_register')) {
17
+ $link = $before . '<a href="' . wp_registration_url() . '">' . __('Register', 'peters-login-redirect') . '</a>' . $after;
18
+ } else {
19
+ $link = '';
20
+ }
21
+ } else {
22
+ $link = $before . '<a href="' . Helpers::login_redirect_logic_callback('', '', $current_user) . '">' . __('Site Admin', 'peters-login-redirect') . '</a>' . $after;
23
+ }
24
+
25
+ if ($give_echo) {
26
+ echo $link;
27
+ } else {
28
+ return $link;
29
+ }
30
+ }
31
+
32
+ function loginwpPOST_var($key, $default = false, $empty = false, $bucket = false)
33
+ {
34
+ $bucket = ! $bucket ? $_POST : $bucket;
35
+
36
+ if ($empty) {
37
+ return ! empty($bucket[$key]) ? $bucket[$key] : $default;
38
+ }
39
+
40
+ return isset($bucket[$key]) ? $bucket[$key] : $default;
41
+ }
42
+
43
+ function loginwpGET_var($key, $default = false, $empty = false)
44
+ {
45
+ $bucket = $_GET;
46
+
47
+ if ($empty) {
48
+ return ! empty($bucket[$key]) ? $bucket[$key] : $default;
49
+ }
50
+
51
+ return isset($bucket[$key]) ? $bucket[$key] : $default;
52
+ }
53
+
54
+ function loginwp_var($bucket, $key, $default = false, $empty = false)
55
+ {
56
+ if ($empty) {
57
+ return ! empty($bucket[$key]) ? $bucket[$key] : $default;
58
+ }
59
+
60
+ return isset($bucket[$key]) ? $bucket[$key] : $default;
61
+ }
62
+
63
+ function loginwp_var_obj($bucket, $key, $default = false, $empty = false)
64
+ {
65
+ if ($empty) {
66
+ return ! empty($bucket->$key) ? $bucket->$key : $default;
67
+ }
68
+
69
+ return isset($bucket->$key) ? $bucket->$key : $default;
70
+ }
71
+
72
+ /**
73
+ * Return currently viewed page url without query string.
74
+ *
75
+ * @return string
76
+ */
77
+ function loginwp_get_current_url()
78
+ {
79
+ $protocol = 'http://';
80
+
81
+ if ((isset($_SERVER['HTTPS']) && ($_SERVER['HTTPS'] == 'on' || $_SERVER['HTTPS'] == 1))
82
+ || (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https')
83
+ ) {
84
+ $protocol = 'https://';
85
+ }
86
+
87
+ return esc_url_raw($protocol . $_SERVER['HTTP_HOST'] . parse_url($_SERVER['REQUEST_URI'], PHP_URL_PATH));
88
+ }
89
+
90
+ /**
91
+ * Return currently viewed page url with query string.
92
+ *
93
+ * @return string
94
+ */
95
+ function loginwp_get_current_url_query_string()
96
+ {
97
+ $protocol = 'http://';
98
+
99
+ if ((isset($_SERVER['HTTPS']) && ($_SERVER['HTTPS'] == 'on' || $_SERVER['HTTPS'] == 1))
100
+ || (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && $_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https')
101
+ ) {
102
+ $protocol = 'https://';
103
+ }
104
+
105
+ $url = $protocol . $_SERVER['HTTP_HOST'];
106
+
107
+ $url .= $_SERVER['REQUEST_URI'];
108
+
109
+ return esc_url_raw($url);
110
+ }
111
+
112
+ function redirect_to_front_page($redirect_to, $requested_redirect_to, $user)
113
+ {
114
+ Helpers::login_redirect_logic_callback($redirect_to, $requested_redirect_to, $user);
115
+ }
116
+
117
+ function wplogin_redirect_control_function()
118
+ {
119
+ $redirect_url = Redirections::login_redirect_callback(admin_url(), '', wp_get_current_user());
120
+ wp_redirect($redirect_url);
121
+ exit;
122
+ }
src/core/src/Helpers.php ADDED
@@ -0,0 +1,363 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core;
4
+
5
+ class Helpers
6
+ {
7
+ public static function get_rule_by_id($id)
8
+ {
9
+ global $wpdb;
10
+
11
+ return $wpdb->get_row(
12
+ $wpdb->prepare(
13
+ 'SELECT * FROM ' . PTR_LOGINWP_DB_TABLE . " WHERE id = %d",
14
+ absint($id)
15
+ ),
16
+ 'ARRAY_A'
17
+ );
18
+ }
19
+
20
+ public static function get_other_users_rule()
21
+ {
22
+ global $wpdb;
23
+
24
+ return $wpdb->get_row('SELECT rul_url, rul_url_logout FROM ' . PTR_LOGINWP_DB_TABLE . " WHERE rul_type = 'all'", 'ARRAY_A');
25
+ }
26
+
27
+ public static function get_after_registration_rule()
28
+ {
29
+ global $wpdb;
30
+
31
+ return $wpdb->get_var('SELECT rul_url FROM ' . PTR_LOGINWP_DB_TABLE . " WHERE rul_type = 'register'");
32
+ }
33
+
34
+ public static function username_list()
35
+ {
36
+ global $wpdb;
37
+
38
+ $rul_userresults = $wpdb->get_results('SELECT user_login FROM ' . $wpdb->users . ' ORDER BY user_login', 'ARRAY_N');
39
+
40
+ return array_reduce($rul_userresults, function ($carry, $item) {
41
+
42
+ $carry[$item[0]] = $item[0];
43
+
44
+ return $carry;
45
+ });
46
+ }
47
+
48
+ public static function user_role_list()
49
+ {
50
+ global $wp_roles;
51
+
52
+ $roles = array();
53
+
54
+ foreach ($wp_roles->role_names as $key => $value) {
55
+ $roles[$key] = $value;
56
+ }
57
+
58
+ return $roles;
59
+ }
60
+
61
+ public static function capability_list()
62
+ {
63
+ global $wp_roles;
64
+
65
+ $caps = array();
66
+
67
+ // Builds the array of level names by combing through each of the roles and listing their levels
68
+ foreach ($wp_roles->roles as $wp_role) {
69
+ if (isset($wp_role['capabilities']) && is_array($wp_role['capabilities'])) {
70
+ $caps = array_merge($caps, array_keys($wp_role['capabilities']));
71
+ }
72
+ }
73
+
74
+ $caps = array_unique($caps);
75
+
76
+ // Sort the level names in alphabetical order
77
+ sort($caps);
78
+
79
+ // make array value key also
80
+ $caps = array_combine($caps, $caps);
81
+
82
+ return $caps;
83
+ }
84
+
85
+ /*
86
+ This extra function is necessary to support the use case where someone was previously logged in
87
+ Thanks to http://wordpress.org/support/topic/97314 for this function
88
+ */
89
+ public static function redirect_current_user_can($capability, $current_user)
90
+ {
91
+ global $wpdb;
92
+
93
+ $roles = get_option($wpdb->prefix . 'user_roles');
94
+ $user_roles = $current_user->{$wpdb->prefix . 'capabilities'};
95
+ $user_roles = array_keys($user_roles, true);
96
+ $role = $user_roles[0];
97
+ $capabilities = $roles[$role]['capabilities'];
98
+
99
+ if (in_array($capability, array_keys($capabilities, true))) {
100
+ // check array keys of capabilities for match against requested capability
101
+ return true;
102
+ }
103
+
104
+ return false;
105
+ }
106
+
107
+ /*
108
+ A generic function to return the value mapped to a particular variable
109
+ */
110
+ public static function rul_get_variable($variable, $user)
111
+ {
112
+ $variable_value = apply_filters('rul_replace_variable', false, $variable, $user);
113
+
114
+ if ( ! $variable_value) {
115
+ // Return the permalink of the post ID
116
+ if (0 === strpos($variable, 'postid-')) {
117
+ $post_id = str_replace('postid-', '', $variable);
118
+ $permalink = get_permalink($post_id);
119
+ if ($permalink) {
120
+ $variable_value = $permalink;
121
+ }
122
+ } else {
123
+ switch ($variable) {
124
+ // Returns the current user's username (only use this if you know they're logged in)
125
+ case 'username':
126
+ $variable_value = rawurlencode($user->user_login);
127
+ break;
128
+ // Returns the current user's author slug aka nickname as used in URLs
129
+ // sanitize_title should not be required here since it was already done on insert
130
+ case 'userslug':
131
+ case 'user_slug':
132
+ $variable_value = $user->user_nicename;
133
+ break;
134
+ case 'siteurl':
135
+ $variable_value = network_site_url();
136
+ break;
137
+ case 'homeurl':
138
+ case 'website_url':
139
+ $variable_value = network_home_url();
140
+ break;
141
+ // Returns the login referrer in order to redirect back to the same page
142
+ // Note that this will not work if the referrer is the same as the login processor (otherwise in a standard setup you'd redirect to the login form)
143
+ case 'http_referer':
144
+ $referer = wp_get_referer();
145
+ $variable_value = (false != $referer) ? $referer : '';
146
+ break;
147
+ default:
148
+ $variable_value = '';
149
+ break;
150
+ }
151
+ }
152
+ }
153
+
154
+ return $variable_value;
155
+ }
156
+
157
+ /**
158
+ * Replaces the syntax [variable]variable_name[/variable] with whatever has been mapped to the variable_name in the rul_get_variable function
159
+ */
160
+ public static function rul_replace_variable($string, $user)
161
+ {
162
+ preg_match_all("/\[variable\](.*?)\[\/variable\]/i", $string, $out);
163
+
164
+ preg_match_all("/\{\{(.*?)\}\}/is", $string, $out2);
165
+
166
+ if ( ! empty($out[0])) {
167
+ foreach ($out[0] as $instance => $full_match) {
168
+ $replaced_variable = self::rul_get_variable($out[1][$instance], $user);
169
+ $string = str_replace($full_match, $replaced_variable, $string);
170
+ }
171
+ }
172
+
173
+ if ( ! empty($out2[0])) {
174
+ foreach ($out2[0] as $instance => $full_match) {
175
+ $replaced_variable = self::rul_get_variable($out2[1][$instance], $user);
176
+ $string = str_replace($full_match, $replaced_variable, $string);
177
+ }
178
+ }
179
+
180
+ return $string;
181
+ }
182
+
183
+ public static function rul_trigger_allowed_host($url)
184
+ {
185
+ $url_parsed = parse_url($url);
186
+ if (isset($url_parsed['host'])) {
187
+ $rul_allowed_hosts[] = $url_parsed['host'];
188
+ add_filter('allowed_redirect_hosts', function ($hosts) use ($rul_allowed_hosts) {
189
+ return array_merge($hosts, $rul_allowed_hosts);
190
+ });
191
+ }
192
+ }
193
+
194
+ /*
195
+ Grabs settings from the database as of version 2.5.0 of this plugin.
196
+ Defaults are defined here, but the settings values should be edited in the WordPress admin panel.
197
+ If no setting is asked for, then it returns an array of all settings; otherwise it returns a specific setting
198
+ */
199
+ public static function redirectFunctionCollection_get_settings($setting = false)
200
+ {
201
+ $rul_settings = array();
202
+
203
+ // Allow a POST or GET "redirect_to" variable to take precedence over settings within the plugin
204
+ $rul_settings['rul_allow_post_redirect_override'] = '0';
205
+
206
+ // Allow a POST or GET logout "redirect_to" variable to take precedence over settings within the plugin
207
+ $rul_settings['rul_allow_post_redirect_override_logout'] = '0';
208
+
209
+ $db_data = get_option('rul_settings', []);
210
+
211
+ // Merge the default settings with the settings form the database
212
+ // Limit the settings in case there are ones from the database that are old
213
+ foreach ($rul_settings as $key => $value) {
214
+ if (isset($db_data[$key])) {
215
+ $rul_settings[$key] = $db_data[$key];
216
+ }
217
+ }
218
+
219
+ if ( ! $setting) return $rul_settings;
220
+
221
+ if ($setting && isset($rul_settings[$setting])) return $rul_settings[$setting];
222
+
223
+ return false;
224
+ }
225
+
226
+ public static function login_redirect_logic_callback($redirect_to, $requested_redirect_to, $user)
227
+ {
228
+ global $wpdb;
229
+
230
+ $rul_custom_redirect = apply_filters('rul_before_user', false, $redirect_to, $requested_redirect_to, $user);
231
+
232
+ if ($rul_custom_redirect) return self::rul_replace_variable($rul_custom_redirect, $user);
233
+
234
+ // Check for a redirect rule for this user
235
+ $rul_user = $wpdb->get_var('SELECT rul_url FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'user\' AND rul_value = \'' . $user->user_login . '\' LIMIT 1');
236
+
237
+ if ( ! empty($rul_user)) {
238
+ $url = self::rul_replace_variable($rul_user, $user);
239
+ if ( ! empty($url)) return $url;
240
+ }
241
+
242
+ $rul_custom_redirect = apply_filters('rul_before_role', false, $redirect_to, $requested_redirect_to, $user);
243
+
244
+ if ($rul_custom_redirect) return self::rul_replace_variable($rul_custom_redirect, $user);
245
+
246
+ // Check for a redirect rule that matches this user's role
247
+ $rul_roles = $wpdb->get_results('SELECT rul_value, rul_url FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'role\' ORDER BY rul_order, rul_value', OBJECT);
248
+
249
+ if ( ! empty($rul_roles)) {
250
+
251
+ foreach ($rul_roles as $rul_role) {
252
+
253
+ if ( ! empty($rul_role->rul_url) && isset($user->{$wpdb->prefix . 'capabilities'}[$rul_role->rul_value])) {
254
+ $url = self::rul_replace_variable($rul_role->rul_url, $user);
255
+ if ( ! empty($url)) return $url;
256
+ }
257
+ }
258
+ }
259
+
260
+ $rul_custom_redirect = apply_filters('rul_before_capability', false, $redirect_to, $requested_redirect_to, $user);
261
+
262
+ if ($rul_custom_redirect) return self::rul_replace_variable($rul_custom_redirect, $user);
263
+
264
+ // Check for a redirect rule that matches this user's capability
265
+ $rul_levels = $wpdb->get_results('SELECT rul_value, rul_url FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'level\' ORDER BY rul_order, rul_value', OBJECT);
266
+
267
+ if ($rul_levels) {
268
+
269
+ foreach ($rul_levels as $rul_level) {
270
+ if ( ! empty($rul_level->rul_url) && self::redirect_current_user_can($rul_level->rul_value, $user)) {
271
+ $url = self::rul_replace_variable($rul_level->rul_url, $user);
272
+ if ( ! empty($url)) return $url;
273
+ }
274
+ }
275
+ }
276
+
277
+ $rul_custom_redirect = apply_filters('rul_before_fallback', false, $redirect_to, $requested_redirect_to, $user);
278
+
279
+ if ($rul_custom_redirect) return self::rul_replace_variable($rul_custom_redirect, $user);
280
+
281
+ $rul_all = $wpdb->get_var('SELECT rul_url FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'all\' LIMIT 1');
282
+
283
+ if ($rul_all) {
284
+
285
+ $url = self::rul_replace_variable($rul_all, $user);
286
+
287
+ if ( ! empty($url)) return $url;
288
+ }
289
+
290
+ return $redirect_to;
291
+ }
292
+
293
+ // Get the logout redirect URL according to defined rules
294
+ // Functionality for user-, role-, and capability-specific redirect rules is available
295
+ // Note that only the "all other users" redirect URL is currently implemented in the UI
296
+ public static function logout_redirect_logic_callback($user, $requested_redirect_to)
297
+ {
298
+ global $wpdb;
299
+
300
+ $rul_custom_redirect = apply_filters('rul_before_user_logout', false, $requested_redirect_to, $user);
301
+
302
+ if ($rul_custom_redirect) return self::rul_replace_variable($rul_custom_redirect, $user);
303
+
304
+ // Check for a redirect rule for this user
305
+ $rul_user = $wpdb->get_var('SELECT rul_url_logout FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'user\' AND rul_value = \'' . $user->user_login . '\' LIMIT 1');
306
+
307
+ if ($rul_user) {
308
+ $url = self::rul_replace_variable($rul_user, $user);
309
+ if ( ! empty($url)) return $url;
310
+ }
311
+
312
+ $rul_custom_redirect = apply_filters('rul_before_role_logout', false, $requested_redirect_to, $user);
313
+
314
+ if ( ! empty($rul_custom_redirect)) return self::rul_replace_variable($rul_custom_redirect, $user);
315
+
316
+ // Check for a redirect rule that matches this user's role
317
+ $rul_roles = $wpdb->get_results('SELECT rul_value, rul_url_logout FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'role\' ORDER BY rul_order, rul_value', OBJECT);
318
+
319
+ if ($rul_roles) {
320
+
321
+ foreach ($rul_roles as $rul_role) {
322
+ if ('' != $rul_role->rul_url_logout && isset($user->{$wpdb->prefix . 'capabilities'}[$rul_role->rul_value])) {
323
+ $url = self::rul_replace_variable($rul_role->rul_url_logout, $user);
324
+
325
+ if ( ! empty($url)) return $url;
326
+ }
327
+ }
328
+ }
329
+
330
+ $rul_custom_redirect = apply_filters('rul_before_capability_logout', false, $requested_redirect_to, $user);
331
+
332
+ if ($rul_custom_redirect) return self::rul_replace_variable($rul_custom_redirect, $user);
333
+
334
+ // Check for a redirect rule that matches this user's capability
335
+ $rul_levels = $wpdb->get_results('SELECT rul_value, rul_url_logout FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'level\' ORDER BY rul_order, rul_value', OBJECT);
336
+
337
+ if ($rul_levels) {
338
+ foreach ($rul_levels as $rul_level) {
339
+ if ('' != $rul_level->rul_url_logout && self::redirect_current_user_can($rul_level->rul_value, $user)) {
340
+ $url = self::rul_replace_variable($rul_level->rul_url_logout, $user);
341
+
342
+ if ( ! empty($url)) return $url;
343
+ }
344
+ }
345
+ }
346
+
347
+ $rul_custom_redirect = apply_filters('rul_before_fallback_logout', false, $requested_redirect_to, $user);
348
+
349
+ if ($rul_custom_redirect) return self::rul_replace_variable($rul_custom_redirect, $user);
350
+
351
+ // If none of the above matched, look for a rule to apply to all users
352
+ $rul_all = $wpdb->get_var('SELECT rul_url_logout FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'all\' LIMIT 1');
353
+
354
+ if ($rul_all) {
355
+
356
+ $url = self::rul_replace_variable($rul_all, $user);
357
+
358
+ if ( ! empty($url)) return $url;
359
+ }
360
+
361
+ return false;
362
+ }
363
+ }
mo-admin-notice-featured.php → src/core/src/MoAdminNotice.php RENAMED
@@ -1,38 +1,42 @@
1
  <?php
2
 
3
- if ( ! class_exists( 'MO_Admin_Notice' ) ) {
4
 
5
- class MO_Admin_Notice {
6
- public function __construct() {
7
- add_action( 'admin_notices', array( $this, 'admin_notice' ) );
8
- add_action( 'network_admin_notices', array( $this, 'admin_notice' ) );
 
 
9
 
10
- add_action( 'admin_init', array( $this, 'dismiss_admin_notice' ) );
11
  }
12
 
13
- public function dismiss_admin_notice() {
14
- if ( ! isset( $_GET['mo-adaction'] ) || $_GET['mo-adaction'] != 'mo_dismiss_adnotice' ) {
 
15
  return;
16
  }
17
 
18
  $url = admin_url();
19
- update_option( 'mo_dismiss_adnotice', 'true' );
20
 
21
- wp_redirect( $url );
22
  exit;
23
  }
24
 
25
- public function admin_notice() {
 
26
 
27
  global $pagenow;
28
 
29
- if($pagenow != 'index.php') return;
30
 
31
- if ( get_option( 'mo_dismiss_adnotice', 'false' ) == 'true' ) {
32
  return;
33
  }
34
 
35
- if ( $this->is_plugin_installed() && $this->is_plugin_active() ) {
36
  return;
37
  }
38
 
@@ -46,71 +50,75 @@ if ( ! class_exists( 'MO_Admin_Notice' ) ) {
46
  );
47
  $this->notice_css();
48
  $install_url = wp_nonce_url(
49
- admin_url( 'update.php?action=install-plugin&plugin=mailoptin' ),
50
  'install-plugin_mailoptin'
51
  );
52
 
53
- $activate_url = wp_nonce_url( admin_url( 'plugins.php?action=activate&plugin=mailoptin%2Fmailoptin.php' ), 'activate-plugin_mailoptin/mailoptin.php' );
54
  ?>
55
  <div class="mo-admin-notice notice notice-success">
56
  <div class="mo-notice-first-half">
57
  <p>
58
  <?php
59
  printf(
60
- __('Free optin form plugin that will %1$sincrease your email list subscribers%2$s and keep them engaged with %1$sautomated and schedule newsletters%2$s.'),
61
  '<span class="mo-stylize"><strong>', '</strong></span>');
62
  ?>
63
  </p>
64
- <p style="text-decoration: underline;font-size: 12px;">Recommended by "Peter's Login Redirect" plugin</p>
65
  </div>
66
  <div class="mo-notice-other-half">
67
  <?php if ( ! $this->is_plugin_installed()) : ?>
68
  <a class="button button-primary button-hero" id="mo-install-mailoptin-plugin" href="<?php echo $install_url; ?>">
69
- <?php _e('Install MailOptin Now for Free!'); ?>
70
  </a>
71
  <?php endif; ?>
72
  <?php if ($this->is_plugin_installed() && ! $this->is_plugin_active()) : ?>
73
  <a class="button button-primary button-hero" id="mo-activate-mailoptin-plugin" href="<?php echo $activate_url; ?>">
74
- <?php _e('Activate MailOptin Now!'); ?>
75
  </a>
76
  <?php endif; ?>
77
  <div class="mo-notice-learn-more">
78
- <a target="_blank" href="https://mailoptin.io">Learn more</a>
79
  </div>
80
  </div>
81
  <a href="<?php echo $dismiss_url; ?>">
82
  <button type="button" class="notice-dismiss">
83
- <span class="screen-reader-text"><?php _e('Dismiss this notice'); ?>.</span>
84
  </button>
85
  </a>
86
  </div>
87
  <?php
88
  }
89
 
90
- public function current_admin_url() {
91
- $parts = parse_url( home_url() );
 
92
  $uri = $parts['scheme'] . '://' . $parts['host'];
93
 
94
- if ( array_key_exists( 'port', $parts ) ) {
95
  $uri .= ':' . $parts['port'];
96
  }
97
 
98
- $uri .= add_query_arg( array() );
99
 
100
  return $uri;
101
  }
102
 
103
- public function is_plugin_installed() {
 
104
  $installed_plugins = get_plugins();
105
 
106
- return isset( $installed_plugins['mailoptin/mailoptin.php'] );
107
  }
108
 
109
- public function is_plugin_active() {
110
- return is_plugin_active( 'mailoptin/mailoptin.php' );
 
111
  }
112
 
113
- public function notice_css() {
 
114
  ?>
115
  <style type="text/css">
116
  .mo-admin-notice {
@@ -164,10 +172,11 @@ if ( ! class_exists( 'MO_Admin_Notice' ) ) {
164
  <?php
165
  }
166
 
167
- public static function instance() {
 
168
  static $instance = null;
169
 
170
- if ( is_null( $instance ) ) {
171
  $instance = new self();
172
  }
173
 
1
  <?php
2
 
3
+ if ( ! class_exists('MO_Admin_Notice')) {
4
 
5
+ class MO_Admin_Notice
6
+ {
7
+ public function __construct()
8
+ {
9
+ add_action('admin_notices', array($this, 'admin_notice'));
10
+ add_action('network_admin_notices', array($this, 'admin_notice'));
11
 
12
+ add_action('admin_init', array($this, 'dismiss_admin_notice'));
13
  }
14
 
15
+ public function dismiss_admin_notice()
16
+ {
17
+ if ( ! isset($_GET['mo-adaction']) || $_GET['mo-adaction'] != 'mo_dismiss_adnotice') {
18
  return;
19
  }
20
 
21
  $url = admin_url();
22
+ update_option('mo_dismiss_adnotice', 'true');
23
 
24
+ wp_redirect($url);
25
  exit;
26
  }
27
 
28
+ public function admin_notice()
29
+ {
30
 
31
  global $pagenow;
32
 
33
+ if ($pagenow != 'index.php') return;
34
 
35
+ if (get_option('mo_dismiss_adnotice', 'false') == 'true') {
36
  return;
37
  }
38
 
39
+ if ($this->is_plugin_installed() && $this->is_plugin_active()) {
40
  return;
41
  }
42
 
50
  );
51
  $this->notice_css();
52
  $install_url = wp_nonce_url(
53
+ admin_url('update.php?action=install-plugin&plugin=mailoptin'),
54
  'install-plugin_mailoptin'
55
  );
56
 
57
+ $activate_url = wp_nonce_url(admin_url('plugins.php?action=activate&plugin=mailoptin%2Fmailoptin.php'), 'activate-plugin_mailoptin/mailoptin.php');
58
  ?>
59
  <div class="mo-admin-notice notice notice-success">
60
  <div class="mo-notice-first-half">
61
  <p>
62
  <?php
63
  printf(
64
+ __('Free optin form plugin that will %1$sincrease your email list subscribers%2$s and keep them engaged with %1$sautomated and schedule newsletters%2$s.', 'peters-login-redirect'),
65
  '<span class="mo-stylize"><strong>', '</strong></span>');
66
  ?>
67
  </p>
68
+ <p style="text-decoration: underline;font-size: 12px;">Recommended by "LoginWP (Peter's Login Redirect)" plugin</p>
69
  </div>
70
  <div class="mo-notice-other-half">
71
  <?php if ( ! $this->is_plugin_installed()) : ?>
72
  <a class="button button-primary button-hero" id="mo-install-mailoptin-plugin" href="<?php echo $install_url; ?>">
73
+ <?php _e('Install MailOptin Now for Free!', 'peters-login-redirect'); ?>
74
  </a>
75
  <?php endif; ?>
76
  <?php if ($this->is_plugin_installed() && ! $this->is_plugin_active()) : ?>
77
  <a class="button button-primary button-hero" id="mo-activate-mailoptin-plugin" href="<?php echo $activate_url; ?>">
78
+ <?php _e('Activate MailOptin Now!', 'peters-login-redirect'); ?>
79
  </a>
80
  <?php endif; ?>
81
  <div class="mo-notice-learn-more">
82
+ <a target="_blank" href="https://mailoptin.io/">Learn more</a>
83
  </div>
84
  </div>
85
  <a href="<?php echo $dismiss_url; ?>">
86
  <button type="button" class="notice-dismiss">
87
+ <span class="screen-reader-text"><?php _e('Dismiss this notice', 'peters-login-redirect'); ?>.</span>
88
  </button>
89
  </a>
90
  </div>
91
  <?php
92
  }
93
 
94
+ public function current_admin_url()
95
+ {
96
+ $parts = parse_url(home_url());
97
  $uri = $parts['scheme'] . '://' . $parts['host'];
98
 
99
+ if (array_key_exists('port', $parts)) {
100
  $uri .= ':' . $parts['port'];
101
  }
102
 
103
+ $uri .= add_query_arg(array());
104
 
105
  return $uri;
106
  }
107
 
108
+ public function is_plugin_installed()
109
+ {
110
  $installed_plugins = get_plugins();
111
 
112
+ return isset($installed_plugins['mailoptin/mailoptin.php']);
113
  }
114
 
115
+ public function is_plugin_active()
116
+ {
117
+ return is_plugin_active('mailoptin/mailoptin.php');
118
  }
119
 
120
+ public function notice_css()
121
+ {
122
  ?>
123
  <style type="text/css">
124
  .mo-admin-notice {
172
  <?php
173
  }
174
 
175
+ public static function instance()
176
+ {
177
  static $instance = null;
178
 
179
+ if (is_null($instance)) {
180
  $instance = new self();
181
  }
182
 
src/core/src/Redirections/Redirections.php ADDED
@@ -0,0 +1,106 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace LoginWP\Core\Redirections;
4
+
5
+ use LoginWP\Core\Helpers;
6
+
7
+ class Redirections
8
+ {
9
+ public function __construct()
10
+ {
11
+ add_filter('login_redirect', [__CLASS__, 'login_redirect_callback'], 999999999, 3);
12
+ add_filter('registration_redirect', [__CLASS__, 'registration_redirect_callback'], 10, 2);
13
+ add_filter('logout_redirect', [__CLASS__, 'logout_redirect'], 999999999, 3);
14
+ }
15
+
16
+ public static function login_redirect_callback($redirect_to, $requested_redirect_to, $user)
17
+ {
18
+ $post_redirect_to_override = Helpers::redirectFunctionCollection_get_settings('rul_allow_post_redirect_override');
19
+
20
+ if ( ! isset($user->user_login)) return $redirect_to;
21
+
22
+ $requested_redirect_to = ! empty($requested_redirect_to) ? $requested_redirect_to : loginwp_var($_REQUEST, 'redirect_to', '');
23
+ $requested_redirect_to = wp_validate_redirect($requested_redirect_to);
24
+
25
+ if ('1' == $post_redirect_to_override && ! empty($requested_redirect_to) && $requested_redirect_to != admin_url()) {
26
+
27
+ do_action('loginwp_after_login_redirect', $requested_redirect_to, $user);
28
+
29
+ return $requested_redirect_to;
30
+ }
31
+
32
+ $rul_url = Helpers::login_redirect_logic_callback($redirect_to, $requested_redirect_to, $user);
33
+
34
+ if ( ! empty($rul_url)) {
35
+
36
+ Helpers::rul_trigger_allowed_host($rul_url);
37
+
38
+ do_action('loginwp_after_login_redirect', $rul_url, $user);
39
+
40
+ return $rul_url;
41
+ }
42
+
43
+ do_action('loginwp_after_login_redirect', $redirect_to, $user);
44
+
45
+ return $redirect_to;
46
+ }
47
+
48
+ public static function registration_redirect_callback($registration_redirect)
49
+ {
50
+ /*
51
+ Some limitations:
52
+ - Not yet possible: Username-customized page, since the WordPress hook is implemented pre-registration, not post-registration
53
+ */
54
+ $requested_redirect_to = ! empty($_REQUEST['redirect_to']) ? $_REQUEST['redirect_to'] : '';
55
+
56
+ if ( ! empty($requested_redirect_to)) return wp_validate_redirect($requested_redirect_to);
57
+
58
+ global $wpdb;
59
+
60
+ $rul_url = $wpdb->get_var('SELECT rul_url FROM ' . PTR_LOGINWP_DB_TABLE . ' WHERE rul_type = \'register\' LIMIT 1');
61
+
62
+ if ( ! empty($rul_url)) {
63
+
64
+ $rul_url = Helpers::rul_replace_variable($rul_url, false);
65
+
66
+ Helpers::rul_trigger_allowed_host($rul_url);
67
+
68
+ return $rul_url;
69
+ }
70
+
71
+ return $registration_redirect;
72
+ }
73
+
74
+ public static function logout_redirect($redirect_to, $requested_redirect_to, $current_user)
75
+ {
76
+ $post_redirect_override_logout = Helpers::redirectFunctionCollection_get_settings('rul_allow_post_redirect_override_logout');
77
+
78
+ $requested_redirect_to = ! empty($requested_redirect_to) ? $requested_redirect_to : loginwp_var($_REQUEST, 'redirect_to', '');
79
+
80
+ if ('1' == $post_redirect_override_logout && ! empty($requested_redirect_to)) {
81
+ return $requested_redirect_to;
82
+ }
83
+
84
+ $rul_url = Helpers::logout_redirect_logic_callback($current_user, $requested_redirect_to);
85
+
86
+ if ( ! empty($rul_url)) {
87
+
88
+ Helpers::rul_trigger_allowed_host($rul_url);
89
+
90
+ return $rul_url;
91
+ }
92
+
93
+ return $redirect_to;
94
+ }
95
+
96
+ public static function get_instance()
97
+ {
98
+ static $instance = null;
99
+
100
+ if (is_null($instance)) {
101
+ $instance = new self();
102
+ }
103
+
104
+ return $instance;
105
+ }
106
+ }
src/core/src/Redirections/index.php ADDED
File without changes
src/core/src/index.php ADDED
File without changes
uninstall.php ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ //if uninstall not called from WordPress exit
4
+ if ( ! defined('WP_UNINSTALL_PLUGIN')) {
5
+ exit();
6
+ }
7
+
8
+ include_once(dirname(__FILE__) . '/wplogin_redirect.php');
9
+
10
+ function loginwp_mo_uninstall_function()
11
+ {
12
+ $remove_plugin_data = loginwp_var(get_option('loginwp_settings', []), 'remove_plugin_data');
13
+
14
+ if ($remove_plugin_data == 'true') {
15
+
16
+ global $wpdb;
17
+
18
+ $drop_tables[] = "DROP TABLE IF EXISTS " . PTR_LOGINWP_DB_TABLE;
19
+
20
+ foreach ($drop_tables as $tables) {
21
+ $wpdb->query($tables);
22
+ }
23
+
24
+ delete_option('rul_version');
25
+ delete_option('rul_settings');
26
+ delete_option('loginwp_from_ab_initio');
27
+ delete_option('loginwp_install_date');
28
+ delete_option('loginwp_redirection_settings');
29
+ delete_option('loginwp_settings');
30
+
31
+ delete_option('loginwp_license_status');
32
+ delete_option('loginwp_license_expired_status');
33
+ delete_option('loginwp_license_key');
34
+
35
+ delete_site_option('pand-' . md5('loginwp-review-plugin-notice'));
36
+ delete_site_option('pand-' . md5('ptlr_is_now_loginwp_notice'));
37
+
38
+ wp_cache_flush();
39
+ }
40
+ }
41
+
42
+ if ( ! is_multisite()) {
43
+ loginwp_mo_uninstall_function();
44
+ } else {
45
+
46
+ if ( ! wp_is_large_network()) {
47
+ $site_ids = get_sites(['fields' => 'ids', 'number' => 0]);
48
+
49
+ foreach ($site_ids as $site_id) {
50
+ switch_to_blog($site_id);
51
+ loginwp_mo_uninstall_function();
52
+ restore_current_blog();
53
+ }
54
+ }
55
+ }
vendor/autoload.php ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // autoload.php @generated by Composer
4
+
5
+ require_once __DIR__ . '/composer/autoload_real.php';
6
+
7
+ return ComposerAutoloaderInitd2e8977aa883062bbd1dd5840dd615c3::getLoader();
vendor/collizo4sky/persist-admin-notices-dismissal/CHANGES.md ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ #### 1.4.4
2
+ * Added support for extra dismissible links via `.dismiss-this` CSS class.
3
+
4
+ #### 1.4.3
5
+ * Added filter hook `pand_dismiss_notice_js_url` in case you're using this in a theme or a local environment that doesn't quite find the correct URL.
6
+ * Added filter hook `pand_theme_loader` that returns a boolean for simpler usage of the `pand_dismiss_notice_js_url` hook
7
+
8
+ #### 1.4.2
9
+ * No changes to `class PAnD`
10
+ * Updated `.gitignore` and `.gitattributes`
11
+ * Now use classmap in composer's autoloader, should be more efficient
12
+
13
+ #### 1.4.1
14
+ * Fixed the `forever` setting with options
15
+
16
+ #### 1.4.0
17
+ * WPCS 1.1.0 linting done
18
+ * Switched from storing timeout in transients to storing in the options table, this should play much better with object caching
19
+
20
+ #### 1.3.x
21
+ * Uses transients to store timeout
vendor/collizo4sky/persist-admin-notices-dismissal/README.md ADDED
@@ -0,0 +1,128 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Persist Admin notice Dismissals
2
+ [![Latest Stable Version](https://poser.pugx.org/collizo4sky/persist-admin-notices-dismissal/v/stable)](https://packagist.org/packages/collizo4sky/persist-admin-notices-dismissal)
3
+ [![Total Downloads](https://poser.pugx.org/collizo4sky/persist-admin-notices-dismissal/downloads)](https://packagist.org/packages/collizo4sky/persist-admin-notices-dismissal)
4
+
5
+ Simple framework library that persists the dismissal of admin notices across pages in WordPress dashboard.
6
+
7
+ ## Installation
8
+
9
+ Run `composer require collizo4sky/persist-admin-notices-dismissal`
10
+
11
+ Alternatively, clone or download this repo into the `vendor/` folder in your plugin, and include/require the `persist-admin-notices-dismissal.php` file like so
12
+
13
+ ```php
14
+ require __DIR__ . '/vendor/persist-admin-notices-dismissal/persist-admin-notices-dismissal.php';
15
+ add_action( 'admin_init', array( 'PAnD', 'init' ) );
16
+ ```
17
+
18
+ or let Composer's autoloader do the work.
19
+
20
+ ## How to Use
21
+ Firstly, install and activate this library within a plugin.
22
+
23
+ Say you have the following markup as your admin notice,
24
+
25
+
26
+ ```php
27
+ function sample_admin_notice__success() {
28
+ ?>
29
+ <div class="updated notice notice-success is-dismissible">
30
+ <p><?php _e( 'Done!', 'sample-text-domain' ); ?></p>
31
+ </div>
32
+ <?php
33
+ }
34
+ add_action( 'admin_notices', 'sample_admin_notice__success' );
35
+ ```
36
+
37
+ To make it hidden forever when dismissed, add the following data attribute `data-dismissible="disable-done-notice-forever"` to the div markup like so:
38
+
39
+
40
+ ```php
41
+ function sample_admin_notice__success() {
42
+ if ( ! PAnD::is_admin_notice_active( 'disable-done-notice-forever' ) ) {
43
+ return;
44
+ }
45
+
46
+ ?>
47
+ <div data-dismissible="disable-done-notice-forever" class="updated notice notice-success is-dismissible">
48
+ <p><?php _e( 'Done!', 'sample-text-domain' ); ?></p>
49
+ </div>
50
+ <?php
51
+ }
52
+ add_action( 'admin_init', array( 'PAnD', 'init' ) );
53
+ add_action( 'admin_notices', 'sample_admin_notice__success' );
54
+ ```
55
+
56
+ ## Autoloaders
57
+ When using the framework with an autoloader you **must** also load the class outside of the `admin_notices` or `network_admin_notices` hooks. The reason is that these hooks come after the `admin_enqueue_script` hook that loads the javascript.
58
+
59
+ Just add the following in your main plugin file.
60
+
61
+ ```php
62
+ add_action( 'admin_init', array( 'PAnD', 'init' ) );
63
+ ```
64
+
65
+ #### Usage Instructions and Examples
66
+ If you have two notices displayed when certain actions are triggered; firstly, choose a string to uniquely identify them, e.g. `notice-one` and `notice-two`
67
+
68
+ To make the first notice never appear once dismissed, its `data-dismissible` attribute will be `data-dismissible="notice-one-forever"` where `notice-one` is its unique identifier and `forever` is the dismissal time period.
69
+
70
+ To make the second notice only hidden for 2 days, its `data-dismissible` attribute will be `data-dismissible="notice-two-2"` where `notice-two` is its unique identifier and the `2`, the number of days it will be hidden is the dismissal time period.
71
+
72
+ You **must** append the dismissal time period to the end of your unique identifier with a hyphen (`-`) and this value must be an integer. The only exception is the string `forever`.
73
+
74
+ To actually make the dismissed admin notice not to appear, use the `is_admin_notice_active()` function like so:
75
+
76
+
77
+ ```php
78
+ function sample_admin_notice__success1() {
79
+ if ( ! PAnD::is_admin_notice_active( 'notice-one-forever' ) ) {
80
+ return;
81
+ }
82
+
83
+ ?>
84
+ <div data-dismissible="notice-one-forever" class="updated notice notice-success is-dismissible">
85
+ <p><?php _e( 'Done 1!', 'sample-text-domain' ); ?></p>
86
+ </div>
87
+ <?php
88
+ }
89
+
90
+ function sample_admin_notice__success2() {
91
+ if ( ! PAnD::is_admin_notice_active( 'notice-two-2' ) ) {
92
+ return;
93
+ }
94
+
95
+ ?>
96
+ <div data-dismissible="notice-two-2" class="updated notice notice-success is-dismissible">
97
+ <p><?php _e( 'Done 2!', 'sample-text-domain' ); ?></p>
98
+ </div>
99
+ <?php
100
+ }
101
+
102
+ add_action( 'admin_init', array( 'PAnD', 'init' ) );
103
+ add_action( 'admin_notices', 'sample_admin_notice__success1' );
104
+ add_action( 'admin_notices', 'sample_admin_notice__success2' );
105
+ ```
106
+
107
+ Please note that if you cleanup after your plugin deletion please try to make the removal of stored options as specific as possible. Otherwise you may end up deleting the stored options from other projects.
108
+
109
+ A filter hook is available to return the proper URL to the Javascript file. An example usage is as follows, especially if this is being used in a theme.
110
+
111
+ ```php
112
+ add_filter( 'pand_theme_loader', '__return_true' );
113
+ ```
114
+
115
+ The `pand_theme_loader` runs the following hook if `true`. You can directly change the URL to the Javascript file by using another hook in the following manner by changing the return value.
116
+
117
+ ```php
118
+ add_filter(
119
+ 'pand_dismiss_notice_js_url',
120
+ function( $js_url, $composer_path ) {
121
+ return get_stylesheet_directory_uri() . $composer_path;
122
+ },
123
+ 10,
124
+ 2
125
+ );
126
+ ```
127
+
128
+ Cool beans. Isn't it?
vendor/collizo4sky/persist-admin-notices-dismissal/composer.json ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "collizo4sky/persist-admin-notices-dismissal",
3
+ "description": "Simple library to persist dismissal of admin notices across pages in WordPress dashboard.",
4
+ "version": "1.4.4",
5
+ "type": "library",
6
+ "license": "GPL-3.0-or-later",
7
+ "authors": [
8
+ {
9
+ "name": "Collins Agbonghama",
10
+ "email": "me@w3guy.com",
11
+ "role": "developer"
12
+ }
13
+ ],
14
+ "prefer-stable": true,
15
+ "require": {
16
+ "php": ">=5.4"
17
+ },
18
+ "support": {
19
+ "issues": "https://github.com/w3guy/persist-admin-notices-dismissal/issues",
20
+ "source": "https://github.com/w3guy/persist-admin-notices-dismissal"
21
+ },
22
+ "autoload": {
23
+ "classmap": [
24
+ "persist-admin-notices-dismissal.php"
25
+ ]
26
+ }
27
+ }
vendor/collizo4sky/persist-admin-notices-dismissal/dismiss-notice.js ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ (function ($) {
2
+ //shorthand for ready event.
3
+ $(
4
+ function () {
5
+ $( 'div[data-dismissible] button.notice-dismiss, div[data-dismissible] .dismiss-this' ).on("click",
6
+ function (event) {
7
+ event.preventDefault();
8
+ var $this = $( this );
9
+
10
+ var attr_value, option_name, dismissible_length, data;
11
+
12
+ attr_value = $this.closest("div[data-dismissible]").attr( 'data-dismissible' ).split( '-' );
13
+
14
+ // remove the dismissible length from the attribute value and rejoin the array.
15
+ dismissible_length = attr_value.pop();
16
+
17
+ option_name = attr_value.join( '-' );
18
+
19
+ data = {
20
+ 'action': 'dismiss_admin_notice',
21
+ 'option_name': option_name,
22
+ 'dismissible_length': dismissible_length,
23
+ 'nonce': dismissible_notice.nonce
24
+ };
25
+
26
+ // We can also pass the url value separately from ajaxurl for front end AJAX implementations
27
+ $.post( ajaxurl, data );
28
+ $this.closest("div[data-dismissible]").hide('slow');
29
+ }
30
+ );
31
+ }
32
+ )
33
+
34
+ }(jQuery));
vendor/collizo4sky/persist-admin-notices-dismissal/persist-admin-notices-dismissal.php ADDED
@@ -0,0 +1,189 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Persist Admin notices Dismissal
5
+ *
6
+ * Copyright (C) 2016 Collins Agbonghama <https://w3guy.com>
7
+ *
8
+ * This program is free software: you can redistribute it and/or modify
9
+ * it under the terms of the GNU General Public License as published by
10
+ * the Free Software Foundation, either version 3 of the License, or
11
+ * (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful,
14
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16
+ * GNU General Public License for more details.
17
+ *
18
+ * You should have received a copy of the GNU General Public License
19
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
20
+ *
21
+ * @package Persist Admin notices Dismissal
22
+ * @author Collins Agbonghama
23
+ * @author Andy Fragen
24
+ * @license http://www.gnu.org/licenses GNU General Public License
25
+ */
26
+
27
+ /**
28
+ * Exit if called directly.
29
+ */
30
+ if ( ! defined( 'ABSPATH' ) ) {
31
+ die;
32
+ }
33
+
34
+ if ( ! class_exists( 'PAnD' ) ) {
35
+
36
+ /**
37
+ * Class PAnD
38
+ */
39
+ class PAnD {
40
+
41
+ /**
42
+ * Init hooks.
43
+ */
44
+ public static function init() {
45
+ add_action( 'admin_enqueue_scripts', array( __CLASS__, 'load_script' ) );
46
+ add_action( 'wp_ajax_dismiss_admin_notice', array( __CLASS__, 'dismiss_admin_notice' ) );
47
+
48
+ /**
49
+ * Filter to activate another filter providing a simpler use case.
50
+ *
51
+ * @since 1.4.3
52
+ *
53
+ * @param bool
54
+ */
55
+ if ( apply_filters( 'pand_theme_loader', false ) ) {
56
+ add_filter(
57
+ 'pand_dismiss_notice_js_url',
58
+ function( $js_url, $composer_path ) {
59
+ return get_stylesheet_directory_uri() . $composer_path;
60
+ },
61
+ 10,
62
+ 2
63
+ );
64
+ }
65
+ }
66
+
67
+ /**
68
+ * Enqueue javascript and variables.
69
+ */
70
+ public static function load_script() {
71
+
72
+ if ( is_customize_preview() ) {
73
+ return;
74
+ }
75
+
76
+ $js_url = plugins_url( 'dismiss-notice.js', __FILE__ );
77
+ $composer_path = '/vendor/collizo4sky/persist-admin-notices-dismissal/dismiss-notice.js';
78
+
79
+ /**
80
+ * Filter dismiss-notice.js URL.
81
+ *
82
+ * @since 1.4.3
83
+ *
84
+ * @param string $js_url URL to the Javascript file.
85
+ * @param string $composer_path Relative path of Javascript file from composer install.
86
+ */
87
+ $js_url = apply_filters( 'pand_dismiss_notice_js_url', $js_url, $composer_path );
88
+ wp_enqueue_script(
89
+ 'dismissible-notices',
90
+ $js_url,
91
+ array( 'jquery', 'common' ),
92
+ false,
93
+ true
94
+ );
95
+
96
+ wp_localize_script(
97
+ 'dismissible-notices',
98
+ 'dismissible_notice',
99
+ array(
100
+ 'nonce' => wp_create_nonce( 'dismissible-notice' ),
101
+ )
102
+ );
103
+ }
104
+
105
+ /**
106
+ * Handles Ajax request to persist notices dismissal.
107
+ * Uses check_ajax_referer to verify nonce.
108
+ */
109
+ public static function dismiss_admin_notice() {
110
+ $option_name = sanitize_text_field( $_POST['option_name'] );
111
+ $dismissible_length = sanitize_text_field( $_POST['dismissible_length'] );
112
+
113
+ if ( 'forever' != $dismissible_length ) {
114
+ // If $dismissible_length is not an integer default to 1
115
+ $dismissible_length = ( 0 == absint( $dismissible_length ) ) ? 1 : $dismissible_length;
116
+ $dismissible_length = strtotime( absint( $dismissible_length ) . ' days' );
117
+ }
118
+
119
+ check_ajax_referer( 'dismissible-notice', 'nonce' );
120
+ self::set_admin_notice_cache( $option_name, $dismissible_length );
121
+ wp_die();
122
+ }
123
+
124
+ /**
125
+ * Is admin notice active?
126
+ *
127
+ * @param string $arg data-dismissible content of notice.
128
+ *
129
+ * @return bool
130
+ */
131
+ public static function is_admin_notice_active( $arg ) {
132
+ $array = explode( '-', $arg );
133
+ $length = array_pop( $array );
134
+ $option_name = implode( '-', $array );
135
+ $db_record = self::get_admin_notice_cache( $option_name );
136
+
137
+ if ( 'forever' == $db_record ) {
138
+ return false;
139
+ } elseif ( absint( $db_record ) >= time() ) {
140
+ return false;
141
+ } else {
142
+ return true;
143
+ }
144
+ }
145
+
146
+ /**
147
+ * Returns admin notice cached timeout.
148
+ *
149
+ * @access public
150
+ *
151
+ * @param string|bool $id admin notice name or false.
152
+ *
153
+ * @return array|bool The timeout. False if expired.
154
+ */
155
+ public static function get_admin_notice_cache( $id = false ) {
156
+ if ( ! $id ) {
157
+ return false;
158
+ }
159
+ $cache_key = 'pand-' . md5( $id );
160
+ $timeout = get_site_option( $cache_key );
161
+ $timeout = 'forever' === $timeout ? time() + 60 : $timeout;
162
+
163
+ if ( empty( $timeout ) || time() > $timeout ) {
164
+ return false;
165
+ }
166
+
167
+ return $timeout;
168
+ }
169
+
170
+ /**
171
+ * Sets admin notice timeout in site option.
172
+ *
173
+ * @access public
174
+ *
175
+ * @param string $id Data Identifier.
176
+ * @param string|bool $timeout Timeout for admin notice.
177
+ *
178
+ * @return bool
179
+ */
180
+ public static function set_admin_notice_cache( $id, $timeout ) {
181
+ $cache_key = 'pand-' . md5( $id );
182
+ update_site_option( $cache_key, $timeout );
183
+
184
+ return true;
185
+ }
186
+
187
+ }
188
+
189
+ }
vendor/composer/ClassLoader.php ADDED
@@ -0,0 +1,481 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /*
4
+ * This file is part of Composer.
5
+ *
6
+ * (c) Nils Adermann <naderman@naderman.de>
7
+ * Jordi Boggiano <j.boggiano@seld.be>
8
+ *
9
+ * For the full copyright and license information, please view the LICENSE
10
+ * file that was distributed with this source code.
11
+ */
12
+
13
+ namespace Composer\Autoload;
14
+
15
+ /**
16
+ * ClassLoader implements a PSR-0, PSR-4 and classmap class loader.
17
+ *
18
+ * $loader = new \Composer\Autoload\ClassLoader();
19
+ *
20
+ * // register classes with namespaces
21
+ * $loader->add('Symfony\Component', __DIR__.'/component');
22
+ * $loader->add('Symfony', __DIR__.'/framework');
23
+ *
24
+ * // activate the autoloader
25
+ * $loader->register();
26
+ *
27
+ * // to enable searching the include path (eg. for PEAR packages)
28
+ * $loader->setUseIncludePath(true);
29
+ *
30
+ * In this example, if you try to use a class in the Symfony\Component
31
+ * namespace or one of its children (Symfony\Component\Console for instance),
32
+ * the autoloader will first look for the class under the component/
33
+ * directory, and it will then fallback to the framework/ directory if not
34
+ * found before giving up.
35
+ *
36
+ * This class is loosely based on the Symfony UniversalClassLoader.
37
+ *
38
+ * @author Fabien Potencier <fabien@symfony.com>
39
+ * @author Jordi Boggiano <j.boggiano@seld.be>
40
+ * @see https://www.php-fig.org/psr/psr-0/
41
+ * @see https://www.php-fig.org/psr/psr-4/
42
+ */
43
+ class ClassLoader
44
+ {
45
+ private $vendorDir;
46
+
47
+ // PSR-4
48
+ private $prefixLengthsPsr4 = array();
49
+ private $prefixDirsPsr4 = array();
50
+ private $fallbackDirsPsr4 = array();
51
+
52
+ // PSR-0
53
+ private $prefixesPsr0 = array();
54
+ private $fallbackDirsPsr0 = array();
55
+
56
+ private $useIncludePath = false;
57
+ private $classMap = array();
58
+ private $classMapAuthoritative = false;
59
+ private $missingClasses = array();
60
+ private $apcuPrefix;
61
+
62
+ private static $registeredLoaders = array();
63
+
64
+ public function __construct($vendorDir = null)
65
+ {
66
+ $this->vendorDir = $vendorDir;
67
+ }
68
+
69
+ public function getPrefixes()
70
+ {
71
+ if (!empty($this->prefixesPsr0)) {
72
+ return call_user_func_array('array_merge', array_values($this->prefixesPsr0));
73
+ }
74
+
75
+ return array();
76
+ }
77
+
78
+ public function getPrefixesPsr4()
79
+ {
80
+ return $this->prefixDirsPsr4;
81
+ }
82
+
83
+ public function getFallbackDirs()
84
+ {
85
+ return $this->fallbackDirsPsr0;
86
+ }
87
+
88
+ public function getFallbackDirsPsr4()
89
+ {
90
+ return $this->fallbackDirsPsr4;
91
+ }
92
+
93
+ public function getClassMap()
94
+ {
95
+ return $this->classMap;
96
+ }
97
+
98
+ /**
99
+ * @param array $classMap Class to filename map
100
+ */
101
+ public function addClassMap(array $classMap)
102
+ {
103
+ if ($this->classMap) {
104
+ $this->classMap = array_merge($this->classMap, $classMap);
105
+ } else {
106
+ $this->classMap = $classMap;
107
+ }
108
+ }
109
+
110
+ /**
111
+ * Registers a set of PSR-0 directories for a given prefix, either
112
+ * appending or prepending to the ones previously set for this prefix.
113
+ *
114
+ * @param string $prefix The prefix
115
+ * @param array|string $paths The PSR-0 root directories
116
+ * @param bool $prepend Whether to prepend the directories
117
+ */
118
+ public function add($prefix, $paths, $prepend = false)
119
+ {
120
+ if (!$prefix) {
121
+ if ($prepend) {
122
+ $this->fallbackDirsPsr0 = array_merge(
123
+ (array) $paths,
124
+ $this->fallbackDirsPsr0
125
+ );
126
+ } else {
127
+ $this->fallbackDirsPsr0 = array_merge(
128
+ $this->fallbackDirsPsr0,
129
+ (array) $paths
130
+ );
131
+ }
132
+
133
+ return;
134
+ }
135
+
136
+ $first = $prefix[0];
137
+ if (!isset($this->prefixesPsr0[$first][$prefix])) {
138
+ $this->prefixesPsr0[$first][$prefix] = (array) $paths;
139
+
140
+ return;
141
+ }
142
+ if ($prepend) {
143
+ $this->prefixesPsr0[$first][$prefix] = array_merge(
144
+ (array) $paths,
145
+ $this->prefixesPsr0[$first][$prefix]
146
+ );
147
+ } else {
148
+ $this->prefixesPsr0[$first][$prefix] = array_merge(
149
+ $this->prefixesPsr0[$first][$prefix],
150
+ (array) $paths
151
+ );
152
+ }
153
+ }
154
+
155
+ /**
156
+ * Registers a set of PSR-4 directories for a given namespace, either
157
+ * appending or prepending to the ones previously set for this namespace.
158
+ *
159
+ * @param string $prefix The prefix/namespace, with trailing '\\'
160
+ * @param array|string $paths The PSR-4 base directories
161
+ * @param bool $prepend Whether to prepend the directories
162
+ *
163
+ * @throws \InvalidArgumentException
164
+ */
165
+ public function addPsr4($prefix, $paths, $prepend = false)
166
+ {
167
+ if (!$prefix) {
168
+ // Register directories for the root namespace.
169
+ if ($prepend) {
170
+ $this->fallbackDirsPsr4 = array_merge(
171
+ (array) $paths,
172
+ $this->fallbackDirsPsr4
173
+ );
174
+ } else {
175
+ $this->fallbackDirsPsr4 = array_merge(
176
+ $this->fallbackDirsPsr4,
177
+ (array) $paths
178
+ );
179
+ }
180
+ } elseif (!isset($this->prefixDirsPsr4[$prefix])) {
181
+ // Register directories for a new namespace.
182
+ $length = strlen($prefix);
183
+ if ('\\' !== $prefix[$length - 1]) {
184
+ throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator.");
185
+ }
186
+ $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length;
187
+ $this->prefixDirsPsr4[$prefix] = (array) $paths;
188
+ } elseif ($prepend) {
189
+ // Prepend directories for an already registered namespace.
190
+ $this->prefixDirsPsr4[$prefix] = array_merge(
191
+ (array) $paths,
192
+ $this->prefixDirsPsr4[$prefix]
193
+ );
194
+ } else {
195
+ // Append directories for an already registered namespace.
196
+ $this->prefixDirsPsr4[$prefix] = array_merge(
197
+ $this->prefixDirsPsr4[$prefix],
198
+ (array) $paths
199
+ );
200
+ }
201
+ }
202
+
203
+ /**
204
+ * Registers a set of PSR-0 directories for a given prefix,
205
+ * replacing any others previously set for this prefix.
206
+ *
207
+ * @param string $prefix The prefix
208
+ * @param array|string $paths The PSR-0 base directories
209
+ */
210
+ public function set($prefix, $paths)
211
+ {
212
+ if (!$prefix) {
213
+ $this->fallbackDirsPsr0 = (array) $paths;
214
+ } else {
215
+ $this->prefixesPsr0[$prefix[0]][$prefix] = (array) $paths;
216
+ }
217
+ }
218
+
219
+ /**
220
+ * Registers a set of PSR-4 directories for a given namespace,
221
+ * replacing any others previously set for this namespace.
222
+ *
223
+ * @param string $prefix The prefix/namespace, with trailing '\\'
224
+ * @param array|string $paths The PSR-4 base directories
225
+ *
226
+ * @throws \InvalidArgumentException
227
+ */
228
+ public function setPsr4($prefix, $paths)
229
+ {
230
+ if (!$prefix) {
231
+ $this->fallbackDirsPsr4 = (array) $paths;
232
+ } else {
233
+ $length = strlen($prefix);
234
+ if ('\\' !== $prefix[$length - 1]) {
235
+ throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator.");
236
+ }
237
+ $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length;
238
+ $this->prefixDirsPsr4[$prefix] = (array) $paths;
239
+ }
240
+ }
241
+
242
+ /**
243
+ * Turns on searching the include path for class files.
244
+ *
245
+ * @param bool $useIncludePath
246
+ */
247
+ public function setUseIncludePath($useIncludePath)
248
+ {
249
+ $this->useIncludePath = $useIncludePath;
250
+ }
251
+
252
+ /**
253
+ * Can be used to check if the autoloader uses the include path to check
254
+ * for classes.
255
+ *
256
+ * @return bool
257
+ */
258
+ public function getUseIncludePath()
259
+ {
260
+ return $this->useIncludePath;
261
+ }
262
+
263
+ /**
264
+ * Turns off searching the prefix and fallback directories for classes
265
+ * that have not been registered with the class map.
266
+ *
267
+ * @param bool $classMapAuthoritative
268
+ */
269
+ public function setClassMapAuthoritative($classMapAuthoritative)
270
+ {
271
+ $this->classMapAuthoritative = $classMapAuthoritative;
272
+ }
273
+
274
+ /**
275
+ * Should class lookup fail if not found in the current class map?
276
+ *
277
+ * @return bool
278
+ */
279
+ public function isClassMapAuthoritative()
280
+ {
281
+ return $this->classMapAuthoritative;
282
+ }
283
+
284
+ /**
285
+ * APCu prefix to use to cache found/not-found classes, if the extension is enabled.
286
+ *
287
+ * @param string|null $apcuPrefix
288
+ */
289
+ public function setApcuPrefix($apcuPrefix)
290
+ {
291
+ $this->apcuPrefix = function_exists('apcu_fetch') && filter_var(ini_get('apc.enabled'), FILTER_VALIDATE_BOOLEAN) ? $apcuPrefix : null;
292
+ }
293
+
294
+ /**
295
+ * The APCu prefix in use, or null if APCu caching is not enabled.
296
+ *
297
+ * @return string|null
298
+ */
299
+ public function getApcuPrefix()
300
+ {
301
+ return $this->apcuPrefix;
302
+ }
303
+
304
+ /**
305
+ * Registers this instance as an autoloader.
306
+ *
307
+ * @param bool $prepend Whether to prepend the autoloader or not
308
+ */
309
+ public function register($prepend = false)
310
+ {
311
+ spl_autoload_register(array($this, 'loadClass'), true, $prepend);
312
+
313
+ if (null === $this->vendorDir) {
314
+ return;
315
+ }
316
+
317
+ if ($prepend) {
318
+ self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
319
+ } else {
320
+ unset(self::$registeredLoaders[$this->vendorDir]);
321
+ self::$registeredLoaders[$this->vendorDir] = $this;
322
+ }
323
+ }
324
+
325
+ /**
326
+ * Unregisters this instance as an autoloader.
327
+ */
328
+ public function unregister()
329
+ {
330
+ spl_autoload_unregister(array($this, 'loadClass'));
331
+
332
+ if (null !== $this->vendorDir) {
333
+ unset(self::$registeredLoaders[$this->vendorDir]);
334
+ }
335
+ }
336
+
337
+ /**
338
+ * Loads the given class or interface.
339
+ *
340
+ * @param string $class The name of the class
341
+ * @return true|null True if loaded, null otherwise
342
+ */
343
+ public function loadClass($class)
344
+ {
345
+ if ($file = $this->findFile($class)) {
346
+ includeFile($file);
347
+
348
+ return true;
349
+ }
350
+
351
+ return null;
352
+ }
353
+
354
+ /**
355
+ * Finds the path to the file where the class is defined.
356
+ *
357
+ * @param string $class The name of the class
358
+ *
359
+ * @return string|false The path if found, false otherwise
360
+ */
361
+ public function findFile($class)
362
+ {
363
+ // class map lookup
364
+ if (isset($this->classMap[$class])) {
365
+ return $this->classMap[$class];
366
+ }
367
+ if ($this->classMapAuthoritative || isset($this->missingClasses[$class])) {
368
+ return false;
369
+ }
370
+ if (null !== $this->apcuPrefix) {
371
+ $file = apcu_fetch($this->apcuPrefix.$class, $hit);
372
+ if ($hit) {
373
+ return $file;
374
+ }
375
+ }
376
+
377
+ $file = $this->findFileWithExtension($class, '.php');
378
+
379
+ // Search for Hack files if we are running on HHVM
380
+ if (false === $file && defined('HHVM_VERSION')) {
381
+ $file = $this->findFileWithExtension($class, '.hh');
382
+ }
383
+
384
+ if (null !== $this->apcuPrefix) {
385
+ apcu_add($this->apcuPrefix.$class, $file);
386
+ }
387
+
388
+ if (false === $file) {
389
+ // Remember that this class does not exist.
390
+ $this->missingClasses[$class] = true;
391
+ }
392
+
393
+ return $file;
394
+ }
395
+
396
+ /**
397
+ * Returns the currently registered loaders indexed by their corresponding vendor directories.
398
+ *
399
+ * @return self[]
400
+ */
401
+ public static function getRegisteredLoaders()
402
+ {
403
+ return self::$registeredLoaders;
404
+ }
405
+
406
+ private function findFileWithExtension($class, $ext)
407
+ {
408
+ // PSR-4 lookup
409
+ $logicalPathPsr4 = strtr($class, '\\', DIRECTORY_SEPARATOR) . $ext;
410
+
411
+ $first = $class[0];
412
+ if (isset($this->prefixLengthsPsr4[$first])) {
413
+ $subPath = $class;
414
+ while (false !== $lastPos = strrpos($subPath, '\\')) {
415
+ $subPath = substr($subPath, 0, $lastPos);
416
+ $search = $subPath . '\\';
417
+ if (isset($this->prefixDirsPsr4[$search])) {
418
+ $pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1);
419
+ foreach ($this->prefixDirsPsr4[$search] as $dir) {
420
+ if (file_exists($file = $dir . $pathEnd)) {
421
+ return $file;
422
+ }
423
+ }
424
+ }
425
+ }
426
+ }
427
+
428
+ // PSR-4 fallback dirs
429
+ foreach ($this->fallbackDirsPsr4 as $dir) {
430
+ if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr4)) {
431
+ return $file;
432
+ }
433
+ }
434
+
435
+ // PSR-0 lookup
436
+ if (false !== $pos = strrpos($class, '\\')) {
437
+ // namespaced class name
438
+ $logicalPathPsr0 = substr($logicalPathPsr4, 0, $pos + 1)
439
+ . strtr(substr($logicalPathPsr4, $pos + 1), '_', DIRECTORY_SEPARATOR);
440
+ } else {
441
+ // PEAR-like class name
442
+ $logicalPathPsr0 = strtr($class, '_', DIRECTORY_SEPARATOR) . $ext;
443
+ }
444
+
445
+ if (isset($this->prefixesPsr0[$first])) {
446
+ foreach ($this->prefixesPsr0[$first] as $prefix => $dirs) {
447
+ if (0 === strpos($class, $prefix)) {
448
+ foreach ($dirs as $dir) {
449
+ if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) {
450
+ return $file;
451
+ }
452
+ }
453
+ }
454
+ }
455
+ }
456
+
457
+ // PSR-0 fallback dirs
458
+ foreach ($this->fallbackDirsPsr0 as $dir) {
459
+ if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) {
460
+ return $file;
461
+ }
462
+ }
463
+
464
+ // PSR-0 include paths.
465
+ if ($this->useIncludePath && $file = stream_resolve_include_path($logicalPathPsr0)) {
466
+ return $file;
467
+ }
468
+
469
+ return false;
470
+ }
471
+ }
472
+
473
+ /**
474
+ * Scope isolated include.
475
+ *
476
+ * Prevents access to $this/self from included files.
477
+ */
478
+ function includeFile($file)
479
+ {
480
+ include $file;
481
+ }
vendor/composer/InstalledVersions.php ADDED
@@ -0,0 +1,337 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /*
4
+ * This file is part of Composer.
5
+ *
6
+ * (c) Nils Adermann <naderman@naderman.de>
7
+ * Jordi Boggiano <j.boggiano@seld.be>
8
+ *
9
+ * For the full copyright and license information, please view the LICENSE
10
+ * file that was distributed with this source code.
11
+ */
12
+
13
+ namespace Composer;
14
+
15
+ use Composer\Autoload\ClassLoader;
16
+ use Composer\Semver\VersionParser;
17
+
18
+ /**
19
+ * This class is copied in every Composer installed project and available to all
20
+ *
21
+ * See also https://getcomposer.org/doc/07-runtime.md#installed-versions
22
+ *
23
+ * To require it's presence, you can require `composer-runtime-api ^2.0`
24
+ */
25
+ class InstalledVersions
26
+ {
27
+ private static $installed;
28
+ private static $canGetVendors;
29
+ private static $installedByVendor = array();
30
+
31
+ /**
32
+ * Returns a list of all package names which are present, either by being installed, replaced or provided
33
+ *
34
+ * @return string[]
35
+ * @psalm-return list<string>
36
+ */
37
+ public static function getInstalledPackages()
38
+ {
39
+ $packages = array();
40
+ foreach (self::getInstalled() as $installed) {
41
+ $packages[] = array_keys($installed['versions']);
42
+ }
43
+
44
+ if (1 === \count($packages)) {
45
+ return $packages[0];
46
+ }
47
+
48
+ return array_keys(array_flip(\call_user_func_array('array_merge', $packages)));
49
+ }
50
+
51
+ /**
52
+ * Returns a list of all package names with a specific type e.g. 'library'
53
+ *
54
+ * @param string $type
55
+ * @return string[]
56
+ * @psalm-return list<string>
57
+ */
58
+ public static function getInstalledPackagesByType($type)
59
+ {
60
+ $packagesByType = array();
61
+
62
+ foreach (self::getInstalled() as $installed) {
63
+ foreach ($installed['versions'] as $name => $package) {
64
+ if (isset($package['type']) && $package['type'] === $type) {
65
+ $packagesByType[] = $name;
66
+ }
67
+ }
68
+ }
69
+
70
+ return $packagesByType;
71
+ }
72
+
73
+ /**
74
+ * Checks whether the given package is installed
75
+ *
76
+ * This also returns true if the package name is provided or replaced by another package
77
+ *
78
+ * @param string $packageName
79
+ * @param bool $includeDevRequirements
80
+ * @return bool
81
+ */
82
+ public static function isInstalled($packageName, $includeDevRequirements = true)
83
+ {
84
+ foreach (self::getInstalled() as $installed) {
85
+ if (isset($installed['versions'][$packageName])) {
86
+ return $includeDevRequirements || empty($installed['versions'][$packageName]['dev_requirement']);
87
+ }
88
+ }
89
+
90
+ return false;
91
+ }
92
+
93
+ /**
94
+ * Checks whether the given package satisfies a version constraint
95
+ *
96
+ * e.g. If you want to know whether version 2.3+ of package foo/bar is installed, you would call:
97
+ *
98
+ * Composer\InstalledVersions::satisfies(new VersionParser, 'foo/bar', '^2.3')
99
+ *
100
+ * @param VersionParser $parser Install composer/semver to have access to this class and functionality
101
+ * @param string $packageName
102
+ * @param string|null $constraint A version constraint to check for, if you pass one you have to make sure composer/semver is required by your package
103
+ * @return bool
104
+ */
105
+ public static function satisfies(VersionParser $parser, $packageName, $constraint)
106
+ {
107
+ $constraint = $parser->parseConstraints($constraint);
108
+ $provided = $parser->parseConstraints(self::getVersionRanges($packageName));
109
+
110
+ return $provided->matches($constraint);
111
+ }
112
+
113
+ /**
114
+ * Returns a version constraint representing all the range(s) which are installed for a given package
115
+ *
116
+ * It is easier to use this via isInstalled() with the $constraint argument if you need to check
117
+ * whether a given version of a package is installed, and not just whether it exists
118
+ *
119
+ * @param string $packageName
120
+ * @return string Version constraint usable with composer/semver
121
+ */
122
+ public static function getVersionRanges($packageName)
123
+ {
124
+ foreach (self::getInstalled() as $installed) {
125
+ if (!isset($installed['versions'][$packageName])) {
126
+ continue;
127
+ }
128
+
129
+ $ranges = array();
130
+ if (isset($installed['versions'][$packageName]['pretty_version'])) {
131
+ $ranges[] = $installed['versions'][$packageName]['pretty_version'];
132
+ }
133
+ if (array_key_exists('aliases', $installed['versions'][$packageName])) {
134
+ $ranges = array_merge($ranges, $installed['versions'][$packageName]['aliases']);
135
+ }
136
+ if (array_key_exists('replaced', $installed['versions'][$packageName])) {
137
+ $ranges = array_merge($ranges, $installed['versions'][$packageName]['replaced']);
138
+ }
139
+ if (array_key_exists('provided', $installed['versions'][$packageName])) {
140
+ $ranges = array_merge($ranges, $installed['versions'][$packageName]['provided']);
141
+ }
142
+
143
+ return implode(' || ', $ranges);
144
+ }
145
+
146
+ throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
147
+ }
148
+
149
+ /**
150
+ * @param string $packageName
151
+ * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as version, use satisfies or getVersionRanges if you need to know if a given version is present
152
+ */
153
+ public static function getVersion($packageName)
154
+ {
155
+ foreach (self::getInstalled() as $installed) {
156
+ if (!isset($installed['versions'][$packageName])) {
157
+ continue;
158
+ }
159
+
160
+ if (!isset($installed['versions'][$packageName]['version'])) {
161
+ return null;
162
+ }
163
+
164
+ return $installed['versions'][$packageName]['version'];
165
+ }
166
+
167
+ throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
168
+ }
169
+
170
+ /**
171
+ * @param string $packageName
172
+ * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as version, use satisfies or getVersionRanges if you need to know if a given version is present
173
+ */
174
+ public static function getPrettyVersion($packageName)
175
+ {
176
+ foreach (self::getInstalled() as $installed) {
177
+ if (!isset($installed['versions'][$packageName])) {
178
+ continue;
179
+ }
180
+
181
+ if (!isset($installed['versions'][$packageName]['pretty_version'])) {
182
+ return null;
183
+ }
184
+
185
+ return $installed['versions'][$packageName]['pretty_version'];
186
+ }
187
+
188
+ throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
189
+ }
190
+
191
+ /**
192
+ * @param string $packageName
193
+ * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as reference
194
+ */
195
+ public static function getReference($packageName)
196
+ {
197
+ foreach (self::getInstalled() as $installed) {
198
+ if (!isset($installed['versions'][$packageName])) {
199
+ continue;
200
+ }
201
+
202
+ if (!isset($installed['versions'][$packageName]['reference'])) {
203
+ return null;
204
+ }
205
+
206
+ return $installed['versions'][$packageName]['reference'];
207
+ }
208
+
209
+ throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
210
+ }
211
+
212
+ /**
213
+ * @param string $packageName
214
+ * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as install path. Packages of type metapackages also have a null install path.
215
+ */
216
+ public static function getInstallPath($packageName)
217
+ {
218
+ foreach (self::getInstalled() as $installed) {
219
+ if (!isset($installed['versions'][$packageName])) {
220
+ continue;
221
+ }
222
+
223
+ return isset($installed['versions'][$packageName]['install_path']) ? $installed['versions'][$packageName]['install_path'] : null;
224
+ }
225
+
226
+ throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
227
+ }
228
+
229
+ /**
230
+ * @return array
231
+ * @psalm-return array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string}
232
+ */
233
+ public static function getRootPackage()
234
+ {
235
+ $installed = self::getInstalled();
236
+
237
+ return $installed[0]['root'];
238
+ }
239
+
240
+ /**
241
+ * Returns the raw installed.php data for custom implementations
242
+ *
243
+ * @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect.
244
+ * @return array[]
245
+ * @psalm-return array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string}>}
246
+ */
247
+ public static function getRawData()
248
+ {
249
+ @trigger_error('getRawData only returns the first dataset loaded, which may not be what you expect. Use getAllRawData() instead which returns all datasets for all autoloaders present in the process.', E_USER_DEPRECATED);
250
+
251
+ if (null === self::$installed) {
252
+ // only require the installed.php file if this file is loaded from its dumped location,
253
+ // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937
254
+ if (substr(__DIR__, -8, 1) !== 'C') {
255
+ self::$installed = include __DIR__ . '/installed.php';
256
+ } else {
257
+ self::$installed = array();
258
+ }
259
+ }
260
+
261
+ return self::$installed;
262
+ }
263
+
264
+ /**
265
+ * Returns the raw data of all installed.php which are currently loaded for custom implementations
266
+ *
267
+ * @return array[]
268
+ * @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string}>}>
269
+ */
270
+ public static function getAllRawData()
271
+ {
272
+ return self::getInstalled();
273
+ }
274
+
275
+ /**
276
+ * Lets you reload the static array from another file
277
+ *
278
+ * This is only useful for complex integrations in which a project needs to use
279
+ * this class but then also needs to execute another project's autoloader in process,
280
+ * and wants to ensure both projects have access to their version of installed.php.
281
+ *
282
+ * A typical case would be PHPUnit, where it would need to make sure it reads all
283
+ * the data it needs from this class, then call reload() with
284
+ * `require $CWD/vendor/composer/installed.php` (or similar) as input to make sure
285
+ * the project in which it runs can then also use this class safely, without
286
+ * interference between PHPUnit's dependencies and the project's dependencies.
287
+ *
288
+ * @param array[] $data A vendor/composer/installed.php data set
289
+ * @return void
290
+ *
291
+ * @psalm-param array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string}>} $data
292
+ */
293
+ public static function reload($data)
294
+ {
295
+ self::$installed = $data;
296
+ self::$installedByVendor = array();
297
+ }
298
+
299
+ /**
300
+ * @return array[]
301
+ * @psalm-return list<array{root: array{name: string, version: string, reference: string, pretty_version: string, aliases: string[], dev: bool, install_path: string}, versions: array<string, array{dev_requirement: bool, pretty_version?: string, version?: string, aliases?: string[], reference?: string, replaced?: string[], provided?: string[], install_path?: string}>}>
302
+ */
303
+ private static function getInstalled()
304
+ {
305
+ if (null === self::$canGetVendors) {
306
+ self::$canGetVendors = method_exists('Composer\Autoload\ClassLoader', 'getRegisteredLoaders');
307
+ }
308
+
309
+ $installed = array();
310
+
311
+ if (self::$canGetVendors) {
312
+ foreach (ClassLoader::getRegisteredLoaders() as $vendorDir => $loader) {
313
+ if (isset(self::$installedByVendor[$vendorDir])) {
314
+ $installed[] = self::$installedByVendor[$vendorDir];
315
+ } elseif (is_file($vendorDir.'/composer/installed.php')) {
316
+ $installed[] = self::$installedByVendor[$vendorDir] = require $vendorDir.'/composer/installed.php';
317
+ if (null === self::$installed && strtr($vendorDir.'/composer', '\\', '/') === strtr(__DIR__, '\\', '/')) {
318
+ self::$installed = $installed[count($installed) - 1];
319
+ }
320
+ }
321
+ }
322
+ }
323
+
324
+ if (null === self::$installed) {
325
+ // only require the installed.php file if this file is loaded from its dumped location,
326
+ // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937
327
+ if (substr(__DIR__, -8, 1) !== 'C') {
328
+ self::$installed = require __DIR__ . '/installed.php';
329
+ } else {
330
+ self::$installed = array();
331
+ }
332
+ }
333
+ $installed[] = self::$installed;
334
+
335
+ return $installed;
336
+ }
337
+ }
vendor/composer/LICENSE ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+
2
+ Copyright (c) Nils Adermann, Jordi Boggiano
3
+
4
+ Permission is hereby granted, free of charge, to any person obtaining a copy
5
+ of this software and associated documentation files (the "Software"), to deal
6
+ in the Software without restriction, including without limitation the rights
7
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8
+ copies of the Software, and to permit persons to whom the Software is furnished
9
+ to do so, subject to the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be included in all
12
+ copies or substantial portions of the Software.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
20
+ THE SOFTWARE.
21
+
vendor/composer/autoload_classmap.php ADDED
@@ -0,0 +1,125 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // autoload_classmap.php @generated by Composer
4
+
5
+ $vendorDir = dirname(dirname(__FILE__));
6
+ $baseDir = dirname($vendorDir);
7
+
8
+ return array(
9
+ 'Composer\\InstalledVersions' => $vendorDir . '/composer/InstalledVersions.php',
10
+ 'Composer\\Installers\\AglInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AglInstaller.php',
11
+ 'Composer\\Installers\\AimeosInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AimeosInstaller.php',
12
+ 'Composer\\Installers\\AnnotateCmsInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AnnotateCmsInstaller.php',
13
+ 'Composer\\Installers\\AsgardInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AsgardInstaller.php',
14
+ 'Composer\\Installers\\AttogramInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/AttogramInstaller.php',
15
+ 'Composer\\Installers\\BaseInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/BaseInstaller.php',
16
+ 'Composer\\Installers\\BitrixInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/BitrixInstaller.php',
17
+ 'Composer\\Installers\\BonefishInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/BonefishInstaller.php',
18
+ 'Composer\\Installers\\CakePHPInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CakePHPInstaller.php',
19
+ 'Composer\\Installers\\ChefInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ChefInstaller.php',
20
+ 'Composer\\Installers\\CiviCrmInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CiviCrmInstaller.php',
21
+ 'Composer\\Installers\\ClanCatsFrameworkInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ClanCatsFrameworkInstaller.php',
22
+ 'Composer\\Installers\\CockpitInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CockpitInstaller.php',
23
+ 'Composer\\Installers\\CodeIgniterInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CodeIgniterInstaller.php',
24
+ 'Composer\\Installers\\Concrete5Installer' => $vendorDir . '/composer/installers/src/Composer/Installers/Concrete5Installer.php',
25
+ 'Composer\\Installers\\CraftInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CraftInstaller.php',
26
+ 'Composer\\Installers\\CroogoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/CroogoInstaller.php',
27
+ 'Composer\\Installers\\DecibelInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DecibelInstaller.php',
28
+ 'Composer\\Installers\\DframeInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DframeInstaller.php',
29
+ 'Composer\\Installers\\DokuWikiInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DokuWikiInstaller.php',
30
+ 'Composer\\Installers\\DolibarrInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DolibarrInstaller.php',
31
+ 'Composer\\Installers\\DrupalInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/DrupalInstaller.php',
32
+ 'Composer\\Installers\\ElggInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ElggInstaller.php',
33
+ 'Composer\\Installers\\EliasisInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/EliasisInstaller.php',
34
+ 'Composer\\Installers\\ExpressionEngineInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php',
35
+ 'Composer\\Installers\\EzPlatformInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/EzPlatformInstaller.php',
36
+ 'Composer\\Installers\\FuelInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/FuelInstaller.php',
37
+ 'Composer\\Installers\\FuelphpInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/FuelphpInstaller.php',
38
+ 'Composer\\Installers\\GravInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/GravInstaller.php',
39
+ 'Composer\\Installers\\HuradInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/HuradInstaller.php',
40
+ 'Composer\\Installers\\ImageCMSInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ImageCMSInstaller.php',
41
+ 'Composer\\Installers\\Installer' => $vendorDir . '/composer/installers/src/Composer/Installers/Installer.php',
42
+ 'Composer\\Installers\\ItopInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ItopInstaller.php',
43
+ 'Composer\\Installers\\JoomlaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/JoomlaInstaller.php',
44
+ 'Composer\\Installers\\KanboardInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/KanboardInstaller.php',
45
+ 'Composer\\Installers\\KirbyInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/KirbyInstaller.php',
46
+ 'Composer\\Installers\\KnownInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/KnownInstaller.php',
47
+ 'Composer\\Installers\\KodiCMSInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/KodiCMSInstaller.php',
48
+ 'Composer\\Installers\\KohanaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/KohanaInstaller.php',
49
+ 'Composer\\Installers\\LanManagementSystemInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/LanManagementSystemInstaller.php',
50
+ 'Composer\\Installers\\LaravelInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/LaravelInstaller.php',
51
+ 'Composer\\Installers\\LavaLiteInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/LavaLiteInstaller.php',
52
+ 'Composer\\Installers\\LithiumInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/LithiumInstaller.php',
53
+ 'Composer\\Installers\\MODULEWorkInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MODULEWorkInstaller.php',
54
+ 'Composer\\Installers\\MODXEvoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MODXEvoInstaller.php',
55
+ 'Composer\\Installers\\MagentoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MagentoInstaller.php',
56
+ 'Composer\\Installers\\MajimaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MajimaInstaller.php',
57
+ 'Composer\\Installers\\MakoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MakoInstaller.php',
58
+ 'Composer\\Installers\\MantisBTInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MantisBTInstaller.php',
59
+ 'Composer\\Installers\\MauticInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MauticInstaller.php',
60
+ 'Composer\\Installers\\MayaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MayaInstaller.php',
61
+ 'Composer\\Installers\\MediaWikiInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MediaWikiInstaller.php',
62
+ 'Composer\\Installers\\MiaoxingInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MiaoxingInstaller.php',
63
+ 'Composer\\Installers\\MicroweberInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MicroweberInstaller.php',
64
+ 'Composer\\Installers\\ModxInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ModxInstaller.php',
65
+ 'Composer\\Installers\\MoodleInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/MoodleInstaller.php',
66
+ 'Composer\\Installers\\OctoberInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/OctoberInstaller.php',
67
+ 'Composer\\Installers\\OntoWikiInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/OntoWikiInstaller.php',
68
+ 'Composer\\Installers\\OsclassInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/OsclassInstaller.php',
69
+ 'Composer\\Installers\\OxidInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/OxidInstaller.php',
70
+ 'Composer\\Installers\\PPIInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PPIInstaller.php',
71
+ 'Composer\\Installers\\PhiftyInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PhiftyInstaller.php',
72
+ 'Composer\\Installers\\PhpBBInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PhpBBInstaller.php',
73
+ 'Composer\\Installers\\PimcoreInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PimcoreInstaller.php',
74
+ 'Composer\\Installers\\PiwikInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PiwikInstaller.php',
75
+ 'Composer\\Installers\\PlentymarketsInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PlentymarketsInstaller.php',
76
+ 'Composer\\Installers\\Plugin' => $vendorDir . '/composer/installers/src/Composer/Installers/Plugin.php',
77
+ 'Composer\\Installers\\PortoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PortoInstaller.php',
78
+ 'Composer\\Installers\\PrestashopInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PrestashopInstaller.php',
79
+ 'Composer\\Installers\\ProcessWireInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ProcessWireInstaller.php',
80
+ 'Composer\\Installers\\PuppetInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PuppetInstaller.php',
81
+ 'Composer\\Installers\\PxcmsInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/PxcmsInstaller.php',
82
+ 'Composer\\Installers\\RadPHPInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/RadPHPInstaller.php',
83
+ 'Composer\\Installers\\ReIndexInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ReIndexInstaller.php',
84
+ 'Composer\\Installers\\Redaxo5Installer' => $vendorDir . '/composer/installers/src/Composer/Installers/Redaxo5Installer.php',
85
+ 'Composer\\Installers\\RedaxoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/RedaxoInstaller.php',
86
+ 'Composer\\Installers\\RoundcubeInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/RoundcubeInstaller.php',
87
+ 'Composer\\Installers\\SMFInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/SMFInstaller.php',
88
+ 'Composer\\Installers\\ShopwareInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ShopwareInstaller.php',
89
+ 'Composer\\Installers\\SilverStripeInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/SilverStripeInstaller.php',
90
+ 'Composer\\Installers\\SiteDirectInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/SiteDirectInstaller.php',
91
+ 'Composer\\Installers\\StarbugInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/StarbugInstaller.php',
92
+ 'Composer\\Installers\\SyDESInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/SyDESInstaller.php',
93
+ 'Composer\\Installers\\SyliusInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/SyliusInstaller.php',
94
+ 'Composer\\Installers\\Symfony1Installer' => $vendorDir . '/composer/installers/src/Composer/Installers/Symfony1Installer.php',
95
+ 'Composer\\Installers\\TYPO3CmsInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TYPO3CmsInstaller.php',
96
+ 'Composer\\Installers\\TYPO3FlowInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TYPO3FlowInstaller.php',
97
+ 'Composer\\Installers\\TaoInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TaoInstaller.php',
98
+ 'Composer\\Installers\\TastyIgniterInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TastyIgniterInstaller.php',
99
+ 'Composer\\Installers\\TheliaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TheliaInstaller.php',
100
+ 'Composer\\Installers\\TuskInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/TuskInstaller.php',
101
+ 'Composer\\Installers\\UserFrostingInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/UserFrostingInstaller.php',
102
+ 'Composer\\Installers\\VanillaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/VanillaInstaller.php',
103
+ 'Composer\\Installers\\VgmcpInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/VgmcpInstaller.php',
104
+ 'Composer\\Installers\\WHMCSInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/WHMCSInstaller.php',
105
+ 'Composer\\Installers\\WinterInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/WinterInstaller.php',
106
+ 'Composer\\Installers\\WolfCMSInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/WolfCMSInstaller.php',
107
+ 'Composer\\Installers\\WordPressInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/WordPressInstaller.php',
108
+ 'Composer\\Installers\\YawikInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/YawikInstaller.php',
109
+ 'Composer\\Installers\\ZendInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ZendInstaller.php',
110
+ 'Composer\\Installers\\ZikulaInstaller' => $vendorDir . '/composer/installers/src/Composer/Installers/ZikulaInstaller.php',
111
+ 'LoginWP\\Core\\Admin\\AbstractSettingsPage' => $baseDir . '/src/core/src/Admin/AbstractSettingsPage.php',
112
+ 'LoginWP\\Core\\Admin\\Admin' => $baseDir . '/src/core/src/Admin/Admin.php',
113
+ 'LoginWP\\Core\\Admin\\Installer\\LoginWP_Install_Skin' => $baseDir . '/src/core/src/Admin/Installer/LoginWP_Install_Skin.php',
114
+ 'LoginWP\\Core\\Admin\\Installer\\PluginSilentUpgrader' => $baseDir . '/src/core/src/Admin/Installer/PluginSilentUpgrader.php',
115
+ 'LoginWP\\Core\\Admin\\Installer\\PluginSilentUpgraderSkin' => $baseDir . '/src/core/src/Admin/Installer/PluginSilentUpgraderSkin.php',
116
+ 'LoginWP\\Core\\Admin\\ProfilePress' => $baseDir . '/src/core/src/Admin/ProfilePress.php',
117
+ 'LoginWP\\Core\\Admin\\RedirectWPList' => $baseDir . '/src/core/src/Admin/RedirectWPList.php',
118
+ 'LoginWP\\Core\\Admin\\RedirectionsPage' => $baseDir . '/src/core/src/Admin/RedirectionsPage.php',
119
+ 'LoginWP\\Core\\Admin\\SettingsPage' => $baseDir . '/src/core/src/Admin/SettingsPage.php',
120
+ 'LoginWP\\Core\\Admin\\SettingsPageApi' => $baseDir . '/src/core/src/Admin/SettingsPageApi.php',
121
+ 'LoginWP\\Core\\Core' => $baseDir . '/src/core/src/Core.php',
122
+ 'LoginWP\\Core\\Helpers' => $baseDir . '/src/core/src/Helpers.php',
123
+ 'LoginWP\\Core\\Redirections\\Redirections' => $baseDir . '/src/core/src/Redirections/Redirections.php',
124
+ 'PAnD' => $vendorDir . '/collizo4sky/persist-admin-notices-dismissal/persist-admin-notices-dismissal.php',
125
+ );
vendor/composer/autoload_files.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // autoload_files.php @generated by Composer
4
+
5
+ $vendorDir = dirname(dirname(__FILE__));
6
+ $baseDir = dirname($vendorDir);
7
+
8
+ return array(
9
+ '7c119350ad5d791b1ae2d87a60e07ace' => $baseDir . '/src/core/src/MoAdminNotice.php',
10
+ '3bf5dc06dc60153669808308032ef358' => $baseDir . '/src/core/src/Functions.php',
11
+ );
vendor/composer/autoload_namespaces.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // autoload_namespaces.php @generated by Composer
4
+
5
+ $vendorDir = dirname(dirname(__FILE__));
6
+ $baseDir = dirname($vendorDir);
7
+
8
+ return array(
9
+ );
vendor/composer/autoload_psr4.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // autoload_psr4.php @generated by Composer
4
+
5
+ $vendorDir = dirname(dirname(__FILE__));
6
+ $baseDir = dirname($vendorDir);
7
+
8
+ return array(
9
+ 'LoginWP\\Core\\' => array($baseDir . '/src/core/src'),
10
+ 'Composer\\Installers\\' => array($vendorDir . '/composer/installers/src/Composer/Installers'),
11
+ );
vendor/composer/autoload_real.php ADDED
@@ -0,0 +1,75 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // autoload_real.php @generated by Composer
4
+
5
+ class ComposerAutoloaderInitd2e8977aa883062bbd1dd5840dd615c3
6
+ {
7
+ private static $loader;
8
+
9
+ public static function loadClassLoader($class)
10
+ {
11
+ if ('Composer\Autoload\ClassLoader' === $class) {
12
+ require __DIR__ . '/ClassLoader.php';
13
+ }
14
+ }
15
+
16
+ /**
17
+ * @return \Composer\Autoload\ClassLoader
18
+ */
19
+ public static function getLoader()
20
+ {
21
+ if (null !== self::$loader) {
22
+ return self::$loader;
23
+ }
24
+
25
+ require __DIR__ . '/platform_check.php';
26
+
27
+ spl_autoload_register(array('ComposerAutoloaderInitd2e8977aa883062bbd1dd5840dd615c3', 'loadClassLoader'), true, true);
28
+ self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__)));
29
+ spl_autoload_unregister(array('ComposerAutoloaderInitd2e8977aa883062bbd1dd5840dd615c3', 'loadClassLoader'));
30
+
31
+ $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
32
+ if ($useStaticLoader) {
33
+ require __DIR__ . '/autoload_static.php';
34
+
35
+ call_user_func(\Composer\Autoload\ComposerStaticInitd2e8977aa883062bbd1dd5840dd615c3::getInitializer($loader));
36
+ } else {
37
+ $map = require __DIR__ . '/autoload_namespaces.php';
38
+ foreach ($map as $namespace => $path) {
39
+ $loader->set($namespace, $path);
40
+ }
41
+
42
+ $map = require __DIR__ . '/autoload_psr4.php';
43
+ foreach ($map as $namespace => $path) {
44
+ $loader->setPsr4($namespace, $path);
45
+ }
46
+
47
+ $classMap = require __DIR__ . '/autoload_classmap.php';
48
+ if ($classMap) {
49
+ $loader->addClassMap($classMap);
50
+ }
51
+ }
52
+
53
+ $loader->register(true);
54
+
55
+ if ($useStaticLoader) {
56
+ $includeFiles = Composer\Autoload\ComposerStaticInitd2e8977aa883062bbd1dd5840dd615c3::$files;
57
+ } else {
58
+ $includeFiles = require __DIR__ . '/autoload_files.php';
59
+ }
60
+ foreach ($includeFiles as $fileIdentifier => $file) {
61
+ composerRequired2e8977aa883062bbd1dd5840dd615c3($fileIdentifier, $file);
62
+ }
63
+
64
+ return $loader;
65
+ }
66
+ }
67
+
68
+ function composerRequired2e8977aa883062bbd1dd5840dd615c3($fileIdentifier, $file)
69
+ {
70
+ if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
71
+ require $file;
72
+
73
+ $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
74
+ }
75
+ }
vendor/composer/autoload_static.php ADDED
@@ -0,0 +1,164 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // autoload_static.php @generated by Composer
4
+
5
+ namespace Composer\Autoload;
6
+
7
+ class ComposerStaticInitd2e8977aa883062bbd1dd5840dd615c3
8
+ {
9
+ public static $files = array (
10
+ '7c119350ad5d791b1ae2d87a60e07ace' => __DIR__ . '/../..' . '/src/core/src/MoAdminNotice.php',
11
+ '3bf5dc06dc60153669808308032ef358' => __DIR__ . '/../..' . '/src/core/src/Functions.php',
12
+ );
13
+
14
+ public static $prefixLengthsPsr4 = array (
15
+ 'L' =>
16
+ array (
17
+ 'LoginWP\\Core\\' => 13,
18
+ ),
19
+ 'C' =>
20
+ array (
21
+ 'Composer\\Installers\\' => 20,
22
+ ),
23
+ );
24
+
25
+ public static $prefixDirsPsr4 = array (
26
+ 'LoginWP\\Core\\' =>
27
+ array (
28
+ 0 => __DIR__ . '/../..' . '/src/core/src',
29
+ ),
30
+ 'Composer\\Installers\\' =>
31
+ array (
32
+ 0 => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers',
33
+ ),
34
+ );
35
+
36
+ public static $classMap = array (
37
+ 'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
38
+ 'Composer\\Installers\\AglInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/AglInstaller.php',
39
+ 'Composer\\Installers\\AimeosInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/AimeosInstaller.php',
40
+ 'Composer\\Installers\\AnnotateCmsInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/AnnotateCmsInstaller.php',
41
+ 'Composer\\Installers\\AsgardInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/AsgardInstaller.php',
42
+ 'Composer\\Installers\\AttogramInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/AttogramInstaller.php',
43
+ 'Composer\\Installers\\BaseInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/BaseInstaller.php',
44
+ 'Composer\\Installers\\BitrixInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/BitrixInstaller.php',
45
+ 'Composer\\Installers\\BonefishInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/BonefishInstaller.php',
46
+ 'Composer\\Installers\\CakePHPInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/CakePHPInstaller.php',
47
+ 'Composer\\Installers\\ChefInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ChefInstaller.php',
48
+ 'Composer\\Installers\\CiviCrmInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/CiviCrmInstaller.php',
49
+ 'Composer\\Installers\\ClanCatsFrameworkInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ClanCatsFrameworkInstaller.php',
50
+ 'Composer\\Installers\\CockpitInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/CockpitInstaller.php',
51
+ 'Composer\\Installers\\CodeIgniterInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/CodeIgniterInstaller.php',
52
+ 'Composer\\Installers\\Concrete5Installer' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/Concrete5Installer.php',
53
+ 'Composer\\Installers\\CraftInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/CraftInstaller.php',
54
+ 'Composer\\Installers\\CroogoInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/CroogoInstaller.php',
55
+ 'Composer\\Installers\\DecibelInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/DecibelInstaller.php',
56
+ 'Composer\\Installers\\DframeInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/DframeInstaller.php',
57
+ 'Composer\\Installers\\DokuWikiInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/DokuWikiInstaller.php',
58
+ 'Composer\\Installers\\DolibarrInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/DolibarrInstaller.php',
59
+ 'Composer\\Installers\\DrupalInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/DrupalInstaller.php',
60
+ 'Composer\\Installers\\ElggInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ElggInstaller.php',
61
+ 'Composer\\Installers\\EliasisInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/EliasisInstaller.php',
62
+ 'Composer\\Installers\\ExpressionEngineInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php',
63
+ 'Composer\\Installers\\EzPlatformInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/EzPlatformInstaller.php',
64
+ 'Composer\\Installers\\FuelInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/FuelInstaller.php',
65
+ 'Composer\\Installers\\FuelphpInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/FuelphpInstaller.php',
66
+ 'Composer\\Installers\\GravInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/GravInstaller.php',
67
+ 'Composer\\Installers\\HuradInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/HuradInstaller.php',
68
+ 'Composer\\Installers\\ImageCMSInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ImageCMSInstaller.php',
69
+ 'Composer\\Installers\\Installer' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/Installer.php',
70
+ 'Composer\\Installers\\ItopInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ItopInstaller.php',
71
+ 'Composer\\Installers\\JoomlaInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/JoomlaInstaller.php',
72
+ 'Composer\\Installers\\KanboardInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/KanboardInstaller.php',
73
+ 'Composer\\Installers\\KirbyInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/KirbyInstaller.php',
74
+ 'Composer\\Installers\\KnownInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/KnownInstaller.php',
75
+ 'Composer\\Installers\\KodiCMSInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/KodiCMSInstaller.php',
76
+ 'Composer\\Installers\\KohanaInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/KohanaInstaller.php',
77
+ 'Composer\\Installers\\LanManagementSystemInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/LanManagementSystemInstaller.php',
78
+ 'Composer\\Installers\\LaravelInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/LaravelInstaller.php',
79
+ 'Composer\\Installers\\LavaLiteInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/LavaLiteInstaller.php',
80
+ 'Composer\\Installers\\LithiumInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/LithiumInstaller.php',
81
+ 'Composer\\Installers\\MODULEWorkInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MODULEWorkInstaller.php',
82
+ 'Composer\\Installers\\MODXEvoInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MODXEvoInstaller.php',
83
+ 'Composer\\Installers\\MagentoInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MagentoInstaller.php',
84
+ 'Composer\\Installers\\MajimaInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MajimaInstaller.php',
85
+ 'Composer\\Installers\\MakoInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MakoInstaller.php',
86
+ 'Composer\\Installers\\MantisBTInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MantisBTInstaller.php',
87
+ 'Composer\\Installers\\MauticInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MauticInstaller.php',
88
+ 'Composer\\Installers\\MayaInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MayaInstaller.php',
89
+ 'Composer\\Installers\\MediaWikiInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MediaWikiInstaller.php',
90
+ 'Composer\\Installers\\MiaoxingInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MiaoxingInstaller.php',
91
+ 'Composer\\Installers\\MicroweberInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MicroweberInstaller.php',
92
+ 'Composer\\Installers\\ModxInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ModxInstaller.php',
93
+ 'Composer\\Installers\\MoodleInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/MoodleInstaller.php',
94
+ 'Composer\\Installers\\OctoberInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/OctoberInstaller.php',
95
+ 'Composer\\Installers\\OntoWikiInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/OntoWikiInstaller.php',
96
+ 'Composer\\Installers\\OsclassInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/OsclassInstaller.php',
97
+ 'Composer\\Installers\\OxidInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/OxidInstaller.php',
98
+ 'Composer\\Installers\\PPIInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PPIInstaller.php',
99
+ 'Composer\\Installers\\PhiftyInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PhiftyInstaller.php',
100
+ 'Composer\\Installers\\PhpBBInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PhpBBInstaller.php',
101
+ 'Composer\\Installers\\PimcoreInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PimcoreInstaller.php',
102
+ 'Composer\\Installers\\PiwikInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PiwikInstaller.php',
103
+ 'Composer\\Installers\\PlentymarketsInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PlentymarketsInstaller.php',
104
+ 'Composer\\Installers\\Plugin' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/Plugin.php',
105
+ 'Composer\\Installers\\PortoInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PortoInstaller.php',
106
+ 'Composer\\Installers\\PrestashopInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PrestashopInstaller.php',
107
+ 'Composer\\Installers\\ProcessWireInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ProcessWireInstaller.php',
108
+ 'Composer\\Installers\\PuppetInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PuppetInstaller.php',
109
+ 'Composer\\Installers\\PxcmsInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/PxcmsInstaller.php',
110
+ 'Composer\\Installers\\RadPHPInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/RadPHPInstaller.php',
111
+ 'Composer\\Installers\\ReIndexInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ReIndexInstaller.php',
112
+ 'Composer\\Installers\\Redaxo5Installer' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/Redaxo5Installer.php',
113
+ 'Composer\\Installers\\RedaxoInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/RedaxoInstaller.php',
114
+ 'Composer\\Installers\\RoundcubeInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/RoundcubeInstaller.php',
115
+ 'Composer\\Installers\\SMFInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/SMFInstaller.php',
116
+ 'Composer\\Installers\\ShopwareInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ShopwareInstaller.php',
117
+ 'Composer\\Installers\\SilverStripeInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/SilverStripeInstaller.php',
118
+ 'Composer\\Installers\\SiteDirectInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/SiteDirectInstaller.php',
119
+ 'Composer\\Installers\\StarbugInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/StarbugInstaller.php',
120
+ 'Composer\\Installers\\SyDESInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/SyDESInstaller.php',
121
+ 'Composer\\Installers\\SyliusInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/SyliusInstaller.php',
122
+ 'Composer\\Installers\\Symfony1Installer' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/Symfony1Installer.php',
123
+ 'Composer\\Installers\\TYPO3CmsInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/TYPO3CmsInstaller.php',
124
+ 'Composer\\Installers\\TYPO3FlowInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/TYPO3FlowInstaller.php',
125
+ 'Composer\\Installers\\TaoInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/TaoInstaller.php',
126
+ 'Composer\\Installers\\TastyIgniterInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/TastyIgniterInstaller.php',
127
+ 'Composer\\Installers\\TheliaInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/TheliaInstaller.php',
128
+ 'Composer\\Installers\\TuskInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/TuskInstaller.php',
129
+ 'Composer\\Installers\\UserFrostingInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/UserFrostingInstaller.php',
130
+ 'Composer\\Installers\\VanillaInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/VanillaInstaller.php',
131
+ 'Composer\\Installers\\VgmcpInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/VgmcpInstaller.php',
132
+ 'Composer\\Installers\\WHMCSInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/WHMCSInstaller.php',
133
+ 'Composer\\Installers\\WinterInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/WinterInstaller.php',
134
+ 'Composer\\Installers\\WolfCMSInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/WolfCMSInstaller.php',
135
+ 'Composer\\Installers\\WordPressInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/WordPressInstaller.php',
136
+ 'Composer\\Installers\\YawikInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/YawikInstaller.php',
137
+ 'Composer\\Installers\\ZendInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ZendInstaller.php',
138
+ 'Composer\\Installers\\ZikulaInstaller' => __DIR__ . '/..' . '/composer/installers/src/Composer/Installers/ZikulaInstaller.php',
139
+ 'LoginWP\\Core\\Admin\\AbstractSettingsPage' => __DIR__ . '/../..' . '/src/core/src/Admin/AbstractSettingsPage.php',
140
+ 'LoginWP\\Core\\Admin\\Admin' => __DIR__ . '/../..' . '/src/core/src/Admin/Admin.php',
141
+ 'LoginWP\\Core\\Admin\\Installer\\LoginWP_Install_Skin' => __DIR__ . '/../..' . '/src/core/src/Admin/Installer/LoginWP_Install_Skin.php',
142
+ 'LoginWP\\Core\\Admin\\Installer\\PluginSilentUpgrader' => __DIR__ . '/../..' . '/src/core/src/Admin/Installer/PluginSilentUpgrader.php',
143
+ 'LoginWP\\Core\\Admin\\Installer\\PluginSilentUpgraderSkin' => __DIR__ . '/../..' . '/src/core/src/Admin/Installer/PluginSilentUpgraderSkin.php',
144
+ 'LoginWP\\Core\\Admin\\ProfilePress' => __DIR__ . '/../..' . '/src/core/src/Admin/ProfilePress.php',
145
+ 'LoginWP\\Core\\Admin\\RedirectWPList' => __DIR__ . '/../..' . '/src/core/src/Admin/RedirectWPList.php',
146
+ 'LoginWP\\Core\\Admin\\RedirectionsPage' => __DIR__ . '/../..' . '/src/core/src/Admin/RedirectionsPage.php',
147
+ 'LoginWP\\Core\\Admin\\SettingsPage' => __DIR__ . '/../..' . '/src/core/src/Admin/SettingsPage.php',
148
+ 'LoginWP\\Core\\Admin\\SettingsPageApi' => __DIR__ . '/../..' . '/src/core/src/Admin/SettingsPageApi.php',
149
+ 'LoginWP\\Core\\Core' => __DIR__ . '/../..' . '/src/core/src/Core.php',
150
+ 'LoginWP\\Core\\Helpers' => __DIR__ . '/../..' . '/src/core/src/Helpers.php',
151
+ 'LoginWP\\Core\\Redirections\\Redirections' => __DIR__ . '/../..' . '/src/core/src/Redirections/Redirections.php',
152
+ 'PAnD' => __DIR__ . '/..' . '/collizo4sky/persist-admin-notices-dismissal/persist-admin-notices-dismissal.php',
153
+ );
154
+
155
+ public static function getInitializer(ClassLoader $loader)
156
+ {
157
+ return \Closure::bind(function () use ($loader) {
158
+ $loader->prefixLengthsPsr4 = ComposerStaticInitd2e8977aa883062bbd1dd5840dd615c3::$prefixLengthsPsr4;
159
+ $loader->prefixDirsPsr4 = ComposerStaticInitd2e8977aa883062bbd1dd5840dd615c3::$prefixDirsPsr4;
160
+ $loader->classMap = ComposerStaticInitd2e8977aa883062bbd1dd5840dd615c3::$classMap;
161
+
162
+ }, null, ClassLoader::class);
163
+ }
164
+ }
vendor/composer/installed.json ADDED
@@ -0,0 +1,242 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "packages": [
3
+ {
4
+ "name": "collizo4sky/persist-admin-notices-dismissal",
5
+ "version": "1.4.4",
6
+ "version_normalized": "1.4.4.0",
7
+ "source": {
8
+ "type": "git",
9
+ "url": "https://github.com/w3guy/persist-admin-notices-dismissal.git",
10
+ "reference": "900739eb6b0ec0210465f5983a6d4e0e420289e4"
11
+ },
12
+ "dist": {
13
+ "type": "zip",
14
+ "url": "https://api.github.com/repos/w3guy/persist-admin-notices-dismissal/zipball/900739eb6b0ec0210465f5983a6d4e0e420289e4",
15
+ "reference": "900739eb6b0ec0210465f5983a6d4e0e420289e4",
16
+ "shasum": ""
17
+ },
18
+ "require": {
19
+ "php": ">=5.4"
20
+ },
21
+ "time": "2020-12-31T17:12:37+00:00",
22
+ "type": "library",
23
+ "installation-source": "dist",
24
+ "autoload": {
25
+ "classmap": [
26
+ "persist-admin-notices-dismissal.php"
27
+ ]
28
+ },
29
+ "notification-url": "https://packagist.org/downloads/",
30
+ "license": [
31
+ "GPL-3.0-or-later"
32
+ ],
33
+ "authors": [
34
+ {
35
+ "name": "Collins Agbonghama",
36
+ "email": "me@w3guy.com",
37
+ "role": "developer"
38
+ }
39
+ ],
40
+ "description": "Simple library to persist dismissal of admin notices across pages in WordPress dashboard.",
41
+ "support": {
42
+ "issues": "https://github.com/w3guy/persist-admin-notices-dismissal/issues",
43
+ "source": "https://github.com/w3guy/persist-admin-notices-dismissal"
44
+ },
45
+ "install-path": "../collizo4sky/persist-admin-notices-dismissal"
46
+ },
47
+ {
48
+ "name": "composer/installers",
49
+ "version": "v1.11.0",
50
+ "version_normalized": "1.11.0.0",
51
+ "source": {
52
+ "type": "git",
53
+ "url": "https://github.com/composer/installers.git",
54
+ "reference": "ae03311f45dfe194412081526be2e003960df74b"
55
+ },
56
+ "dist": {
57
+ "type": "zip",
58
+ "url": "https://api.github.com/repos/composer/installers/zipball/ae03311f45dfe194412081526be2e003960df74b",
59
+ "reference": "ae03311f45dfe194412081526be2e003960df74b",
60
+ "shasum": ""
61
+ },
62
+ "require": {
63
+ "composer-plugin-api": "^1.0 || ^2.0"
64
+ },
65
+ "replace": {
66
+ "roundcube/plugin-installer": "*",
67
+ "shama/baton": "*"
68
+ },
69
+ "require-dev": {
70
+ "composer/composer": "1.6.* || ^2.0",
71
+ "composer/semver": "^1 || ^3",
72
+ "phpstan/phpstan": "^0.12.55",
73
+ "phpstan/phpstan-phpunit": "^0.12.16",
74
+ "symfony/phpunit-bridge": "^4.2 || ^5",
75
+ "symfony/process": "^2.3"
76
+ },
77
+ "time": "2021-04-28T06:42:17+00:00",
78
+ "type": "composer-plugin",
79
+ "extra": {
80
+ "class": "Composer\\Installers\\Plugin",
81
+ "branch-alias": {
82
+ "dev-main": "1.x-dev"
83
+ }
84
+ },
85
+ "installation-source": "dist",
86
+ "autoload": {
87
+ "psr-4": {
88
+ "Composer\\Installers\\": "src/Composer/Installers"
89
+ }
90
+ },
91
+ "notification-url": "https://packagist.org/downloads/",
92
+ "license": [
93
+ "MIT"
94
+ ],
95
+ "authors": [
96
+ {
97
+ "name": "Kyle Robinson Young",
98
+ "email": "kyle@dontkry.com",
99
+ "homepage": "https://github.com/shama"
100
+ }
101
+ ],
102
+ "description": "A multi-framework Composer library installer",
103
+ "homepage": "https://composer.github.io/installers/",
104
+ "keywords": [
105
+ "Craft",
106
+ "Dolibarr",
107
+ "Eliasis",
108
+ "Hurad",
109
+ "ImageCMS",
110
+ "Kanboard",
111
+ "Lan Management System",
112
+ "MODX Evo",
113
+ "MantisBT",
114
+ "Mautic",
115
+ "Maya",
116
+ "OXID",
117
+ "Plentymarkets",
118
+ "Porto",
119
+ "RadPHP",
120
+ "SMF",
121
+ "Starbug",
122
+ "Thelia",
123
+ "Whmcs",
124
+ "WolfCMS",
125
+ "agl",
126
+ "aimeos",
127
+ "annotatecms",
128
+ "attogram",
129
+ "bitrix",
130
+ "cakephp",
131
+ "chef",
132
+ "cockpit",
133
+ "codeigniter",
134
+ "concrete5",
135
+ "croogo",
136
+ "dokuwiki",
137
+ "drupal",
138
+ "eZ Platform",
139
+ "elgg",
140
+ "expressionengine",
141
+ "fuelphp",
142
+ "grav",
143
+ "installer",
144
+ "itop",
145
+ "joomla",
146
+ "known",
147
+ "kohana",
148
+ "laravel",
149
+ "lavalite",
150
+ "lithium",
151
+ "magento",
152
+ "majima",
153
+ "mako",
154
+ "mediawiki",
155
+ "miaoxing",
156
+ "modulework",
157
+ "modx",
158
+ "moodle",
159
+ "osclass",
160
+ "phpbb",
161
+ "piwik",
162
+ "ppi",
163
+ "processwire",
164
+ "puppet",
165
+ "pxcms",
166
+ "reindex",
167
+ "roundcube",
168
+ "shopware",
169
+ "silverstripe",
170
+ "sydes",
171
+ "sylius",
172
+ "symfony",
173
+ "tastyigniter",
174
+ "typo3",
175
+ "wordpress",
176
+ "yawik",
177
+ "zend",
178
+ "zikula"
179
+ ],
180
+ "support": {
181
+ "issues": "https://github.com/composer/installers/issues",
182
+ "source": "https://github.com/composer/installers/tree/v1.11.0"
183
+ },
184
+ "funding": [
185
+ {
186
+ "url": "https://packagist.com",
187
+ "type": "custom"
188
+ },
189
+ {
190
+ "url": "https://github.com/composer",
191
+ "type": "github"
192
+ },
193
+ {
194
+ "url": "https://tidelift.com/funding/github/packagist/composer/composer",
195
+ "type": "tidelift"
196
+ }
197
+ ],
198
+ "install-path": "./installers"
199
+ },
200
+ {
201
+ "name": "loginwp/core",
202
+ "version": "0.1.0-alpha.1631387791",
203
+ "version_normalized": "0.1.0.0-alpha1631387791",
204
+ "source": {
205
+ "type": "git",
206
+ "url": "https://github.com/LoginWP/Core.git",
207
+ "reference": "89a37fbca268153e7569a051cf4aac8395f3029b"
208
+ },
209
+ "dist": {
210
+ "type": "zip",
211
+ "url": "https://api.github.com/repos/LoginWP/Core/zipball/89a37fbca268153e7569a051cf4aac8395f3029b",
212
+ "reference": "89a37fbca268153e7569a051cf4aac8395f3029b",
213
+ "shasum": ""
214
+ },
215
+ "require": {
216
+ "collizo4sky/persist-admin-notices-dismissal": "^1.4",
217
+ "composer/installers": "~1.0"
218
+ },
219
+ "time": "2021-09-10T09:48:29+00:00",
220
+ "type": "wordpress-plugin",
221
+ "installation-source": "dist",
222
+ "autoload": {
223
+ "psr-4": {
224
+ "LoginWP\\Core\\": "src/"
225
+ },
226
+ "files": [
227
+ "src/MoAdminNotice.php",
228
+ "src/Functions.php"
229
+ ]
230
+ },
231
+ "notification-url": "https://packagist.org/downloads/",
232
+ "description": "Core lib for LoginWP",
233
+ "support": {
234
+ "issues": "https://github.com/LoginWP/Core/issues",
235
+ "source": "https://github.com/LoginWP/Core/tree/0.1.0-alpha.1631387791"
236
+ },
237
+ "install-path": "../../src/core"
238
+ }
239
+ ],
240
+ "dev": false,
241
+ "dev-package-names": []
242
+ }
vendor/composer/installed.php ADDED
@@ -0,0 +1,62 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php return array(
2
+ 'root' => array(
3
+ 'pretty_version' => '3.x-dev',
4
+ 'version' => '3.9999999.9999999.9999999-dev',
5
+ 'type' => 'library',
6
+ 'install_path' => __DIR__ . '/../../',
7
+ 'aliases' => array(),
8
+ 'reference' => '71baab880b5d4fc49bfc889c1a6a337ad75c6054',
9
+ 'name' => '__root__',
10
+ 'dev' => false,
11
+ ),
12
+ 'versions' => array(
13
+ '__root__' => array(
14
+ 'pretty_version' => '3.x-dev',
15
+ 'version' => '3.9999999.9999999.9999999-dev',
16
+ 'type' => 'library',
17
+ 'install_path' => __DIR__ . '/../../',
18
+ 'aliases' => array(),
19
+ 'reference' => '71baab880b5d4fc49bfc889c1a6a337ad75c6054',
20
+ 'dev_requirement' => false,
21
+ ),
22
+ 'collizo4sky/persist-admin-notices-dismissal' => array(
23
+ 'pretty_version' => '1.4.4',
24
+ 'version' => '1.4.4.0',
25
+ 'type' => 'library',
26
+ 'install_path' => __DIR__ . '/../collizo4sky/persist-admin-notices-dismissal',
27
+ 'aliases' => array(),
28
+ 'reference' => '900739eb6b0ec0210465f5983a6d4e0e420289e4',
29
+ 'dev_requirement' => false,
30
+ ),
31
+ 'composer/installers' => array(
32
+ 'pretty_version' => 'v1.11.0',
33
+ 'version' => '1.11.0.0',
34
+ 'type' => 'composer-plugin',
35
+ 'install_path' => __DIR__ . '/./installers',
36
+ 'aliases' => array(),
37
+ 'reference' => 'ae03311f45dfe194412081526be2e003960df74b',
38
+ 'dev_requirement' => false,
39
+ ),
40
+ 'loginwp/core' => array(
41
+ 'pretty_version' => '0.1.0-alpha.1631387791',
42
+ 'version' => '0.1.0.0-alpha1631387791',
43
+ 'type' => 'wordpress-plugin',
44
+ 'install_path' => __DIR__ . '/../../src/core',
45
+ 'aliases' => array(),
46
+ 'reference' => '89a37fbca268153e7569a051cf4aac8395f3029b',
47
+ 'dev_requirement' => false,
48
+ ),
49
+ 'roundcube/plugin-installer' => array(
50
+ 'dev_requirement' => false,
51
+ 'replaced' => array(
52
+ 0 => '*',
53
+ ),
54
+ ),
55
+ 'shama/baton' => array(
56
+ 'dev_requirement' => false,
57
+ 'replaced' => array(
58
+ 0 => '*',
59
+ ),
60
+ ),
61
+ ),
62
+ );
vendor/composer/installers/.github/workflows/continuous-integration.yml ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: "Continuous Integration"
2
+
3
+ on:
4
+ - push
5
+ - pull_request
6
+
7
+ env:
8
+ COMPOSER_FLAGS: "--ansi --no-interaction --no-progress --prefer-dist"
9
+ SYMFONY_PHPUNIT_REMOVE_RETURN_TYPEHINT: "1"
10
+
11
+ jobs:
12
+ tests:
13
+ name: "CI"
14
+
15
+ runs-on: ubuntu-latest
16
+
17
+ strategy:
18
+ matrix:
19
+ php-version:
20
+ - "5.3"
21
+ - "5.4"
22
+ - "5.5"
23
+ - "5.6"
24
+ - "7.0"
25
+ - "7.1"
26
+ - "7.2"
27
+ - "7.3"
28
+ - "7.4"
29
+ - "8.0"
30
+ - "8.1"
31
+ dependencies: [locked]
32
+ include:
33
+ - php-version: "5.3"
34
+ dependencies: lowest
35
+ - php-version: "8.1"
36
+ dependencies: lowest
37
+
38
+ steps:
39
+ - name: "Checkout"
40
+ uses: "actions/checkout@v2"
41
+
42
+ - name: "Install PHP"
43
+ uses: "shivammathur/setup-php@v2"
44
+ with:
45
+ coverage: "none"
46
+ php-version: "${{ matrix.php-version }}"
47
+
48
+ - name: Get composer cache directory
49
+ id: composercache
50
+ run: echo "::set-output name=dir::$(composer config cache-files-dir)"
51
+
52
+ - name: Cache dependencies
53
+ uses: actions/cache@v2
54
+ with:
55
+ path: ${{ steps.composercache.outputs.dir }}
56
+ key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
57
+ restore-keys: ${{ runner.os }}-composer-
58
+
59
+ - name: "Handle lowest dependencies update"
60
+ if: "contains(matrix.dependencies, 'lowest')"
61
+ run: "echo \"COMPOSER_FLAGS=$COMPOSER_FLAGS --prefer-lowest\" >> $GITHUB_ENV"
62
+
63
+ - name: "Install latest dependencies"
64
+ run: |
65
+ # Remove PHPStan as it requires a newer PHP
66
+ composer remove phpstan/phpstan phpstan/phpstan-phpunit --dev --no-update
67
+ composer update ${{ env.COMPOSER_FLAGS }}
68
+
69
+ - name: "Run tests"
70
+ run: "vendor/bin/simple-phpunit --verbose"
vendor/composer/installers/.github/workflows/lint.yml ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: "PHP Lint"
2
+
3
+ on:
4
+ - push
5
+ - pull_request
6
+
7
+ jobs:
8
+ tests:
9
+ name: "Lint"
10
+
11
+ runs-on: ubuntu-latest
12
+
13
+ strategy:
14
+ matrix:
15
+ php-version:
16
+ - "5.3"
17
+ - "8.0"
18
+
19
+ steps:
20
+ - name: "Checkout"
21
+ uses: "actions/checkout@v2"
22
+
23
+ - name: "Install PHP"
24
+ uses: "shivammathur/setup-php@v2"
25
+ with:
26
+ coverage: "none"
27
+ php-version: "${{ matrix.php-version }}"
28
+
29
+ - name: "Lint PHP files"
30
+ run: "find src/ -type f -name '*.php' -print0 | xargs -0 -L1 -P4 -- php -l -f"
vendor/composer/installers/.github/workflows/phpstan.yml ADDED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ name: "PHPStan"
2
+
3
+ on:
4
+ - push
5
+ - pull_request
6
+
7
+ env:
8
+ COMPOSER_FLAGS: "--ansi --no-interaction --no-progress --prefer-dist"
9
+ SYMFONY_PHPUNIT_VERSION: ""
10
+
11
+ jobs:
12
+ tests:
13
+ name: "PHPStan"
14
+
15
+ runs-on: ubuntu-latest
16
+
17
+ strategy:
18
+ matrix:
19
+ php-version:
20
+ # pinned to 7.4 because we need PHPUnit 7.5 which does not support PHP 8
21
+ - "7.4"
22
+
23
+ steps:
24
+ - name: "Checkout"
25
+ uses: "actions/checkout@v2"
26
+
27
+ - name: "Install PHP"
28
+ uses: "shivammathur/setup-php@v2"
29
+ with:
30
+ coverage: "none"
31
+ php-version: "${{ matrix.php-version }}"
32
+
33
+ - name: Get composer cache directory
34
+ id: composercache
35
+ run: echo "::set-output name=dir::$(composer config cache-files-dir)"
36
+
37
+ - name: Cache dependencies
38
+ uses: actions/cache@v2
39
+ with:
40
+ path: ${{ steps.composercache.outputs.dir }}
41
+ key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
42
+ restore-keys: ${{ runner.os }}-composer-
43
+
44
+ - name: "Install latest dependencies"
45
+ run: "composer update ${{ env.COMPOSER_FLAGS }}"
46
+
47
+ - name: Run PHPStan
48
+ # Locked to phpunit 7.5 here as newer ones have void return types which break inheritance
49
+ run: |
50
+ composer require --dev phpunit/phpunit:^7.5.20 --with-all-dependencies ${{ env.COMPOSER_FLAGS }}
51
+ vendor/bin/phpstan analyse
vendor/composer/installers/LICENSE ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ Copyright (c) 2012 Kyle Robinson Young
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy
4
+ of this software and associated documentation files (the "Software"), to deal
5
+ in the Software without restriction, including without limitation the rights
6
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
+ copies of the Software, and to permit persons to whom the Software is furnished
8
+ to do so, subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in all
11
+ copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19
+ THE SOFTWARE.
vendor/composer/installers/composer.json ADDED
@@ -0,0 +1,121 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "name": "composer/installers",
3
+ "type": "composer-plugin",
4
+ "license": "MIT",
5
+ "description": "A multi-framework Composer library installer",
6
+ "keywords": [
7
+ "installer",
8
+ "Aimeos",
9
+ "AGL",
10
+ "AnnotateCms",
11
+ "Attogram",
12
+ "Bitrix",
13
+ "CakePHP",
14
+ "Chef",
15
+ "Cockpit",
16
+ "CodeIgniter",
17
+ "concrete5",
18
+ "Craft",
19
+ "Croogo",
20
+ "DokuWiki",
21
+ "Dolibarr",
22
+ "Drupal",
23
+ "Elgg",
24
+ "Eliasis",
25
+ "ExpressionEngine",
26
+ "eZ Platform",
27
+ "FuelPHP",
28
+ "Grav",
29
+ "Hurad",
30
+ "ImageCMS",
31
+ "iTop",
32
+ "Joomla",
33
+ "Kanboard",
34
+ "Known",
35
+ "Kohana",
36
+ "Lan Management System",
37
+ "Laravel",
38
+ "Lavalite",
39
+ "Lithium",
40
+ "Magento",
41
+ "majima",
42
+ "Mako",
43
+ "MantisBT",
44
+ "Mautic",
45
+ "Maya",
46
+ "MODX",
47
+ "MODX Evo",
48
+ "MediaWiki",
49
+ "Miaoxing",
50
+ "OXID",
51
+ "osclass",
52
+ "MODULEWork",
53
+ "Moodle",
54
+ "Piwik",
55
+ "pxcms",
56
+ "phpBB",
57
+ "Plentymarkets",
58
+ "PPI",
59
+ "Puppet",
60
+ "Porto",
61
+ "ProcessWire",
62
+ "RadPHP",
63
+ "ReIndex",
64
+ "Roundcube",
65
+ "shopware",
66
+ "SilverStripe",
67
+ "SMF",
68
+ "Starbug",
69
+ "SyDES",
70
+ "Sylius",
71
+ "symfony",
72
+ "TastyIgniter",
73
+ "Thelia",
74
+ "TYPO3",
75
+ "WHMCS",
76
+ "WolfCMS",
77
+ "WordPress",
78
+ "YAWIK",
79
+ "Zend",
80
+ "Zikula"
81
+ ],
82
+ "homepage": "https://composer.github.io/installers/",
83
+ "authors": [
84
+ {
85
+ "name": "Kyle Robinson Young",
86
+ "email": "kyle@dontkry.com",
87
+ "homepage": "https://github.com/shama"
88
+ }
89
+ ],
90
+ "autoload": {
91
+ "psr-4": { "Composer\\Installers\\": "src/Composer/Installers" }
92
+ },
93
+ "autoload-dev": {
94
+ "psr-4": { "Composer\\Installers\\Test\\": "tests/Composer/Installers/Test" }
95
+ },
96
+ "extra": {
97
+ "class": "Composer\\Installers\\Plugin",
98
+ "branch-alias": {
99
+ "dev-main": "1.x-dev"
100
+ }
101
+ },
102
+ "replace": {
103
+ "shama/baton": "*",
104
+ "roundcube/plugin-installer": "*"
105
+ },
106
+ "require": {
107
+ "composer-plugin-api": "^1.0 || ^2.0"
108
+ },
109
+ "require-dev": {
110
+ "composer/composer": "1.6.* || ^2.0",
111
+ "composer/semver": "^1 || ^3",
112
+ "symfony/phpunit-bridge": "^4.2 || ^5",
113
+ "phpstan/phpstan": "^0.12.55",
114
+ "symfony/process": "^2.3",
115
+ "phpstan/phpstan-phpunit": "^0.12.16"
116
+ },
117
+ "scripts": {
118
+ "test": "SYMFONY_PHPUNIT_REMOVE_RETURN_TYPEHINT=1 vendor/bin/simple-phpunit",
119
+ "phpstan": "vendor/bin/phpstan analyse"
120
+ }
121
+ }
vendor/composer/installers/phpstan.neon.dist ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ parameters:
2
+ level: 5
3
+ paths:
4
+ - src
5
+ - tests
6
+ excludes_analyse:
7
+ - tests/Composer/Installers/Test/PolyfillTestCase.php
8
+
9
+ includes:
10
+ - vendor/phpstan/phpstan-phpunit/extension.neon
vendor/composer/installers/src/Composer/Installers/AglInstaller.php ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class AglInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'More/{$name}/',
8
+ );
9
+
10
+ /**
11
+ * Format package name to CamelCase
12
+ */
13
+ public function inflectPackageVars($vars)
14
+ {
15
+ $vars['name'] = preg_replace_callback('/(?:^|_|-)(.?)/', function ($matches) {
16
+ return strtoupper($matches[1]);
17
+ }, $vars['name']);
18
+
19
+ return $vars;
20
+ }
21
+ }
vendor/composer/installers/src/Composer/Installers/AimeosInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class AimeosInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'extension' => 'ext/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/AnnotateCmsInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class AnnotateCmsInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'addons/modules/{$name}/',
8
+ 'component' => 'addons/components/{$name}/',
9
+ 'service' => 'addons/services/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/AsgardInstaller.php ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class AsgardInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'Modules/{$name}/',
8
+ 'theme' => 'Themes/{$name}/'
9
+ );
10
+
11
+ /**
12
+ * Format package name.
13
+ *
14
+ * For package type asgard-module, cut off a trailing '-plugin' if present.
15
+ *
16
+ * For package type asgard-theme, cut off a trailing '-theme' if present.
17
+ *
18
+ */
19
+ public function inflectPackageVars($vars)
20
+ {
21
+ if ($vars['type'] === 'asgard-module') {
22
+ return $this->inflectPluginVars($vars);
23
+ }
24
+
25
+ if ($vars['type'] === 'asgard-theme') {
26
+ return $this->inflectThemeVars($vars);
27
+ }
28
+
29
+ return $vars;
30
+ }
31
+
32
+ protected function inflectPluginVars($vars)
33
+ {
34
+ $vars['name'] = preg_replace('/-module$/', '', $vars['name']);
35
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
36
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
37
+
38
+ return $vars;
39
+ }
40
+
41
+ protected function inflectThemeVars($vars)
42
+ {
43
+ $vars['name'] = preg_replace('/-theme$/', '', $vars['name']);
44
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
45
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
46
+
47
+ return $vars;
48
+ }
49
+ }
vendor/composer/installers/src/Composer/Installers/AttogramInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class AttogramInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/BaseInstaller.php ADDED
@@ -0,0 +1,137 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ use Composer\IO\IOInterface;
5
+ use Composer\Composer;
6
+ use Composer\Package\PackageInterface;
7
+
8
+ abstract class BaseInstaller
9
+ {
10
+ protected $locations = array();
11
+ protected $composer;
12
+ protected $package;
13
+ protected $io;
14
+
15
+ /**
16
+ * Initializes base installer.
17
+ *
18
+ * @param PackageInterface $package
19
+ * @param Composer $composer
20
+ * @param IOInterface $io
21
+ */
22
+ public function __construct(PackageInterface $package = null, Composer $composer = null, IOInterface $io = null)
23
+ {
24
+ $this->composer = $composer;
25
+ $this->package = $package;
26
+ $this->io = $io;
27
+ }
28
+
29
+ /**
30
+ * Return the install path based on package type.
31
+ *
32
+ * @param PackageInterface $package
33
+ * @param string $frameworkType
34
+ * @return string
35
+ */
36
+ public function getInstallPath(PackageInterface $package, $frameworkType = '')
37
+ {
38
+ $type = $this->package->getType();
39
+
40
+ $prettyName = $this->package->getPrettyName();
41
+ if (strpos($prettyName, '/') !== false) {
42
+ list($vendor, $name) = explode('/', $prettyName);
43
+ } else {
44
+ $vendor = '';
45
+ $name = $prettyName;
46
+ }
47
+
48
+ $availableVars = $this->inflectPackageVars(compact('name', 'vendor', 'type'));
49
+
50
+ $extra = $package->getExtra();
51
+ if (!empty($extra['installer-name'])) {
52
+ $availableVars['name'] = $extra['installer-name'];
53
+ }
54
+
55
+ if ($this->composer->getPackage()) {
56
+ $extra = $this->composer->getPackage()->getExtra();
57
+ if (!empty($extra['installer-paths'])) {
58
+ $customPath = $this->mapCustomInstallPaths($extra['installer-paths'], $prettyName, $type, $vendor);
59
+ if ($customPath !== false) {
60
+ return $this->templatePath($customPath, $availableVars);
61
+ }
62
+ }
63
+ }
64
+
65
+ $packageType = substr($type, strlen($frameworkType) + 1);
66
+ $locations = $this->getLocations();
67
+ if (!isset($locations[$packageType])) {
68
+ throw new \InvalidArgumentException(sprintf('Package type "%s" is not supported', $type));
69
+ }
70
+
71
+ return $this->templatePath($locations[$packageType], $availableVars);
72
+ }
73
+
74
+ /**
75
+ * For an installer to override to modify the vars per installer.
76
+ *
77
+ * @param array<string, string> $vars This will normally receive array{name: string, vendor: string, type: string}
78
+ * @return array<string, string>
79
+ */
80
+ public function inflectPackageVars($vars)
81
+ {
82
+ return $vars;
83
+ }
84
+
85
+ /**
86
+ * Gets the installer's locations
87
+ *
88
+ * @return array<string, string> map of package types => install path
89
+ */
90
+ public function getLocations()
91
+ {
92
+ return $this->locations;
93
+ }
94
+
95
+ /**
96
+ * Replace vars in a path
97
+ *
98
+ * @param string $path
99
+ * @param array<string, string> $vars
100
+ * @return string
101
+ */
102
+ protected function templatePath($path, array $vars = array())
103
+ {
104
+ if (strpos($path, '{') !== false) {
105
+ extract($vars);
106
+ preg_match_all('@\{\$([A-Za-z0-9_]*)\}@i', $path, $matches);
107
+ if (!empty($matches[1])) {
108
+ foreach ($matches[1] as $var) {
109
+ $path = str_replace('{$' . $var . '}', $$var, $path);
110
+ }
111
+ }
112
+ }
113
+
114
+ return $path;
115
+ }
116
+
117
+ /**
118
+ * Search through a passed paths array for a custom install path.
119
+ *
120
+ * @param array $paths
121
+ * @param string $name
122
+ * @param string $type
123
+ * @param string $vendor = NULL
124
+ * @return string|false
125
+ */
126
+ protected function mapCustomInstallPaths(array $paths, $name, $type, $vendor = NULL)
127
+ {
128
+ foreach ($paths as $path => $names) {
129
+ $names = (array) $names;
130
+ if (in_array($name, $names) || in_array('type:' . $type, $names) || in_array('vendor:' . $vendor, $names)) {
131
+ return $path;
132
+ }
133
+ }
134
+
135
+ return false;
136
+ }
137
+ }
vendor/composer/installers/src/Composer/Installers/BitrixInstaller.php ADDED
@@ -0,0 +1,126 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ use Composer\Util\Filesystem;
6
+
7
+ /**
8
+ * Installer for Bitrix Framework. Supported types of extensions:
9
+ * - `bitrix-d7-module` — copy the module to directory `bitrix/modules/<vendor>.<name>`.
10
+ * - `bitrix-d7-component` — copy the component to directory `bitrix/components/<vendor>/<name>`.
11
+ * - `bitrix-d7-template` — copy the template to directory `bitrix/templates/<vendor>_<name>`.
12
+ *
13
+ * You can set custom path to directory with Bitrix kernel in `composer.json`:
14
+ *
15
+ * ```json
16
+ * {
17
+ * "extra": {
18
+ * "bitrix-dir": "s1/bitrix"
19
+ * }
20
+ * }
21
+ * ```
22
+ *
23
+ * @author Nik Samokhvalov <nik@samokhvalov.info>
24
+ * @author Denis Kulichkin <onexhovia@gmail.com>
25
+ */
26
+ class BitrixInstaller extends BaseInstaller
27
+ {
28
+ protected $locations = array(
29
+ 'module' => '{$bitrix_dir}/modules/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
30
+ 'component' => '{$bitrix_dir}/components/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
31
+ 'theme' => '{$bitrix_dir}/templates/{$name}/', // deprecated, remove on the major release (Backward compatibility will be broken)
32
+ 'd7-module' => '{$bitrix_dir}/modules/{$vendor}.{$name}/',
33
+ 'd7-component' => '{$bitrix_dir}/components/{$vendor}/{$name}/',
34
+ 'd7-template' => '{$bitrix_dir}/templates/{$vendor}_{$name}/',
35
+ );
36
+
37
+ /**
38
+ * @var array Storage for informations about duplicates at all the time of installation packages.
39
+ */
40
+ private static $checkedDuplicates = array();
41
+
42
+ /**
43
+ * {@inheritdoc}
44
+ */
45
+ public function inflectPackageVars($vars)
46
+ {
47
+ if ($this->composer->getPackage()) {
48
+ $extra = $this->composer->getPackage()->getExtra();
49
+
50
+ if (isset($extra['bitrix-dir'])) {
51
+ $vars['bitrix_dir'] = $extra['bitrix-dir'];
52
+ }
53
+ }
54
+
55
+ if (!isset($vars['bitrix_dir'])) {
56
+ $vars['bitrix_dir'] = 'bitrix';
57
+ }
58
+
59
+ return parent::inflectPackageVars($vars);
60
+ }
61
+
62
+ /**
63
+ * {@inheritdoc}
64
+ */
65
+ protected function templatePath($path, array $vars = array())
66
+ {
67
+ $templatePath = parent::templatePath($path, $vars);
68
+ $this->checkDuplicates($templatePath, $vars);
69
+
70
+ return $templatePath;
71
+ }
72
+
73
+ /**
74
+ * Duplicates search packages.
75
+ *
76
+ * @param string $path
77
+ * @param array $vars
78
+ */
79
+ protected function checkDuplicates($path, array $vars = array())
80
+ {
81
+ $packageType = substr($vars['type'], strlen('bitrix') + 1);
82
+ $localDir = explode('/', $vars['bitrix_dir']);
83
+ array_pop($localDir);
84
+ $localDir[] = 'local';
85
+ $localDir = implode('/', $localDir);
86
+
87
+ $oldPath = str_replace(
88
+ array('{$bitrix_dir}', '{$name}'),
89
+ array($localDir, $vars['name']),
90
+ $this->locations[$packageType]
91
+ );
92
+
93
+ if (in_array($oldPath, static::$checkedDuplicates)) {
94
+ return;
95
+ }
96
+
97
+ if ($oldPath !== $path && file_exists($oldPath) && $this->io && $this->io->isInteractive()) {
98
+
99
+ $this->io->writeError(' <error>Duplication of packages:</error>');
100
+ $this->io->writeError(' <info>Package ' . $oldPath . ' will be called instead package ' . $path . '</info>');
101
+
102
+ while (true) {
103
+ switch ($this->io->ask(' <info>Delete ' . $oldPath . ' [y,n,?]?</info> ', '?')) {
104
+ case 'y':
105
+ $fs = new Filesystem();
106
+ $fs->removeDirectory($oldPath);
107
+ break 2;
108
+
109
+ case 'n':
110
+ break 2;
111
+
112
+ case '?':
113
+ default:
114
+ $this->io->writeError(array(
115
+ ' y - delete package ' . $oldPath . ' and to continue with the installation',
116
+ ' n - don\'t delete and to continue with the installation',
117
+ ));
118
+ $this->io->writeError(' ? - print help');
119
+ break;
120
+ }
121
+ }
122
+ }
123
+
124
+ static::$checkedDuplicates[] = $oldPath;
125
+ }
126
+ }
vendor/composer/installers/src/Composer/Installers/BonefishInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class BonefishInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'package' => 'Packages/{$vendor}/{$name}/'
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/CakePHPInstaller.php ADDED
@@ -0,0 +1,65 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ use Composer\DependencyResolver\Pool;
5
+ use Composer\Semver\Constraint\Constraint;
6
+
7
+ class CakePHPInstaller extends BaseInstaller
8
+ {
9
+ protected $locations = array(
10
+ 'plugin' => 'Plugin/{$name}/',
11
+ );
12
+
13
+ /**
14
+ * Format package name to CamelCase
15
+ */
16
+ public function inflectPackageVars($vars)
17
+ {
18
+ if ($this->matchesCakeVersion('>=', '3.0.0')) {
19
+ return $vars;
20
+ }
21
+
22
+ $nameParts = explode('/', $vars['name']);
23
+ foreach ($nameParts as &$value) {
24
+ $value = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $value));
25
+ $value = str_replace(array('-', '_'), ' ', $value);
26
+ $value = str_replace(' ', '', ucwords($value));
27
+ }
28
+ $vars['name'] = implode('/', $nameParts);
29
+
30
+ return $vars;
31
+ }
32
+
33
+ /**
34
+ * Change the default plugin location when cakephp >= 3.0
35
+ */
36
+ public function getLocations()
37
+ {
38
+ if ($this->matchesCakeVersion('>=', '3.0.0')) {
39
+ $this->locations['plugin'] = $this->composer->getConfig()->get('vendor-dir') . '/{$vendor}/{$name}/';
40
+ }
41
+ return $this->locations;
42
+ }
43
+
44
+ /**
45
+ * Check if CakePHP version matches against a version
46
+ *
47
+ * @param string $matcher
48
+ * @param string $version
49
+ * @return bool
50
+ */
51
+ protected function matchesCakeVersion($matcher, $version)
52
+ {
53
+ $repositoryManager = $this->composer->getRepositoryManager();
54
+ if (! $repositoryManager) {
55
+ return false;
56
+ }
57
+
58
+ $repos = $repositoryManager->getLocalRepository();
59
+ if (!$repos) {
60
+ return false;
61
+ }
62
+
63
+ return $repos->findPackage('cakephp/cakephp', new Constraint($matcher, $version)) !== null;
64
+ }
65
+ }
vendor/composer/installers/src/Composer/Installers/ChefInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class ChefInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'cookbook' => 'Chef/{$vendor}/{$name}/',
8
+ 'role' => 'Chef/roles/{$name}/',
9
+ );
10
+ }
11
+
vendor/composer/installers/src/Composer/Installers/CiviCrmInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class CiviCrmInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'ext' => 'ext/{$name}/'
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/ClanCatsFrameworkInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class ClanCatsFrameworkInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'ship' => 'CCF/orbit/{$name}/',
8
+ 'theme' => 'CCF/app/themes/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/CockpitInstaller.php ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class CockpitInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'cockpit/modules/addons/{$name}/',
8
+ );
9
+
10
+ /**
11
+ * Format module name.
12
+ *
13
+ * Strip `module-` prefix from package name.
14
+ *
15
+ * {@inheritDoc}
16
+ */
17
+ public function inflectPackageVars($vars)
18
+ {
19
+ if ($vars['type'] == 'cockpit-module') {
20
+ return $this->inflectModuleVars($vars);
21
+ }
22
+
23
+ return $vars;
24
+ }
25
+
26
+ public function inflectModuleVars($vars)
27
+ {
28
+ $vars['name'] = ucfirst(preg_replace('/cockpit-/i', '', $vars['name']));
29
+
30
+ return $vars;
31
+ }
32
+ }
vendor/composer/installers/src/Composer/Installers/CodeIgniterInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class CodeIgniterInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'library' => 'application/libraries/{$name}/',
8
+ 'third-party' => 'application/third_party/{$name}/',
9
+ 'module' => 'application/modules/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/Concrete5Installer.php ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class Concrete5Installer extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'core' => 'concrete/',
8
+ 'block' => 'application/blocks/{$name}/',
9
+ 'package' => 'packages/{$name}/',
10
+ 'theme' => 'application/themes/{$name}/',
11
+ 'update' => 'updates/{$name}/',
12
+ );
13
+ }
vendor/composer/installers/src/Composer/Installers/CraftInstaller.php ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * Installer for Craft Plugins
6
+ */
7
+ class CraftInstaller extends BaseInstaller
8
+ {
9
+ const NAME_PREFIX = 'craft';
10
+ const NAME_SUFFIX = 'plugin';
11
+
12
+ protected $locations = array(
13
+ 'plugin' => 'craft/plugins/{$name}/',
14
+ );
15
+
16
+ /**
17
+ * Strip `craft-` prefix and/or `-plugin` suffix from package names
18
+ *
19
+ * @param array $vars
20
+ *
21
+ * @return array
22
+ */
23
+ final public function inflectPackageVars($vars)
24
+ {
25
+ return $this->inflectPluginVars($vars);
26
+ }
27
+
28
+ private function inflectPluginVars($vars)
29
+ {
30
+ $vars['name'] = preg_replace('/-' . self::NAME_SUFFIX . '$/i', '', $vars['name']);
31
+ $vars['name'] = preg_replace('/^' . self::NAME_PREFIX . '-/i', '', $vars['name']);
32
+
33
+ return $vars;
34
+ }
35
+ }
vendor/composer/installers/src/Composer/Installers/CroogoInstaller.php ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class CroogoInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'Plugin/{$name}/',
8
+ 'theme' => 'View/Themed/{$name}/',
9
+ );
10
+
11
+ /**
12
+ * Format package name to CamelCase
13
+ */
14
+ public function inflectPackageVars($vars)
15
+ {
16
+ $vars['name'] = strtolower(str_replace(array('-', '_'), ' ', $vars['name']));
17
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
18
+
19
+ return $vars;
20
+ }
21
+ }
vendor/composer/installers/src/Composer/Installers/DecibelInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class DecibelInstaller extends BaseInstaller
5
+ {
6
+ /** @var array */
7
+ protected $locations = array(
8
+ 'app' => 'app/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/DframeInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ class DframeInstaller extends BaseInstaller
6
+ {
7
+ protected $locations = array(
8
+ 'module' => 'modules/{$vendor}/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/DokuWikiInstaller.php ADDED
@@ -0,0 +1,50 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class DokuWikiInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'lib/plugins/{$name}/',
8
+ 'template' => 'lib/tpl/{$name}/',
9
+ );
10
+
11
+ /**
12
+ * Format package name.
13
+ *
14
+ * For package type dokuwiki-plugin, cut off a trailing '-plugin',
15
+ * or leading dokuwiki_ if present.
16
+ *
17
+ * For package type dokuwiki-template, cut off a trailing '-template' if present.
18
+ *
19
+ */
20
+ public function inflectPackageVars($vars)
21
+ {
22
+
23
+ if ($vars['type'] === 'dokuwiki-plugin') {
24
+ return $this->inflectPluginVars($vars);
25
+ }
26
+
27
+ if ($vars['type'] === 'dokuwiki-template') {
28
+ return $this->inflectTemplateVars($vars);
29
+ }
30
+
31
+ return $vars;
32
+ }
33
+
34
+ protected function inflectPluginVars($vars)
35
+ {
36
+ $vars['name'] = preg_replace('/-plugin$/', '', $vars['name']);
37
+ $vars['name'] = preg_replace('/^dokuwiki_?-?/', '', $vars['name']);
38
+
39
+ return $vars;
40
+ }
41
+
42
+ protected function inflectTemplateVars($vars)
43
+ {
44
+ $vars['name'] = preg_replace('/-template$/', '', $vars['name']);
45
+ $vars['name'] = preg_replace('/^dokuwiki_?-?/', '', $vars['name']);
46
+
47
+ return $vars;
48
+ }
49
+
50
+ }
vendor/composer/installers/src/Composer/Installers/DolibarrInstaller.php ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * Class DolibarrInstaller
6
+ *
7
+ * @package Composer\Installers
8
+ * @author Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
9
+ */
10
+ class DolibarrInstaller extends BaseInstaller
11
+ {
12
+ //TODO: Add support for scripts and themes
13
+ protected $locations = array(
14
+ 'module' => 'htdocs/custom/{$name}/',
15
+ );
16
+ }
vendor/composer/installers/src/Composer/Installers/DrupalInstaller.php ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class DrupalInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'core' => 'core/',
8
+ 'module' => 'modules/{$name}/',
9
+ 'theme' => 'themes/{$name}/',
10
+ 'library' => 'libraries/{$name}/',
11
+ 'profile' => 'profiles/{$name}/',
12
+ 'database-driver' => 'drivers/lib/Drupal/Driver/Database/{$name}/',
13
+ 'drush' => 'drush/{$name}/',
14
+ 'custom-theme' => 'themes/custom/{$name}/',
15
+ 'custom-module' => 'modules/custom/{$name}/',
16
+ 'custom-profile' => 'profiles/custom/{$name}/',
17
+ 'drupal-multisite' => 'sites/{$name}/',
18
+ 'console' => 'console/{$name}/',
19
+ 'console-language' => 'console/language/{$name}/',
20
+ 'config' => 'config/sync/',
21
+ );
22
+ }
vendor/composer/installers/src/Composer/Installers/ElggInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class ElggInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'mod/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/EliasisInstaller.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class EliasisInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'component' => 'components/{$name}/',
8
+ 'module' => 'modules/{$name}/',
9
+ 'plugin' => 'plugins/{$name}/',
10
+ 'template' => 'templates/{$name}/',
11
+ );
12
+ }
vendor/composer/installers/src/Composer/Installers/ExpressionEngineInstaller.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ use Composer\Package\PackageInterface;
5
+
6
+ class ExpressionEngineInstaller extends BaseInstaller
7
+ {
8
+
9
+ protected $locations = array();
10
+
11
+ private $ee2Locations = array(
12
+ 'addon' => 'system/expressionengine/third_party/{$name}/',
13
+ 'theme' => 'themes/third_party/{$name}/',
14
+ );
15
+
16
+ private $ee3Locations = array(
17
+ 'addon' => 'system/user/addons/{$name}/',
18
+ 'theme' => 'themes/user/{$name}/',
19
+ );
20
+
21
+ public function getInstallPath(PackageInterface $package, $frameworkType = '')
22
+ {
23
+
24
+ $version = "{$frameworkType}Locations";
25
+ $this->locations = $this->$version;
26
+
27
+ return parent::getInstallPath($package, $frameworkType);
28
+ }
29
+ }
vendor/composer/installers/src/Composer/Installers/EzPlatformInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class EzPlatformInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'meta-assets' => 'web/assets/ezplatform/',
8
+ 'assets' => 'web/assets/ezplatform/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/FuelInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class FuelInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'fuel/app/modules/{$name}/',
8
+ 'package' => 'fuel/packages/{$name}/',
9
+ 'theme' => 'fuel/app/themes/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/FuelphpInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class FuelphpInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'component' => 'components/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/GravInstaller.php ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class GravInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'user/plugins/{$name}/',
8
+ 'theme' => 'user/themes/{$name}/',
9
+ );
10
+
11
+ /**
12
+ * Format package name
13
+ *
14
+ * @param array $vars
15
+ *
16
+ * @return array
17
+ */
18
+ public function inflectPackageVars($vars)
19
+ {
20
+ $restrictedWords = implode('|', array_keys($this->locations));
21
+
22
+ $vars['name'] = strtolower($vars['name']);
23
+ $vars['name'] = preg_replace('/^(?:grav-)?(?:(?:'.$restrictedWords.')-)?(.*?)(?:-(?:'.$restrictedWords.'))?$/ui',
24
+ '$1',
25
+ $vars['name']
26
+ );
27
+
28
+ return $vars;
29
+ }
30
+ }
vendor/composer/installers/src/Composer/Installers/HuradInstaller.php ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class HuradInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'plugins/{$name}/',
8
+ 'theme' => 'plugins/{$name}/',
9
+ );
10
+
11
+ /**
12
+ * Format package name to CamelCase
13
+ */
14
+ public function inflectPackageVars($vars)
15
+ {
16
+ $nameParts = explode('/', $vars['name']);
17
+ foreach ($nameParts as &$value) {
18
+ $value = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $value));
19
+ $value = str_replace(array('-', '_'), ' ', $value);
20
+ $value = str_replace(' ', '', ucwords($value));
21
+ }
22
+ $vars['name'] = implode('/', $nameParts);
23
+ return $vars;
24
+ }
25
+ }
vendor/composer/installers/src/Composer/Installers/ImageCMSInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class ImageCMSInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'template' => 'templates/{$name}/',
8
+ 'module' => 'application/modules/{$name}/',
9
+ 'library' => 'application/libraries/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/Installer.php ADDED
@@ -0,0 +1,297 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ use Composer\Composer;
6
+ use Composer\Installer\BinaryInstaller;
7
+ use Composer\Installer\LibraryInstaller;
8
+ use Composer\IO\IOInterface;
9
+ use Composer\Package\PackageInterface;
10
+ use Composer\Repository\InstalledRepositoryInterface;
11
+ use Composer\Util\Filesystem;
12
+ use React\Promise\PromiseInterface;
13
+
14
+ class Installer extends LibraryInstaller
15
+ {
16
+
17
+ /**
18
+ * Package types to installer class map
19
+ *
20
+ * @var array
21
+ */
22
+ private $supportedTypes = array(
23
+ 'aimeos' => 'AimeosInstaller',
24
+ 'asgard' => 'AsgardInstaller',
25
+ 'attogram' => 'AttogramInstaller',
26
+ 'agl' => 'AglInstaller',
27
+ 'annotatecms' => 'AnnotateCmsInstaller',
28
+ 'bitrix' => 'BitrixInstaller',
29
+ 'bonefish' => 'BonefishInstaller',
30
+ 'cakephp' => 'CakePHPInstaller',
31
+ 'chef' => 'ChefInstaller',
32
+ 'civicrm' => 'CiviCrmInstaller',
33
+ 'ccframework' => 'ClanCatsFrameworkInstaller',
34
+ 'cockpit' => 'CockpitInstaller',
35
+ 'codeigniter' => 'CodeIgniterInstaller',
36
+ 'concrete5' => 'Concrete5Installer',
37
+ 'craft' => 'CraftInstaller',
38
+ 'croogo' => 'CroogoInstaller',
39
+ 'dframe' => 'DframeInstaller',
40
+ 'dokuwiki' => 'DokuWikiInstaller',
41
+ 'dolibarr' => 'DolibarrInstaller',
42
+ 'decibel' => 'DecibelInstaller',
43
+ 'drupal' => 'DrupalInstaller',
44
+ 'elgg' => 'ElggInstaller',
45
+ 'eliasis' => 'EliasisInstaller',
46
+ 'ee3' => 'ExpressionEngineInstaller',
47
+ 'ee2' => 'ExpressionEngineInstaller',
48
+ 'ezplatform' => 'EzPlatformInstaller',
49
+ 'fuel' => 'FuelInstaller',
50
+ 'fuelphp' => 'FuelphpInstaller',
51
+ 'grav' => 'GravInstaller',
52
+ 'hurad' => 'HuradInstaller',
53
+ 'tastyigniter' => 'TastyIgniterInstaller',
54
+ 'imagecms' => 'ImageCMSInstaller',
55
+ 'itop' => 'ItopInstaller',
56
+ 'joomla' => 'JoomlaInstaller',
57
+ 'kanboard' => 'KanboardInstaller',
58
+ 'kirby' => 'KirbyInstaller',
59
+ 'known' => 'KnownInstaller',
60
+ 'kodicms' => 'KodiCMSInstaller',
61
+ 'kohana' => 'KohanaInstaller',
62
+ 'lms' => 'LanManagementSystemInstaller',
63
+ 'laravel' => 'LaravelInstaller',
64
+ 'lavalite' => 'LavaLiteInstaller',
65
+ 'lithium' => 'LithiumInstaller',
66
+ 'magento' => 'MagentoInstaller',
67
+ 'majima' => 'MajimaInstaller',
68
+ 'mantisbt' => 'MantisBTInstaller',
69
+ 'mako' => 'MakoInstaller',
70
+ 'maya' => 'MayaInstaller',
71
+ 'mautic' => 'MauticInstaller',
72
+ 'mediawiki' => 'MediaWikiInstaller',
73
+ 'miaoxing' => 'MiaoxingInstaller',
74
+ 'microweber' => 'MicroweberInstaller',
75
+ 'modulework' => 'MODULEWorkInstaller',
76
+ 'modx' => 'ModxInstaller',
77
+ 'modxevo' => 'MODXEvoInstaller',
78
+ 'moodle' => 'MoodleInstaller',
79
+ 'october' => 'OctoberInstaller',
80
+ 'ontowiki' => 'OntoWikiInstaller',
81
+ 'oxid' => 'OxidInstaller',
82
+ 'osclass' => 'OsclassInstaller',
83
+ 'pxcms' => 'PxcmsInstaller',
84
+ 'phpbb' => 'PhpBBInstaller',
85
+ 'pimcore' => 'PimcoreInstaller',
86
+ 'piwik' => 'PiwikInstaller',
87
+ 'plentymarkets'=> 'PlentymarketsInstaller',
88
+ 'ppi' => 'PPIInstaller',
89
+ 'puppet' => 'PuppetInstaller',
90
+ 'radphp' => 'RadPHPInstaller',
91
+ 'phifty' => 'PhiftyInstaller',
92
+ 'porto' => 'PortoInstaller',
93
+ 'processwire' => 'ProcessWireInstaller',
94
+ 'redaxo' => 'RedaxoInstaller',
95
+ 'redaxo5' => 'Redaxo5Installer',
96
+ 'reindex' => 'ReIndexInstaller',
97
+ 'roundcube' => 'RoundcubeInstaller',
98
+ 'shopware' => 'ShopwareInstaller',
99
+ 'sitedirect' => 'SiteDirectInstaller',
100
+ 'silverstripe' => 'SilverStripeInstaller',
101
+ 'smf' => 'SMFInstaller',
102
+ 'starbug' => 'StarbugInstaller',
103
+ 'sydes' => 'SyDESInstaller',
104
+ 'sylius' => 'SyliusInstaller',
105
+ 'symfony1' => 'Symfony1Installer',
106
+ 'tao' => 'TaoInstaller',
107
+ 'thelia' => 'TheliaInstaller',
108
+ 'tusk' => 'TuskInstaller',
109
+ 'typo3-cms' => 'TYPO3CmsInstaller',
110
+ 'typo3-flow' => 'TYPO3FlowInstaller',
111
+ 'userfrosting' => 'UserFrostingInstaller',
112
+ 'vanilla' => 'VanillaInstaller',
113
+ 'whmcs' => 'WHMCSInstaller',
114
+ 'winter' => 'WinterInstaller',
115
+ 'wolfcms' => 'WolfCMSInstaller',
116
+ 'wordpress' => 'WordPressInstaller',
117
+ 'yawik' => 'YawikInstaller',
118
+ 'zend' => 'ZendInstaller',
119
+ 'zikula' => 'ZikulaInstaller',
120
+ 'prestashop' => 'PrestashopInstaller'
121
+ );
122
+
123
+ /**
124
+ * Installer constructor.
125
+ *
126
+ * Disables installers specified in main composer extra installer-disable
127
+ * list
128
+ *
129
+ * @param IOInterface $io
130
+ * @param Composer $composer
131
+ * @param string $type
132
+ * @param Filesystem|null $filesystem
133
+ * @param BinaryInstaller|null $binaryInstaller
134
+ */
135
+ public function __construct(
136
+ IOInterface $io,
137
+ Composer $composer,
138
+ $type = 'library',
139
+ Filesystem $filesystem = null,
140
+ BinaryInstaller $binaryInstaller = null
141
+ ) {
142
+ parent::__construct($io, $composer, $type, $filesystem,
143
+ $binaryInstaller);
144
+ $this->removeDisabledInstallers();
145
+ }
146
+
147
+ /**
148
+ * {@inheritDoc}
149
+ */
150
+ public function getInstallPath(PackageInterface $package)
151
+ {
152
+ $type = $package->getType();
153
+ $frameworkType = $this->findFrameworkType($type);
154
+
155
+ if ($frameworkType === false) {
156
+ throw new \InvalidArgumentException(
157
+ 'Sorry the package type of this package is not yet supported.'
158
+ );
159
+ }
160
+
161
+ $class = 'Composer\\Installers\\' . $this->supportedTypes[$frameworkType];
162
+ $installer = new $class($package, $this->composer, $this->getIO());
163
+
164
+ return $installer->getInstallPath($package, $frameworkType);
165
+ }
166
+
167
+ public function uninstall(InstalledRepositoryInterface $repo, PackageInterface $package)
168
+ {
169
+ $installPath = $this->getPackageBasePath($package);
170
+ $io = $this->io;
171
+ $outputStatus = function () use ($io, $installPath) {
172
+ $io->write(sprintf('Deleting %s - %s', $installPath, !file_exists($installPath) ? '<comment>deleted</comment>' : '<error>not deleted</error>'));
173
+ };
174
+
175
+ $promise = parent::uninstall($repo, $package);
176
+
177
+ // Composer v2 might return a promise here
178
+ if ($promise instanceof PromiseInterface) {
179
+ return $promise->then($outputStatus);
180
+ }
181
+
182
+ // If not, execute the code right away as parent::uninstall executed synchronously (composer v1, or v2 without async)
183
+ $outputStatus();
184
+
185
+ return null;
186
+ }
187
+
188
+ /**
189
+ * {@inheritDoc}
190
+ */
191
+ public function supports($packageType)
192
+ {
193
+ $frameworkType = $this->findFrameworkType($packageType);
194
+
195
+ if ($frameworkType === false) {
196
+ return false;
197
+ }
198
+
199
+ $locationPattern = $this->getLocationPattern($frameworkType);
200
+
201
+ return preg_match('#' . $frameworkType . '-' . $locationPattern . '#', $packageType, $matches) === 1;
202
+ }
203
+
204
+ /**
205
+ * Finds a supported framework type if it exists and returns it
206
+ *
207
+ * @param string $type
208
+ * @return string|false
209
+ */
210
+ protected function findFrameworkType($type)
211
+ {
212
+ krsort($this->supportedTypes);
213
+
214
+ foreach ($this->supportedTypes as $key => $val) {
215
+ if ($key === substr($type, 0, strlen($key))) {
216
+ return substr($type, 0, strlen($key));
217
+ }
218
+ }
219
+
220
+ return false;
221
+ }
222
+
223
+ /**
224
+ * Get the second part of the regular expression to check for support of a
225
+ * package type
226
+ *
227
+ * @param string $frameworkType
228
+ * @return string
229
+ */
230
+ protected function getLocationPattern($frameworkType)
231
+ {
232
+ $pattern = false;
233
+ if (!empty($this->supportedTypes[$frameworkType])) {
234
+ $frameworkClass = 'Composer\\Installers\\' . $this->supportedTypes[$frameworkType];
235
+ /** @var BaseInstaller $framework */
236
+ $framework = new $frameworkClass(null, $this->composer, $this->getIO());
237
+ $locations = array_keys($framework->getLocations());
238
+ $pattern = $locations ? '(' . implode('|', $locations) . ')' : false;
239
+ }
240
+
241
+ return $pattern ? : '(\w+)';
242
+ }
243
+
244
+ /**
245
+ * Get I/O object
246
+ *
247
+ * @return IOInterface
248
+ */
249
+ private function getIO()
250
+ {
251
+ return $this->io;
252
+ }
253
+
254
+ /**
255
+ * Look for installers set to be disabled in composer's extra config and
256
+ * remove them from the list of supported installers.
257
+ *
258
+ * Globals:
259
+ * - true, "all", and "*" - disable all installers.
260
+ * - false - enable all installers (useful with
261
+ * wikimedia/composer-merge-plugin or similar)
262
+ *
263
+ * @return void
264
+ */
265
+ protected function removeDisabledInstallers()
266
+ {
267
+ $extra = $this->composer->getPackage()->getExtra();
268
+
269
+ if (!isset($extra['installer-disable']) || $extra['installer-disable'] === false) {
270
+ // No installers are disabled
271
+ return;
272
+ }
273
+
274
+ // Get installers to disable
275
+ $disable = $extra['installer-disable'];
276
+
277
+ // Ensure $disabled is an array
278
+ if (!is_array($disable)) {
279
+ $disable = array($disable);
280
+ }
281
+
282
+ // Check which installers should be disabled
283
+ $all = array(true, "all", "*");
284
+ $intersect = array_intersect($all, $disable);
285
+ if (!empty($intersect)) {
286
+ // Disable all installers
287
+ $this->supportedTypes = array();
288
+ } else {
289
+ // Disable specified installers
290
+ foreach ($disable as $key => $installer) {
291
+ if (is_string($installer) && key_exists($installer, $this->supportedTypes)) {
292
+ unset($this->supportedTypes[$installer]);
293
+ }
294
+ }
295
+ }
296
+ }
297
+ }
vendor/composer/installers/src/Composer/Installers/ItopInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class ItopInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'extension' => 'extensions/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/JoomlaInstaller.php ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class JoomlaInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'component' => 'components/{$name}/',
8
+ 'module' => 'modules/{$name}/',
9
+ 'template' => 'templates/{$name}/',
10
+ 'plugin' => 'plugins/{$name}/',
11
+ 'library' => 'libraries/{$name}/',
12
+ );
13
+
14
+ // TODO: Add inflector for mod_ and com_ names
15
+ }
vendor/composer/installers/src/Composer/Installers/KanboardInstaller.php ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ *
6
+ * Installer for kanboard plugins
7
+ *
8
+ * kanboard.net
9
+ *
10
+ * Class KanboardInstaller
11
+ * @package Composer\Installers
12
+ */
13
+ class KanboardInstaller extends BaseInstaller
14
+ {
15
+ protected $locations = array(
16
+ 'plugin' => 'plugins/{$name}/',
17
+ );
18
+ }
vendor/composer/installers/src/Composer/Installers/KirbyInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class KirbyInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'site/plugins/{$name}/',
8
+ 'field' => 'site/fields/{$name}/',
9
+ 'tag' => 'site/tags/{$name}/'
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/KnownInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class KnownInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'IdnoPlugins/{$name}/',
8
+ 'theme' => 'Themes/{$name}/',
9
+ 'console' => 'ConsolePlugins/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/KodiCMSInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class KodiCMSInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'cms/plugins/{$name}/',
8
+ 'media' => 'cms/media/vendor/{$name}/'
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/KohanaInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class KohanaInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/LanManagementSystemInstaller.php ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ class LanManagementSystemInstaller extends BaseInstaller
6
+ {
7
+
8
+ protected $locations = array(
9
+ 'plugin' => 'plugins/{$name}/',
10
+ 'template' => 'templates/{$name}/',
11
+ 'document-template' => 'documents/templates/{$name}/',
12
+ 'userpanel-module' => 'userpanel/modules/{$name}/',
13
+ );
14
+
15
+ /**
16
+ * Format package name to CamelCase
17
+ */
18
+ public function inflectPackageVars($vars)
19
+ {
20
+ $vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
21
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
22
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
23
+
24
+ return $vars;
25
+ }
26
+
27
+ }
vendor/composer/installers/src/Composer/Installers/LaravelInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class LaravelInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'library' => 'libraries/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/LavaLiteInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class LavaLiteInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'package' => 'packages/{$vendor}/{$name}/',
8
+ 'theme' => 'public/themes/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/LithiumInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class LithiumInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'library' => 'libraries/{$name}/',
8
+ 'source' => 'libraries/_source/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/MODULEWorkInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class MODULEWorkInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/MODXEvoInstaller.php ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * An installer to handle MODX Evolution specifics when installing packages.
6
+ */
7
+ class MODXEvoInstaller extends BaseInstaller
8
+ {
9
+ protected $locations = array(
10
+ 'snippet' => 'assets/snippets/{$name}/',
11
+ 'plugin' => 'assets/plugins/{$name}/',
12
+ 'module' => 'assets/modules/{$name}/',
13
+ 'template' => 'assets/templates/{$name}/',
14
+ 'lib' => 'assets/lib/{$name}/'
15
+ );
16
+ }
vendor/composer/installers/src/Composer/Installers/MagentoInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class MagentoInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'theme' => 'app/design/frontend/{$name}/',
8
+ 'skin' => 'skin/frontend/default/{$name}/',
9
+ 'library' => 'lib/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/MajimaInstaller.php ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * Plugin/theme installer for majima
6
+ * @author David Neustadt
7
+ */
8
+ class MajimaInstaller extends BaseInstaller
9
+ {
10
+ protected $locations = array(
11
+ 'plugin' => 'plugins/{$name}/',
12
+ );
13
+
14
+ /**
15
+ * Transforms the names
16
+ * @param array $vars
17
+ * @return array
18
+ */
19
+ public function inflectPackageVars($vars)
20
+ {
21
+ return $this->correctPluginName($vars);
22
+ }
23
+
24
+ /**
25
+ * Change hyphenated names to camelcase
26
+ * @param array $vars
27
+ * @return array
28
+ */
29
+ private function correctPluginName($vars)
30
+ {
31
+ $camelCasedName = preg_replace_callback('/(-[a-z])/', function ($matches) {
32
+ return strtoupper($matches[0][1]);
33
+ }, $vars['name']);
34
+ $vars['name'] = ucfirst($camelCasedName);
35
+ return $vars;
36
+ }
37
+ }
vendor/composer/installers/src/Composer/Installers/MakoInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class MakoInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'package' => 'app/packages/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/MantisBTInstaller.php ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ use Composer\DependencyResolver\Pool;
5
+
6
+ class MantisBTInstaller extends BaseInstaller
7
+ {
8
+ protected $locations = array(
9
+ 'plugin' => 'plugins/{$name}/',
10
+ );
11
+
12
+ /**
13
+ * Format package name to CamelCase
14
+ */
15
+ public function inflectPackageVars($vars)
16
+ {
17
+ $vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
18
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
19
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
20
+
21
+ return $vars;
22
+ }
23
+ }
vendor/composer/installers/src/Composer/Installers/MauticInstaller.php ADDED
@@ -0,0 +1,48 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ use Composer\Package\PackageInterface;
5
+
6
+ class MauticInstaller extends BaseInstaller
7
+ {
8
+ protected $locations = array(
9
+ 'plugin' => 'plugins/{$name}/',
10
+ 'theme' => 'themes/{$name}/',
11
+ 'core' => 'app/',
12
+ );
13
+
14
+ private function getDirectoryName()
15
+ {
16
+ $extra = $this->package->getExtra();
17
+ if (!empty($extra['install-directory-name'])) {
18
+ return $extra['install-directory-name'];
19
+ }
20
+
21
+ return $this->toCamelCase($this->package->getPrettyName());
22
+ }
23
+
24
+ /**
25
+ * @param string $packageName
26
+ *
27
+ * @return string
28
+ */
29
+ private function toCamelCase($packageName)
30
+ {
31
+ return str_replace(' ', '', ucwords(str_replace('-', ' ', basename($packageName))));
32
+ }
33
+
34
+ /**
35
+ * Format package name of mautic-plugins to CamelCase
36
+ */
37
+ public function inflectPackageVars($vars)
38
+ {
39
+
40
+ if ($vars['type'] == 'mautic-plugin' || $vars['type'] == 'mautic-theme') {
41
+ $directoryName = $this->getDirectoryName();
42
+ $vars['name'] = $directoryName;
43
+ }
44
+
45
+ return $vars;
46
+ }
47
+
48
+ }
vendor/composer/installers/src/Composer/Installers/MayaInstaller.php ADDED
@@ -0,0 +1,33 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class MayaInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ );
9
+
10
+ /**
11
+ * Format package name.
12
+ *
13
+ * For package type maya-module, cut off a trailing '-module' if present.
14
+ *
15
+ */
16
+ public function inflectPackageVars($vars)
17
+ {
18
+ if ($vars['type'] === 'maya-module') {
19
+ return $this->inflectModuleVars($vars);
20
+ }
21
+
22
+ return $vars;
23
+ }
24
+
25
+ protected function inflectModuleVars($vars)
26
+ {
27
+ $vars['name'] = preg_replace('/-module$/', '', $vars['name']);
28
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
29
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
30
+
31
+ return $vars;
32
+ }
33
+ }
vendor/composer/installers/src/Composer/Installers/MediaWikiInstaller.php ADDED
@@ -0,0 +1,51 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class MediaWikiInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'core' => 'core/',
8
+ 'extension' => 'extensions/{$name}/',
9
+ 'skin' => 'skins/{$name}/',
10
+ );
11
+
12
+ /**
13
+ * Format package name.
14
+ *
15
+ * For package type mediawiki-extension, cut off a trailing '-extension' if present and transform
16
+ * to CamelCase keeping existing uppercase chars.
17
+ *
18
+ * For package type mediawiki-skin, cut off a trailing '-skin' if present.
19
+ *
20
+ */
21
+ public function inflectPackageVars($vars)
22
+ {
23
+
24
+ if ($vars['type'] === 'mediawiki-extension') {
25
+ return $this->inflectExtensionVars($vars);
26
+ }
27
+
28
+ if ($vars['type'] === 'mediawiki-skin') {
29
+ return $this->inflectSkinVars($vars);
30
+ }
31
+
32
+ return $vars;
33
+ }
34
+
35
+ protected function inflectExtensionVars($vars)
36
+ {
37
+ $vars['name'] = preg_replace('/-extension$/', '', $vars['name']);
38
+ $vars['name'] = str_replace('-', ' ', $vars['name']);
39
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
40
+
41
+ return $vars;
42
+ }
43
+
44
+ protected function inflectSkinVars($vars)
45
+ {
46
+ $vars['name'] = preg_replace('/-skin$/', '', $vars['name']);
47
+
48
+ return $vars;
49
+ }
50
+
51
+ }
vendor/composer/installers/src/Composer/Installers/MiaoxingInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ class MiaoxingInstaller extends BaseInstaller
6
+ {
7
+ protected $locations = array(
8
+ 'plugin' => 'plugins/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/MicroweberInstaller.php ADDED
@@ -0,0 +1,119 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class MicroweberInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'userfiles/modules/{$install_item_dir}/',
8
+ 'module-skin' => 'userfiles/modules/{$install_item_dir}/templates/',
9
+ 'template' => 'userfiles/templates/{$install_item_dir}/',
10
+ 'element' => 'userfiles/elements/{$install_item_dir}/',
11
+ 'vendor' => 'vendor/{$install_item_dir}/',
12
+ 'components' => 'components/{$install_item_dir}/'
13
+ );
14
+
15
+ /**
16
+ * Format package name.
17
+ *
18
+ * For package type microweber-module, cut off a trailing '-module' if present
19
+ *
20
+ * For package type microweber-template, cut off a trailing '-template' if present.
21
+ *
22
+ */
23
+ public function inflectPackageVars($vars)
24
+ {
25
+
26
+
27
+ if ($this->package->getTargetDir()) {
28
+ $vars['install_item_dir'] = $this->package->getTargetDir();
29
+ } else {
30
+ $vars['install_item_dir'] = $vars['name'];
31
+ if ($vars['type'] === 'microweber-template') {
32
+ return $this->inflectTemplateVars($vars);
33
+ }
34
+ if ($vars['type'] === 'microweber-templates') {
35
+ return $this->inflectTemplatesVars($vars);
36
+ }
37
+ if ($vars['type'] === 'microweber-core') {
38
+ return $this->inflectCoreVars($vars);
39
+ }
40
+ if ($vars['type'] === 'microweber-adapter') {
41
+ return $this->inflectCoreVars($vars);
42
+ }
43
+ if ($vars['type'] === 'microweber-module') {
44
+ return $this->inflectModuleVars($vars);
45
+ }
46
+ if ($vars['type'] === 'microweber-modules') {
47
+ return $this->inflectModulesVars($vars);
48
+ }
49
+ if ($vars['type'] === 'microweber-skin') {
50
+ return $this->inflectSkinVars($vars);
51
+ }
52
+ if ($vars['type'] === 'microweber-element' or $vars['type'] === 'microweber-elements') {
53
+ return $this->inflectElementVars($vars);
54
+ }
55
+ }
56
+
57
+
58
+ return $vars;
59
+ }
60
+
61
+ protected function inflectTemplateVars($vars)
62
+ {
63
+ $vars['install_item_dir'] = preg_replace('/-template$/', '', $vars['install_item_dir']);
64
+ $vars['install_item_dir'] = preg_replace('/template-$/', '', $vars['install_item_dir']);
65
+
66
+ return $vars;
67
+ }
68
+
69
+ protected function inflectTemplatesVars($vars)
70
+ {
71
+ $vars['install_item_dir'] = preg_replace('/-templates$/', '', $vars['install_item_dir']);
72
+ $vars['install_item_dir'] = preg_replace('/templates-$/', '', $vars['install_item_dir']);
73
+
74
+ return $vars;
75
+ }
76
+
77
+ protected function inflectCoreVars($vars)
78
+ {
79
+ $vars['install_item_dir'] = preg_replace('/-providers$/', '', $vars['install_item_dir']);
80
+ $vars['install_item_dir'] = preg_replace('/-provider$/', '', $vars['install_item_dir']);
81
+ $vars['install_item_dir'] = preg_replace('/-adapter$/', '', $vars['install_item_dir']);
82
+
83
+ return $vars;
84
+ }
85
+
86
+ protected function inflectModuleVars($vars)
87
+ {
88
+ $vars['install_item_dir'] = preg_replace('/-module$/', '', $vars['install_item_dir']);
89
+ $vars['install_item_dir'] = preg_replace('/module-$/', '', $vars['install_item_dir']);
90
+
91
+ return $vars;
92
+ }
93
+
94
+ protected function inflectModulesVars($vars)
95
+ {
96
+ $vars['install_item_dir'] = preg_replace('/-modules$/', '', $vars['install_item_dir']);
97
+ $vars['install_item_dir'] = preg_replace('/modules-$/', '', $vars['install_item_dir']);
98
+
99
+ return $vars;
100
+ }
101
+
102
+ protected function inflectSkinVars($vars)
103
+ {
104
+ $vars['install_item_dir'] = preg_replace('/-skin$/', '', $vars['install_item_dir']);
105
+ $vars['install_item_dir'] = preg_replace('/skin-$/', '', $vars['install_item_dir']);
106
+
107
+ return $vars;
108
+ }
109
+
110
+ protected function inflectElementVars($vars)
111
+ {
112
+ $vars['install_item_dir'] = preg_replace('/-elements$/', '', $vars['install_item_dir']);
113
+ $vars['install_item_dir'] = preg_replace('/elements-$/', '', $vars['install_item_dir']);
114
+ $vars['install_item_dir'] = preg_replace('/-element$/', '', $vars['install_item_dir']);
115
+ $vars['install_item_dir'] = preg_replace('/element-$/', '', $vars['install_item_dir']);
116
+
117
+ return $vars;
118
+ }
119
+ }
vendor/composer/installers/src/Composer/Installers/ModxInstaller.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * An installer to handle MODX specifics when installing packages.
6
+ */
7
+ class ModxInstaller extends BaseInstaller
8
+ {
9
+ protected $locations = array(
10
+ 'extra' => 'core/packages/{$name}/'
11
+ );
12
+ }
vendor/composer/installers/src/Composer/Installers/MoodleInstaller.php ADDED
@@ -0,0 +1,59 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class MoodleInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'mod' => 'mod/{$name}/',
8
+ 'admin_report' => 'admin/report/{$name}/',
9
+ 'atto' => 'lib/editor/atto/plugins/{$name}/',
10
+ 'tool' => 'admin/tool/{$name}/',
11
+ 'assignment' => 'mod/assignment/type/{$name}/',
12
+ 'assignsubmission' => 'mod/assign/submission/{$name}/',
13
+ 'assignfeedback' => 'mod/assign/feedback/{$name}/',
14
+ 'auth' => 'auth/{$name}/',
15
+ 'availability' => 'availability/condition/{$name}/',
16
+ 'block' => 'blocks/{$name}/',
17
+ 'booktool' => 'mod/book/tool/{$name}/',
18
+ 'cachestore' => 'cache/stores/{$name}/',
19
+ 'cachelock' => 'cache/locks/{$name}/',
20
+ 'calendartype' => 'calendar/type/{$name}/',
21
+ 'fileconverter' => 'files/converter/{$name}/',
22
+ 'format' => 'course/format/{$name}/',
23
+ 'coursereport' => 'course/report/{$name}/',
24
+ 'customcertelement' => 'mod/customcert/element/{$name}/',
25
+ 'datafield' => 'mod/data/field/{$name}/',
26
+ 'datapreset' => 'mod/data/preset/{$name}/',
27
+ 'editor' => 'lib/editor/{$name}/',
28
+ 'enrol' => 'enrol/{$name}/',
29
+ 'filter' => 'filter/{$name}/',
30
+ 'gradeexport' => 'grade/export/{$name}/',
31
+ 'gradeimport' => 'grade/import/{$name}/',
32
+ 'gradereport' => 'grade/report/{$name}/',
33
+ 'gradingform' => 'grade/grading/form/{$name}/',
34
+ 'local' => 'local/{$name}/',
35
+ 'logstore' => 'admin/tool/log/store/{$name}/',
36
+ 'ltisource' => 'mod/lti/source/{$name}/',
37
+ 'ltiservice' => 'mod/lti/service/{$name}/',
38
+ 'message' => 'message/output/{$name}/',
39
+ 'mnetservice' => 'mnet/service/{$name}/',
40
+ 'plagiarism' => 'plagiarism/{$name}/',
41
+ 'portfolio' => 'portfolio/{$name}/',
42
+ 'qbehaviour' => 'question/behaviour/{$name}/',
43
+ 'qformat' => 'question/format/{$name}/',
44
+ 'qtype' => 'question/type/{$name}/',
45
+ 'quizaccess' => 'mod/quiz/accessrule/{$name}/',
46
+ 'quiz' => 'mod/quiz/report/{$name}/',
47
+ 'report' => 'report/{$name}/',
48
+ 'repository' => 'repository/{$name}/',
49
+ 'scormreport' => 'mod/scorm/report/{$name}/',
50
+ 'search' => 'search/engine/{$name}/',
51
+ 'theme' => 'theme/{$name}/',
52
+ 'tinymce' => 'lib/editor/tinymce/plugins/{$name}/',
53
+ 'profilefield' => 'user/profile/field/{$name}/',
54
+ 'webservice' => 'webservice/{$name}/',
55
+ 'workshopallocation' => 'mod/workshop/allocation/{$name}/',
56
+ 'workshopeval' => 'mod/workshop/eval/{$name}/',
57
+ 'workshopform' => 'mod/workshop/form/{$name}/'
58
+ );
59
+ }
vendor/composer/installers/src/Composer/Installers/OctoberInstaller.php ADDED
@@ -0,0 +1,48 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class OctoberInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ 'plugin' => 'plugins/{$vendor}/{$name}/',
9
+ 'theme' => 'themes/{$vendor}-{$name}/'
10
+ );
11
+
12
+ /**
13
+ * Format package name.
14
+ *
15
+ * For package type october-plugin, cut off a trailing '-plugin' if present.
16
+ *
17
+ * For package type october-theme, cut off a trailing '-theme' if present.
18
+ *
19
+ */
20
+ public function inflectPackageVars($vars)
21
+ {
22
+ if ($vars['type'] === 'october-plugin') {
23
+ return $this->inflectPluginVars($vars);
24
+ }
25
+
26
+ if ($vars['type'] === 'october-theme') {
27
+ return $this->inflectThemeVars($vars);
28
+ }
29
+
30
+ return $vars;
31
+ }
32
+
33
+ protected function inflectPluginVars($vars)
34
+ {
35
+ $vars['name'] = preg_replace('/^oc-|-plugin$/', '', $vars['name']);
36
+ $vars['vendor'] = preg_replace('/[^a-z0-9_]/i', '', $vars['vendor']);
37
+
38
+ return $vars;
39
+ }
40
+
41
+ protected function inflectThemeVars($vars)
42
+ {
43
+ $vars['name'] = preg_replace('/^oc-|-theme$/', '', $vars['name']);
44
+ $vars['vendor'] = preg_replace('/[^a-z0-9_]/i', '', $vars['vendor']);
45
+
46
+ return $vars;
47
+ }
48
+ }
vendor/composer/installers/src/Composer/Installers/OntoWikiInstaller.php ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class OntoWikiInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'extension' => 'extensions/{$name}/',
8
+ 'theme' => 'extensions/themes/{$name}/',
9
+ 'translation' => 'extensions/translations/{$name}/',
10
+ );
11
+
12
+ /**
13
+ * Format package name to lower case and remove ".ontowiki" suffix
14
+ */
15
+ public function inflectPackageVars($vars)
16
+ {
17
+ $vars['name'] = strtolower($vars['name']);
18
+ $vars['name'] = preg_replace('/.ontowiki$/', '', $vars['name']);
19
+ $vars['name'] = preg_replace('/-theme$/', '', $vars['name']);
20
+ $vars['name'] = preg_replace('/-translation$/', '', $vars['name']);
21
+
22
+ return $vars;
23
+ }
24
+ }
vendor/composer/installers/src/Composer/Installers/OsclassInstaller.php ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+
5
+ class OsclassInstaller extends BaseInstaller
6
+ {
7
+
8
+ protected $locations = array(
9
+ 'plugin' => 'oc-content/plugins/{$name}/',
10
+ 'theme' => 'oc-content/themes/{$name}/',
11
+ 'language' => 'oc-content/languages/{$name}/',
12
+ );
13
+
14
+ }
vendor/composer/installers/src/Composer/Installers/OxidInstaller.php ADDED
@@ -0,0 +1,59 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ use Composer\Package\PackageInterface;
5
+
6
+ class OxidInstaller extends BaseInstaller
7
+ {
8
+ const VENDOR_PATTERN = '/^modules\/(?P<vendor>.+)\/.+/';
9
+
10
+ protected $locations = array(
11
+ 'module' => 'modules/{$name}/',
12
+ 'theme' => 'application/views/{$name}/',
13
+ 'out' => 'out/{$name}/',
14
+ );
15
+
16
+ /**
17
+ * getInstallPath
18
+ *
19
+ * @param PackageInterface $package
20
+ * @param string $frameworkType
21
+ * @return string
22
+ */
23
+ public function getInstallPath(PackageInterface $package, $frameworkType = '')
24
+ {
25
+ $installPath = parent::getInstallPath($package, $frameworkType);
26
+ $type = $this->package->getType();
27
+ if ($type === 'oxid-module') {
28
+ $this->prepareVendorDirectory($installPath);
29
+ }
30
+ return $installPath;
31
+ }
32
+
33
+ /**
34
+ * prepareVendorDirectory
35
+ *
36
+ * Makes sure there is a vendormetadata.php file inside
37
+ * the vendor folder if there is a vendor folder.
38
+ *
39
+ * @param string $installPath
40
+ * @return void
41
+ */
42
+ protected function prepareVendorDirectory($installPath)
43
+ {
44
+ $matches = '';
45
+ $hasVendorDirectory = preg_match(self::VENDOR_PATTERN, $installPath, $matches);
46
+ if (!$hasVendorDirectory) {
47
+ return;
48
+ }
49
+
50
+ $vendorDirectory = $matches['vendor'];
51
+ $vendorPath = getcwd() . '/modules/' . $vendorDirectory;
52
+ if (!file_exists($vendorPath)) {
53
+ mkdir($vendorPath, 0755, true);
54
+ }
55
+
56
+ $vendorMetaDataPath = $vendorPath . '/vendormetadata.php';
57
+ touch($vendorMetaDataPath);
58
+ }
59
+ }
vendor/composer/installers/src/Composer/Installers/PPIInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PPIInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/PhiftyInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PhiftyInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'bundle' => 'bundles/{$name}/',
8
+ 'library' => 'libraries/{$name}/',
9
+ 'framework' => 'frameworks/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/PhpBBInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PhpBBInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'extension' => 'ext/{$vendor}/{$name}/',
8
+ 'language' => 'language/{$name}/',
9
+ 'style' => 'styles/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/PimcoreInstaller.php ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PimcoreInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'plugins/{$name}/',
8
+ );
9
+
10
+ /**
11
+ * Format package name to CamelCase
12
+ */
13
+ public function inflectPackageVars($vars)
14
+ {
15
+ $vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
16
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
17
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
18
+
19
+ return $vars;
20
+ }
21
+ }
vendor/composer/installers/src/Composer/Installers/PiwikInstaller.php ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * Class PiwikInstaller
6
+ *
7
+ * @package Composer\Installers
8
+ */
9
+ class PiwikInstaller extends BaseInstaller
10
+ {
11
+ /**
12
+ * @var array
13
+ */
14
+ protected $locations = array(
15
+ 'plugin' => 'plugins/{$name}/',
16
+ );
17
+
18
+ /**
19
+ * Format package name to CamelCase
20
+ * @param array $vars
21
+ *
22
+ * @return array
23
+ */
24
+ public function inflectPackageVars($vars)
25
+ {
26
+ $vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
27
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
28
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
29
+
30
+ return $vars;
31
+ }
32
+ }
vendor/composer/installers/src/Composer/Installers/PlentymarketsInstaller.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PlentymarketsInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => '{$name}/'
8
+ );
9
+
10
+ /**
11
+ * Remove hyphen, "plugin" and format to camelcase
12
+ * @param array $vars
13
+ *
14
+ * @return array
15
+ */
16
+ public function inflectPackageVars($vars)
17
+ {
18
+ $vars['name'] = explode("-", $vars['name']);
19
+ foreach ($vars['name'] as $key => $name) {
20
+ $vars['name'][$key] = ucfirst($vars['name'][$key]);
21
+ if (strcasecmp($name, "Plugin") == 0) {
22
+ unset($vars['name'][$key]);
23
+ }
24
+ }
25
+ $vars['name'] = implode("",$vars['name']);
26
+
27
+ return $vars;
28
+ }
29
+ }
vendor/composer/installers/src/Composer/Installers/Plugin.php ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ use Composer\Composer;
6
+ use Composer\IO\IOInterface;
7
+ use Composer\Plugin\PluginInterface;
8
+
9
+ class Plugin implements PluginInterface
10
+ {
11
+ private $installer;
12
+
13
+ public function activate(Composer $composer, IOInterface $io)
14
+ {
15
+ $this->installer = new Installer($io, $composer);
16
+ $composer->getInstallationManager()->addInstaller($this->installer);
17
+ }
18
+
19
+ public function deactivate(Composer $composer, IOInterface $io)
20
+ {
21
+ $composer->getInstallationManager()->removeInstaller($this->installer);
22
+ }
23
+
24
+ public function uninstall(Composer $composer, IOInterface $io)
25
+ {
26
+ }
27
+ }
vendor/composer/installers/src/Composer/Installers/PortoInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PortoInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'container' => 'app/Containers/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/PrestashopInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PrestashopInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ 'theme' => 'themes/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/ProcessWireInstaller.php ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ class ProcessWireInstaller extends BaseInstaller
6
+ {
7
+ protected $locations = array(
8
+ 'module' => 'site/modules/{$name}/',
9
+ );
10
+
11
+ /**
12
+ * Format package name to CamelCase
13
+ */
14
+ public function inflectPackageVars($vars)
15
+ {
16
+ $vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
17
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
18
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
19
+
20
+ return $vars;
21
+ }
22
+ }
vendor/composer/installers/src/Composer/Installers/PuppetInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ class PuppetInstaller extends BaseInstaller
6
+ {
7
+
8
+ protected $locations = array(
9
+ 'module' => 'modules/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/PxcmsInstaller.php ADDED
@@ -0,0 +1,63 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class PxcmsInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'app/Modules/{$name}/',
8
+ 'theme' => 'themes/{$name}/',
9
+ );
10
+
11
+ /**
12
+ * Format package name.
13
+ *
14
+ * @param array $vars
15
+ *
16
+ * @return array
17
+ */
18
+ public function inflectPackageVars($vars)
19
+ {
20
+ if ($vars['type'] === 'pxcms-module') {
21
+ return $this->inflectModuleVars($vars);
22
+ }
23
+
24
+ if ($vars['type'] === 'pxcms-theme') {
25
+ return $this->inflectThemeVars($vars);
26
+ }
27
+
28
+ return $vars;
29
+ }
30
+
31
+ /**
32
+ * For package type pxcms-module, cut off a trailing '-plugin' if present.
33
+ *
34
+ * return string
35
+ */
36
+ protected function inflectModuleVars($vars)
37
+ {
38
+ $vars['name'] = str_replace('pxcms-', '', $vars['name']); // strip out pxcms- just incase (legacy)
39
+ $vars['name'] = str_replace('module-', '', $vars['name']); // strip out module-
40
+ $vars['name'] = preg_replace('/-module$/', '', $vars['name']); // strip out -module
41
+ $vars['name'] = str_replace('-', '_', $vars['name']); // make -'s be _'s
42
+ $vars['name'] = ucwords($vars['name']); // make module name camelcased
43
+
44
+ return $vars;
45
+ }
46
+
47
+
48
+ /**
49
+ * For package type pxcms-module, cut off a trailing '-plugin' if present.
50
+ *
51
+ * return string
52
+ */
53
+ protected function inflectThemeVars($vars)
54
+ {
55
+ $vars['name'] = str_replace('pxcms-', '', $vars['name']); // strip out pxcms- just incase (legacy)
56
+ $vars['name'] = str_replace('theme-', '', $vars['name']); // strip out theme-
57
+ $vars['name'] = preg_replace('/-theme$/', '', $vars['name']); // strip out -theme
58
+ $vars['name'] = str_replace('-', '_', $vars['name']); // make -'s be _'s
59
+ $vars['name'] = ucwords($vars['name']); // make module name camelcased
60
+
61
+ return $vars;
62
+ }
63
+ }
vendor/composer/installers/src/Composer/Installers/RadPHPInstaller.php ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class RadPHPInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'bundle' => 'src/{$name}/'
8
+ );
9
+
10
+ /**
11
+ * Format package name to CamelCase
12
+ */
13
+ public function inflectPackageVars($vars)
14
+ {
15
+ $nameParts = explode('/', $vars['name']);
16
+ foreach ($nameParts as &$value) {
17
+ $value = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $value));
18
+ $value = str_replace(array('-', '_'), ' ', $value);
19
+ $value = str_replace(' ', '', ucwords($value));
20
+ }
21
+ $vars['name'] = implode('/', $nameParts);
22
+ return $vars;
23
+ }
24
+ }
vendor/composer/installers/src/Composer/Installers/ReIndexInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class ReIndexInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'theme' => 'themes/{$name}/',
8
+ 'plugin' => 'plugins/{$name}/'
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/Redaxo5Installer.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class Redaxo5Installer extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'addon' => 'redaxo/src/addons/{$name}/',
8
+ 'bestyle-plugin' => 'redaxo/src/addons/be_style/plugins/{$name}/'
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/RedaxoInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class RedaxoInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'addon' => 'redaxo/include/addons/{$name}/',
8
+ 'bestyle-plugin' => 'redaxo/include/addons/be_style/plugins/{$name}/'
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/RoundcubeInstaller.php ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class RoundcubeInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'plugins/{$name}/',
8
+ );
9
+
10
+ /**
11
+ * Lowercase name and changes the name to a underscores
12
+ *
13
+ * @param array $vars
14
+ * @return array
15
+ */
16
+ public function inflectPackageVars($vars)
17
+ {
18
+ $vars['name'] = strtolower(str_replace('-', '_', $vars['name']));
19
+
20
+ return $vars;
21
+ }
22
+ }
vendor/composer/installers/src/Composer/Installers/SMFInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class SMFInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'Sources/{$name}/',
8
+ 'theme' => 'Themes/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/ShopwareInstaller.php ADDED
@@ -0,0 +1,60 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * Plugin/theme installer for shopware
6
+ * @author Benjamin Boit
7
+ */
8
+ class ShopwareInstaller extends BaseInstaller
9
+ {
10
+ protected $locations = array(
11
+ 'backend-plugin' => 'engine/Shopware/Plugins/Local/Backend/{$name}/',
12
+ 'core-plugin' => 'engine/Shopware/Plugins/Local/Core/{$name}/',
13
+ 'frontend-plugin' => 'engine/Shopware/Plugins/Local/Frontend/{$name}/',
14
+ 'theme' => 'templates/{$name}/',
15
+ 'plugin' => 'custom/plugins/{$name}/',
16
+ 'frontend-theme' => 'themes/Frontend/{$name}/',
17
+ );
18
+
19
+ /**
20
+ * Transforms the names
21
+ * @param array $vars
22
+ * @return array
23
+ */
24
+ public function inflectPackageVars($vars)
25
+ {
26
+ if ($vars['type'] === 'shopware-theme') {
27
+ return $this->correctThemeName($vars);
28
+ }
29
+
30
+ return $this->correctPluginName($vars);
31
+ }
32
+
33
+ /**
34
+ * Changes the name to a camelcased combination of vendor and name
35
+ * @param array $vars
36
+ * @return array
37
+ */
38
+ private function correctPluginName($vars)
39
+ {
40
+ $camelCasedName = preg_replace_callback('/(-[a-z])/', function ($matches) {
41
+ return strtoupper($matches[0][1]);
42
+ }, $vars['name']);
43
+
44
+ $vars['name'] = ucfirst($vars['vendor']) . ucfirst($camelCasedName);
45
+
46
+ return $vars;
47
+ }
48
+
49
+ /**
50
+ * Changes the name to a underscore separated name
51
+ * @param array $vars
52
+ * @return array
53
+ */
54
+ private function correctThemeName($vars)
55
+ {
56
+ $vars['name'] = str_replace('-', '_', $vars['name']);
57
+
58
+ return $vars;
59
+ }
60
+ }
vendor/composer/installers/src/Composer/Installers/SilverStripeInstaller.php ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ use Composer\Package\PackageInterface;
5
+
6
+ class SilverStripeInstaller extends BaseInstaller
7
+ {
8
+ protected $locations = array(
9
+ 'module' => '{$name}/',
10
+ 'theme' => 'themes/{$name}/',
11
+ );
12
+
13
+ /**
14
+ * Return the install path based on package type.
15
+ *
16
+ * Relies on built-in BaseInstaller behaviour with one exception: silverstripe/framework
17
+ * must be installed to 'sapphire' and not 'framework' if the version is <3.0.0
18
+ *
19
+ * @param PackageInterface $package
20
+ * @param string $frameworkType
21
+ * @return string
22
+ */
23
+ public function getInstallPath(PackageInterface $package, $frameworkType = '')
24
+ {
25
+ if (
26
+ $package->getName() == 'silverstripe/framework'
27
+ && preg_match('/^\d+\.\d+\.\d+/', $package->getVersion())
28
+ && version_compare($package->getVersion(), '2.999.999') < 0
29
+ ) {
30
+ return $this->templatePath($this->locations['module'], array('name' => 'sapphire'));
31
+ }
32
+
33
+ return parent::getInstallPath($package, $frameworkType);
34
+ }
35
+ }
vendor/composer/installers/src/Composer/Installers/SiteDirectInstaller.php ADDED
@@ -0,0 +1,25 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ class SiteDirectInstaller extends BaseInstaller
6
+ {
7
+ protected $locations = array(
8
+ 'module' => 'modules/{$vendor}/{$name}/',
9
+ 'plugin' => 'plugins/{$vendor}/{$name}/'
10
+ );
11
+
12
+ public function inflectPackageVars($vars)
13
+ {
14
+ return $this->parseVars($vars);
15
+ }
16
+
17
+ protected function parseVars($vars)
18
+ {
19
+ $vars['vendor'] = strtolower($vars['vendor']) == 'sitedirect' ? 'SiteDirect' : $vars['vendor'];
20
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
21
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
22
+
23
+ return $vars;
24
+ }
25
+ }
vendor/composer/installers/src/Composer/Installers/StarbugInstaller.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class StarbugInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ 'theme' => 'themes/{$name}/',
9
+ 'custom-module' => 'app/modules/{$name}/',
10
+ 'custom-theme' => 'app/themes/{$name}/'
11
+ );
12
+ }
vendor/composer/installers/src/Composer/Installers/SyDESInstaller.php ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class SyDESInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'app/modules/{$name}/',
8
+ 'theme' => 'themes/{$name}/',
9
+ );
10
+
11
+ /**
12
+ * Format module name.
13
+ *
14
+ * Strip `sydes-` prefix and a trailing '-theme' or '-module' from package name if present.
15
+ *
16
+ * {@inerhitDoc}
17
+ */
18
+ public function inflectPackageVars($vars)
19
+ {
20
+ if ($vars['type'] == 'sydes-module') {
21
+ return $this->inflectModuleVars($vars);
22
+ }
23
+
24
+ if ($vars['type'] === 'sydes-theme') {
25
+ return $this->inflectThemeVars($vars);
26
+ }
27
+
28
+ return $vars;
29
+ }
30
+
31
+ public function inflectModuleVars($vars)
32
+ {
33
+ $vars['name'] = preg_replace('/(^sydes-|-module$)/i', '', $vars['name']);
34
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
35
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
36
+
37
+ return $vars;
38
+ }
39
+
40
+ protected function inflectThemeVars($vars)
41
+ {
42
+ $vars['name'] = preg_replace('/(^sydes-|-theme$)/', '', $vars['name']);
43
+ $vars['name'] = strtolower($vars['name']);
44
+
45
+ return $vars;
46
+ }
47
+ }
vendor/composer/installers/src/Composer/Installers/SyliusInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class SyliusInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'theme' => 'themes/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/Symfony1Installer.php ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * Plugin installer for symfony 1.x
6
+ *
7
+ * @author Jérôme Tamarelle <jerome@tamarelle.net>
8
+ */
9
+ class Symfony1Installer extends BaseInstaller
10
+ {
11
+ protected $locations = array(
12
+ 'plugin' => 'plugins/{$name}/',
13
+ );
14
+
15
+ /**
16
+ * Format package name to CamelCase
17
+ */
18
+ public function inflectPackageVars($vars)
19
+ {
20
+ $vars['name'] = preg_replace_callback('/(-[a-z])/', function ($matches) {
21
+ return strtoupper($matches[0][1]);
22
+ }, $vars['name']);
23
+
24
+ return $vars;
25
+ }
26
+ }
vendor/composer/installers/src/Composer/Installers/TYPO3CmsInstaller.php ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * Extension installer for TYPO3 CMS
6
+ *
7
+ * @deprecated since 1.0.25, use https://packagist.org/packages/typo3/cms-composer-installers instead
8
+ *
9
+ * @author Sascha Egerer <sascha.egerer@dkd.de>
10
+ */
11
+ class TYPO3CmsInstaller extends BaseInstaller
12
+ {
13
+ protected $locations = array(
14
+ 'extension' => 'typo3conf/ext/{$name}/',
15
+ );
16
+ }
vendor/composer/installers/src/Composer/Installers/TYPO3FlowInstaller.php ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * An installer to handle TYPO3 Flow specifics when installing packages.
6
+ */
7
+ class TYPO3FlowInstaller extends BaseInstaller
8
+ {
9
+ protected $locations = array(
10
+ 'package' => 'Packages/Application/{$name}/',
11
+ 'framework' => 'Packages/Framework/{$name}/',
12
+ 'plugin' => 'Packages/Plugins/{$name}/',
13
+ 'site' => 'Packages/Sites/{$name}/',
14
+ 'boilerplate' => 'Packages/Boilerplates/{$name}/',
15
+ 'build' => 'Build/{$name}/',
16
+ );
17
+
18
+ /**
19
+ * Modify the package name to be a TYPO3 Flow style key.
20
+ *
21
+ * @param array $vars
22
+ * @return array
23
+ */
24
+ public function inflectPackageVars($vars)
25
+ {
26
+ $autoload = $this->package->getAutoload();
27
+ if (isset($autoload['psr-0']) && is_array($autoload['psr-0'])) {
28
+ $namespace = key($autoload['psr-0']);
29
+ $vars['name'] = str_replace('\\', '.', $namespace);
30
+ }
31
+ if (isset($autoload['psr-4']) && is_array($autoload['psr-4'])) {
32
+ $namespace = key($autoload['psr-4']);
33
+ $vars['name'] = rtrim(str_replace('\\', '.', $namespace), '.');
34
+ }
35
+
36
+ return $vars;
37
+ }
38
+ }
vendor/composer/installers/src/Composer/Installers/TaoInstaller.php ADDED
@@ -0,0 +1,30 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ /**
5
+ * An installer to handle TAO extensions.
6
+ */
7
+ class TaoInstaller extends BaseInstaller
8
+ {
9
+ const EXTRA_TAO_EXTENSION_NAME = 'tao-extension-name';
10
+
11
+ protected $locations = array(
12
+ 'extension' => '{$name}'
13
+ );
14
+
15
+ public function inflectPackageVars($vars)
16
+ {
17
+ $extra = $this->package->getExtra();
18
+
19
+ if (array_key_exists(self::EXTRA_TAO_EXTENSION_NAME, $extra)) {
20
+ $vars['name'] = $extra[self::EXTRA_TAO_EXTENSION_NAME];
21
+ return $vars;
22
+ }
23
+
24
+ $vars['name'] = str_replace('extension-', '', $vars['name']);
25
+ $vars['name'] = str_replace('-', ' ', $vars['name']);
26
+ $vars['name'] = lcfirst(str_replace(' ', '', ucwords($vars['name'])));
27
+
28
+ return $vars;
29
+ }
30
+ }
vendor/composer/installers/src/Composer/Installers/TastyIgniterInstaller.php ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ class TastyIgniterInstaller extends BaseInstaller
6
+ {
7
+ protected $locations = array(
8
+ 'extension' => 'extensions/{$vendor}/{$name}/',
9
+ 'theme' => 'themes/{$name}/',
10
+ );
11
+
12
+ /**
13
+ * Format package name.
14
+ *
15
+ * Cut off leading 'ti-ext-' or 'ti-theme-' if present.
16
+ * Strip vendor name of characters that is not alphanumeric or an underscore
17
+ *
18
+ */
19
+ public function inflectPackageVars($vars)
20
+ {
21
+ if ($vars['type'] === 'tastyigniter-extension') {
22
+ $vars['vendor'] = preg_replace('/[^a-z0-9_]/i', '', $vars['vendor']);
23
+ $vars['name'] = preg_replace('/^ti-ext-/', '', $vars['name']);
24
+ }
25
+
26
+ if ($vars['type'] === 'tastyigniter-theme') {
27
+ $vars['name'] = preg_replace('/^ti-theme-/', '', $vars['name']);
28
+ }
29
+
30
+ return $vars;
31
+ }
32
+ }
vendor/composer/installers/src/Composer/Installers/TheliaInstaller.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class TheliaInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'local/modules/{$name}/',
8
+ 'frontoffice-template' => 'templates/frontOffice/{$name}/',
9
+ 'backoffice-template' => 'templates/backOffice/{$name}/',
10
+ 'email-template' => 'templates/email/{$name}/',
11
+ );
12
+ }
vendor/composer/installers/src/Composer/Installers/TuskInstaller.php ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+ /**
4
+ * Composer installer for 3rd party Tusk utilities
5
+ * @author Drew Ewing <drew@phenocode.com>
6
+ */
7
+ class TuskInstaller extends BaseInstaller
8
+ {
9
+ protected $locations = array(
10
+ 'task' => '.tusk/tasks/{$name}/',
11
+ 'command' => '.tusk/commands/{$name}/',
12
+ 'asset' => 'assets/tusk/{$name}/',
13
+ );
14
+ }
vendor/composer/installers/src/Composer/Installers/UserFrostingInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class UserFrostingInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'sprinkle' => 'app/sprinkles/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/VanillaInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class VanillaInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'plugins/{$name}/',
8
+ 'theme' => 'themes/{$name}/',
9
+ );
10
+ }
vendor/composer/installers/src/Composer/Installers/VgmcpInstaller.php ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class VgmcpInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'bundle' => 'src/{$vendor}/{$name}/',
8
+ 'theme' => 'themes/{$name}/'
9
+ );
10
+
11
+ /**
12
+ * Format package name.
13
+ *
14
+ * For package type vgmcp-bundle, cut off a trailing '-bundle' if present.
15
+ *
16
+ * For package type vgmcp-theme, cut off a trailing '-theme' if present.
17
+ *
18
+ */
19
+ public function inflectPackageVars($vars)
20
+ {
21
+ if ($vars['type'] === 'vgmcp-bundle') {
22
+ return $this->inflectPluginVars($vars);
23
+ }
24
+
25
+ if ($vars['type'] === 'vgmcp-theme') {
26
+ return $this->inflectThemeVars($vars);
27
+ }
28
+
29
+ return $vars;
30
+ }
31
+
32
+ protected function inflectPluginVars($vars)
33
+ {
34
+ $vars['name'] = preg_replace('/-bundle$/', '', $vars['name']);
35
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
36
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
37
+
38
+ return $vars;
39
+ }
40
+
41
+ protected function inflectThemeVars($vars)
42
+ {
43
+ $vars['name'] = preg_replace('/-theme$/', '', $vars['name']);
44
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
45
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
46
+
47
+ return $vars;
48
+ }
49
+ }
vendor/composer/installers/src/Composer/Installers/WHMCSInstaller.php ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Composer\Installers;
4
+
5
+ class WHMCSInstaller extends BaseInstaller
6
+ {
7
+ protected $locations = array(
8
+ 'addons' => 'modules/addons/{$vendor}_{$name}/',
9
+ 'fraud' => 'modules/fraud/{$vendor}_{$name}/',
10
+ 'gateways' => 'modules/gateways/{$vendor}_{$name}/',
11
+ 'notifications' => 'modules/notifications/{$vendor}_{$name}/',
12
+ 'registrars' => 'modules/registrars/{$vendor}_{$name}/',
13
+ 'reports' => 'modules/reports/{$vendor}_{$name}/',
14
+ 'security' => 'modules/security/{$vendor}_{$name}/',
15
+ 'servers' => 'modules/servers/{$vendor}_{$name}/',
16
+ 'social' => 'modules/social/{$vendor}_{$name}/',
17
+ 'support' => 'modules/support/{$vendor}_{$name}/',
18
+ 'templates' => 'templates/{$vendor}_{$name}/',
19
+ 'includes' => 'includes/{$vendor}_{$name}/'
20
+ );
21
+ }
vendor/composer/installers/src/Composer/Installers/WinterInstaller.php ADDED
@@ -0,0 +1,58 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class WinterInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$name}/',
8
+ 'plugin' => 'plugins/{$vendor}/{$name}/',
9
+ 'theme' => 'themes/{$name}/'
10
+ );
11
+
12
+ /**
13
+ * Format package name.
14
+ *
15
+ * For package type winter-plugin, cut off a trailing '-plugin' if present.
16
+ *
17
+ * For package type winter-theme, cut off a trailing '-theme' if present.
18
+ *
19
+ */
20
+ public function inflectPackageVars($vars)
21
+ {
22
+ if ($vars['type'] === 'winter-module') {
23
+ return $this->inflectModuleVars($vars);
24
+ }
25
+
26
+ if ($vars['type'] === 'winter-plugin') {
27
+ return $this->inflectPluginVars($vars);
28
+ }
29
+
30
+ if ($vars['type'] === 'winter-theme') {
31
+ return $this->inflectThemeVars($vars);
32
+ }
33
+
34
+ return $vars;
35
+ }
36
+
37
+ protected function inflectModuleVars($vars)
38
+ {
39
+ $vars['name'] = preg_replace('/^wn-|-module$/', '', $vars['name']);
40
+
41
+ return $vars;
42
+ }
43
+
44
+ protected function inflectPluginVars($vars)
45
+ {
46
+ $vars['name'] = preg_replace('/^wn-|-plugin$/', '', $vars['name']);
47
+ $vars['vendor'] = preg_replace('/[^a-z0-9_]/i', '', $vars['vendor']);
48
+
49
+ return $vars;
50
+ }
51
+
52
+ protected function inflectThemeVars($vars)
53
+ {
54
+ $vars['name'] = preg_replace('/^wn-|-theme$/', '', $vars['name']);
55
+
56
+ return $vars;
57
+ }
58
+ }
vendor/composer/installers/src/Composer/Installers/WolfCMSInstaller.php ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class WolfCMSInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'wolf/plugins/{$name}/',
8
+ );
9
+ }
vendor/composer/installers/src/Composer/Installers/WordPressInstaller.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class WordPressInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'plugin' => 'wp-content/plugins/{$name}/',
8
+ 'theme' => 'wp-content/themes/{$name}/',
9
+ 'muplugin' => 'wp-content/mu-plugins/{$name}/',
10
+ 'dropin' => 'wp-content/{$name}/',
11
+ );
12
+ }
vendor/composer/installers/src/Composer/Installers/YawikInstaller.php ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Created by PhpStorm.
4
+ * User: cbleek
5
+ * Date: 25.03.16
6
+ * Time: 20:55
7
+ */
8
+
9
+ namespace Composer\Installers;
10
+
11
+
12
+ class YawikInstaller extends BaseInstaller
13
+ {
14
+ protected $locations = array(
15
+ 'module' => 'module/{$name}/',
16
+ );
17
+
18
+ /**
19
+ * Format package name to CamelCase
20
+ * @param array $vars
21
+ *
22
+ * @return array
23
+ */
24
+ public function inflectPackageVars($vars)
25
+ {
26
+ $vars['name'] = strtolower(preg_replace('/(?<=\\w)([A-Z])/', '_\\1', $vars['name']));
27
+ $vars['name'] = str_replace(array('-', '_'), ' ', $vars['name']);
28
+ $vars['name'] = str_replace(' ', '', ucwords($vars['name']));
29
+
30
+ return $vars;
31
+ }
32
+ }
vendor/composer/installers/src/Composer/Installers/ZendInstaller.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class ZendInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'library' => 'library/{$name}/',
8
+ 'extra' => 'extras/library/{$name}/',
9
+ 'module' => 'module/{$name}/',
10
+ );
11
+ }
vendor/composer/installers/src/Composer/Installers/ZikulaInstaller.php ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Composer\Installers;
3
+
4
+ class ZikulaInstaller extends BaseInstaller
5
+ {
6
+ protected $locations = array(
7
+ 'module' => 'modules/{$vendor}-{$name}/',
8
+ 'theme' => 'themes/{$vendor}-{$name}/'
9
+ );
10
+ }
vendor/composer/installers/src/bootstrap.php ADDED
@@ -0,0 +1,13 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ function includeIfExists($file)
3
+ {
4
+ if (file_exists($file)) {
5
+ return include $file;
6
+ }
7
+ }
8
+ if ((!$loader = includeIfExists(__DIR__ . '/../vendor/autoload.php')) && (!$loader = includeIfExists(__DIR__ . '/../../../autoload.php'))) {
9
+ die('You must set up the project dependencies, run the following commands:'.PHP_EOL.
10
+ 'curl -s http://getcomposer.org/installer | php'.PHP_EOL.
11
+ 'php composer.phar install'.PHP_EOL);
12
+ }
13
+ return $loader;
vendor/composer/platform_check.php ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // platform_check.php @generated by Composer
4
+
5
+ $issues = array();
6
+
7
+ if (!(PHP_VERSION_ID >= 50400)) {
8
+ $issues[] = 'Your Composer dependencies require a PHP version ">= 5.4.0". You are running ' . PHP_VERSION . '.';
9
+ }
10
+
11
+ if ($issues) {
12
+ if (!headers_sent()) {
13
+ header('HTTP/1.1 500 Internal Server Error');
14
+ }
15
+ if (!ini_get('display_errors')) {
16
+ if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
17
+ fwrite(STDERR, 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . implode(PHP_EOL, $issues) . PHP_EOL.PHP_EOL);
18
+ } elseif (!headers_sent()) {
19
+ echo 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . str_replace('You are running '.PHP_VERSION.'.', '', implode(PHP_EOL, $issues)) . PHP_EOL.PHP_EOL;
20
+ }
21
+ }
22
+ trigger_error(
23
+ 'Composer detected issues in your platform: ' . implode(' ', $issues),
24
+ E_USER_ERROR
25
+ );
26
+ }
wplogin_redirect.php CHANGED
@@ -1,1391 +1,25 @@
1
  <?php
2
  /*
3
- Plugin Name: Peter's Login Redirect
4
- Plugin URI: http://www.theblog.ca/wplogin-redirect
5
- Description: Redirect users to different locations after logging in. Define a set of rules for specific users, user with specific roles, users with specific capabilities, and a blanket rule for all other users. This is all managed in Settings > Login/logout redirects.
6
- Author: Peter Keung
7
- Author URI: https://www.theblog.ca
8
- Version: 2.9.9
9
  Text Domain: peters-login-redirect
10
- Domain Path: /languages/
 
11
  */
12
 
13
- require_once dirname(__FILE__) . '/mo-admin-notice-featured.php';
14
 
15
- add_action('init', 'rul_textdomain');
16
- function rul_textdomain()
17
- {
18
- load_plugin_textdomain('peters-login-redirect', false, dirname(plugin_basename(__FILE__)) . '/languages');
19
- }
20
-
21
- global $wpdb;
22
- global $rul_db_addresses;
23
- global $rul_version;
24
- // Name of the database table that will hold group information and moderator rules
25
- $rul_db_addresses = $wpdb->prefix . 'login_redirects';
26
- $rul_version = '2.9.9';
27
-
28
- // doing this so we can pass current user logging out since it is no longer active after logout
29
- if ( ! function_exists('wp_logout')) :
30
- /**
31
- * Log the current user out.
32
- *
33
- * @since 2.5.0
34
- */
35
- function wp_logout()
36
- {
37
- $current_user = wp_get_current_user();
38
- wp_destroy_current_session();
39
- wp_clear_auth_cookie();
40
- wp_set_current_user(0);
41
-
42
- /**
43
- * Fires after a user is logged-out.
44
- *
45
- * @since 1.5.0
46
- */
47
- do_action('wp_logout', $current_user);
48
- }
49
- endif;
50
-
51
- // Some helper functions, all "public static" in PHP5 land
52
- class rulRedirectFunctionCollection
53
- {
54
- /*
55
- Grabs settings from the database as of version 2.5.0 of this plugin.
56
- Defaults are defined here, but the settings values should be edited in the WordPress admin panel.
57
- If no setting is asked for, then it returns an array of all settings; otherwise it returns a specific setting
58
- */
59
- static function get_settings($setting = false)
60
- {
61
- $rul_settings = array();
62
-
63
- // Allow a POST or GET "redirect_to" variable to take precedence over settings within the plugin
64
- $rul_settings['rul_allow_post_redirect_override'] = false;
65
-
66
- // Allow a POST or GET logout "redirect_to" variable to take precedence over settings within the plugin
67
- $rul_settings['rul_allow_post_redirect_override_logout'] = false;
68
-
69
- $rul_settings_from_options_table = rulRedirectFunctionCollection::get_settings_from_options_table();
70
-
71
- // Merge the default settings with the settings form the database
72
- // Limit the settings in case there are ones from the database that are old
73
- foreach ($rul_settings as $setting_name => $setting_value) {
74
- if (isset($rul_settings_from_options_table[$setting_name])) {
75
- $rul_settings[$setting_name] = $rul_settings_from_options_table[$setting_name];
76
- }
77
- }
78
-
79
- if ( ! $setting) {
80
- return $rul_settings;
81
- }
82
-
83
- if ($setting && isset($rul_settings[$setting])) {
84
- return $rul_settings[$setting];
85
- }
86
-
87
- return false;
88
- }
89
-
90
- static function get_settings_from_options_table()
91
- {
92
- return get_option('rul_settings', array());
93
- }
94
-
95
- static function set_setting($setting = false, $value = false)
96
- {
97
- if ($setting) {
98
- $current_settings = rulRedirectFunctionCollection::get_settings();
99
- if ($current_settings) {
100
- $current_settings[$setting] = $value;
101
- update_option('rul_settings', $current_settings);
102
- }
103
- }
104
- }
105
-
106
- /*
107
- This extra function is necessary to support the use case where someone was previously logged in
108
- Thanks to http://wordpress.org/support/topic/97314 for this function
109
- */
110
- static function redirect_current_user_can($capability, $current_user)
111
- {
112
- global $wpdb;
113
-
114
- $roles = get_option($wpdb->prefix . 'user_roles');
115
- $user_roles = $current_user->{$wpdb->prefix . 'capabilities'};
116
- $user_roles = array_keys($user_roles, true);
117
- $role = $user_roles[0];
118
- $capabilities = $roles[$role]['capabilities'];
119
-
120
- if (in_array($capability, array_keys($capabilities, true))) {
121
- // check array keys of capabilities for match against requested capability
122
- return true;
123
- }
124
-
125
- return false;
126
- }
127
-
128
- /*
129
- A generic function to return the value mapped to a particular variable
130
- */
131
- static function rul_get_variable($variable, $user)
132
- {
133
- $variable_value = apply_filters('rul_replace_variable', false, $variable, $user);
134
- if ( ! $variable_value) {
135
- // Return the permalink of the post ID
136
- if (0 === strpos($variable, 'postid-')) {
137
- $post_id = str_replace('postid-', '', $variable);
138
- $permalink = get_permalink($post_id);
139
- if ($permalink) {
140
- $variable_value = $permalink;
141
- }
142
- } else {
143
- switch ($variable) {
144
- // Returns the current user's username (only use this if you know they're logged in)
145
- case 'username':
146
- $variable_value = rawurlencode($user->user_login);
147
- break;
148
- // Returns the current user's author slug aka nickname as used in URLs
149
- // sanitize_title should not be required here since it was already done on insert
150
- case 'userslug':
151
- $variable_value = $user->user_nicename;
152
- break;
153
- // Returns the URL of the WordPress files; see http://codex.wordpress.org/Function_Reference/network_site_url
154
- case 'siteurl':
155
- $variable_value = network_site_url();
156
- break;
157
- // Returns the URL of the site, possibly different from where the WordPress files are; see http://codex.wordpress.org/Function_Reference/network_home_url
158
- case 'homeurl':
159
- $variable_value = network_home_url();
160
- break;
161
- // Returns the login referrer in order to redirect back to the same page
162
- // Note that this will not work if the referrer is the same as the login processor (otherwise in a standard setup you'd redirect to the login form)
163
- case 'http_referer':
164
- $http_referer_parts = parse_url($_SERVER['HTTP_REFERER']);
165
- if ($_SERVER['REQUEST_URI'] != $http_referer_parts['path']) {
166
- $variable_value = $_SERVER['HTTP_REFERER'];
167
- } else {
168
- $variable_value = '';
169
- }
170
- break;
171
- default:
172
- $variable_value = '';
173
- break;
174
- }
175
- }
176
- }
177
-
178
- return $variable_value;
179
- }
180
-
181
- /**
182
- * Replaces the syntax [variable]variable_name[/variable] with whatever has been mapped to the variable_name in the rul_get_variable function
183
- */
184
- static function rul_replace_variable($string, $user)
185
- {
186
- preg_match_all("/\[variable\](.*?)\[\/variable\]/is", $string, $out);
187
-
188
- if ( ! empty($out[0])) {
189
- foreach ($out[0] as $instance => $full_match) {
190
- $replaced_variable = rulRedirectFunctionCollection::rul_get_variable($out[1][$instance], $user);
191
- $string = str_replace($full_match, $replaced_variable, $string);
192
- }
193
- }
194
-
195
- return $string;
196
- }
197
-
198
- static function rul_trigger_allowed_host($url)
199
- {
200
- $url_parsed = parse_url($url);
201
- if (isset($url_parsed['host'])) {
202
- $rul_allowed_hosts[] = $url_parsed['host'];
203
- add_filter('allowed_redirect_hosts', function ($hosts) use ($rul_allowed_hosts) {
204
- return array_merge($hosts, $rul_allowed_hosts);
205
- });
206
- }
207
- }
208
- }
209
-
210
- // Functions specific to logout redirecting
211
- class rulLogoutFunctionCollection
212
- {
213
- static function logout_redirect($current_user)
214
- {
215
- $rul_allow_post_redirect_override_logout = rulRedirectFunctionCollection::get_settings('rul_allow_post_redirect_override_logout');
216
-
217
- $requested_redirect_to = ! empty($_REQUEST['redirect_to']) ? $_REQUEST['redirect_to'] : false;
218
-
219
- if ( ! $requested_redirect_to || ! $rul_allow_post_redirect_override_logout) {
220
- $rul_url = rulLogoutFunctionCollection::get_redirect_url($current_user, $requested_redirect_to);
221
-
222
- if ($rul_url) {
223
- wp_redirect($rul_url);
224
- die();
225
- }
226
- }
227
- }
228
-
229
- static function logout_redirect_2($redirect_to, $requested_redirect_to, $current_user)
230
- {
231
- $rul_allow_post_redirect_override_logout = rulRedirectFunctionCollection::get_settings('rul_allow_post_redirect_override_logout');
232
-
233
- $requested_redirect_to = ! empty($requested_redirect_to) ? $requested_redirect_to : false;
234
-
235
- if ( ! $requested_redirect_to || ! $rul_allow_post_redirect_override_logout) {
236
- $rul_url = rulLogoutFunctionCollection::get_redirect_url($current_user, $requested_redirect_to);
237
-
238
- if ($rul_url) {
239
- rulRedirectFunctionCollection::rul_trigger_allowed_host($rul_url);
240
- $redirect_to = $rul_url;
241
- }
242
- }
243
-
244
- return $redirect_to;
245
- }
246
-
247
- // Get the logout redirect URL according to defined rules
248
- // Functionality for user-, role-, and capability-specific redirect rules is available
249
- // Note that only the "all other users" redirect URL is currently implemented in the UI
250
- static function get_redirect_url($user, $requested_redirect_to)
251
- {
252
- global $wpdb, $rul_db_addresses;
253
-
254
- $redirect_to = false;
255
-
256
- // Check for an extended custom redirect rule
257
- $rul_custom_redirect = apply_filters('rul_before_user_logout', false, $requested_redirect_to, $user);
258
-
259
- if ($rul_custom_redirect) {
260
- return rulRedirectFunctionCollection::rul_replace_variable($rul_custom_redirect, $user);
261
- }
262
-
263
- // Check for a redirect rule for this user
264
- $rul_user = $wpdb->get_var('SELECT rul_url_logout FROM ' . $rul_db_addresses .
265
- ' WHERE rul_type = \'user\' AND rul_value = \'' . $user->user_login . '\' LIMIT 1');
266
-
267
- if ($rul_user) {
268
- return rulRedirectFunctionCollection::rul_replace_variable($rul_user, $user);
269
- }
270
-
271
- // Check for an extended custom redirect rule
272
- $rul_custom_redirect = apply_filters('rul_before_role_logout', false, $requested_redirect_to, $user);
273
-
274
- if ($rul_custom_redirect) {
275
- return rulRedirectFunctionCollection::rul_replace_variable($rul_custom_redirect, $user);
276
- }
277
-
278
- // Check for a redirect rule that matches this user's role
279
- $rul_roles = $wpdb->get_results('SELECT rul_value, rul_url_logout FROM ' . $rul_db_addresses .
280
- ' WHERE rul_type = \'role\'', OBJECT);
281
-
282
- if ($rul_roles) {
283
- foreach ($rul_roles as $rul_role) {
284
- if ('' != $rul_role->rul_url_logout && isset($user->{$wpdb->prefix . 'capabilities'}[$rul_role->rul_value])) {
285
- return rulRedirectFunctionCollection::rul_replace_variable($rul_role->rul_url_logout, $user);
286
- }
287
- }
288
- }
289
-
290
- // Check for an extended custom redirect rule
291
- $rul_custom_redirect = apply_filters('rul_before_capability_logout', false, $requested_redirect_to, $user);
292
- if ($rul_custom_redirect) {
293
- return rulRedirectFunctionCollection::rul_replace_variable($rul_custom_redirect, $user);
294
- }
295
-
296
- // Check for a redirect rule that matches this user's capability
297
- $rul_levels = $wpdb->get_results('SELECT rul_value, rul_url_logout FROM ' . $rul_db_addresses .
298
- ' WHERE rul_type = \'level\' ORDER BY rul_order, rul_value', OBJECT);
299
-
300
- if ($rul_levels) {
301
- foreach ($rul_levels as $rul_level) {
302
- if ('' != $rul_level->rul_url_logout && rulRedirectFunctionCollection::redirect_current_user_can($rul_level->rul_value, $user)) {
303
- return rulRedirectFunctionCollection::rul_replace_variable($rul_level->rul_url_logout, $user);
304
- }
305
- }
306
- }
307
-
308
- // Check for an extended custom redirect rule
309
- $rul_custom_redirect = apply_filters('rul_before_fallback_logout', false, $requested_redirect_to, $user);
310
- if ($rul_custom_redirect) {
311
- return rulRedirectFunctionCollection::rul_replace_variable($rul_custom_redirect, $user);
312
- }
313
-
314
- // If none of the above matched, look for a rule to apply to all users
315
- $rul_all = $wpdb->get_var('SELECT rul_url_logout FROM ' . $rul_db_addresses .
316
- ' WHERE rul_type = \'all\' LIMIT 1');
317
-
318
- if ($rul_all) {
319
- return rulRedirectFunctionCollection::rul_replace_variable($rul_all, $user);
320
- }
321
-
322
- // No rules matched or existed, so just send them to the WordPress admin panel as usual
323
- return $redirect_to;
324
- }
325
- }
326
-
327
- // Functions for redirecting post-registration
328
- class rulRedirectPostRegistration
329
- {
330
- static function post_registration_wrapper($requested_redirect_to)
331
- {
332
- /*
333
- Some limitations:
334
- - Not yet implemented but possible: toggle whether to allow a GET or POST override of the redirect_to variable (currently it is "yes")
335
- - Not yet possible: Username-customized page, since the WordPress hook is implemented pre-registration, not post-registration
336
- */
337
-
338
- $rul_url = rulRedirectPostRegistration::get_redirect_url($requested_redirect_to);
339
- if ($rul_url) {
340
- rulRedirectFunctionCollection::rul_trigger_allowed_host($rul_url);
341
-
342
- return $rul_url;
343
- }
344
-
345
- return $requested_redirect_to;
346
- }
347
-
348
- // Looks up the redirect URL, if any
349
- static function get_redirect_url($requested_redirect_to)
350
- {
351
- global $wpdb, $rul_db_addresses;
352
-
353
- $redirect_to = false;
354
-
355
- $rul_all = $wpdb->get_var('SELECT rul_url FROM ' . $rul_db_addresses .
356
- ' WHERE rul_type = \'register\' LIMIT 1');
357
-
358
- if ($rul_all) {
359
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_all, false);
360
-
361
- return $redirect_to;
362
- }
363
-
364
- // No rule exists
365
- return $redirect_to;
366
- }
367
- }
368
-
369
- function peters_redirect_wrapper($redirect_to, $requested_redirect_to, $user)
370
- {
371
- $rul_allow_post_redirect_override = rulRedirectFunctionCollection::get_settings('rul_allow_post_redirect_override');
372
-
373
- if ( ! isset($user->user_login)) return $redirect_to;
374
-
375
- if ((admin_url() == $redirect_to && $rul_allow_post_redirect_override) || ! $rul_allow_post_redirect_override) {
376
- $rul_url = redirect_to_front_page($redirect_to, $requested_redirect_to, $user);
377
- if ($rul_url) {
378
- rulRedirectFunctionCollection::rul_trigger_allowed_host($rul_url);
379
-
380
- return $rul_url;
381
- }
382
- }
383
-
384
- return $redirect_to;
385
- }
386
-
387
- function redirect_to_front_page($redirect_to, $requested_redirect_to, $user)
388
- {
389
- global $wpdb, $rul_db_addresses;
390
-
391
- // Check for an extended custom redirect rule
392
- $rul_custom_redirect = apply_filters('rul_before_user', false, $redirect_to, $requested_redirect_to, $user);
393
- if ($rul_custom_redirect) {
394
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_custom_redirect, $user);
395
-
396
- return $redirect_to;
397
- }
398
-
399
- // Check for a redirect rule for this user
400
- $rul_user = $wpdb->get_var('SELECT rul_url FROM ' . $rul_db_addresses .
401
- ' WHERE rul_type = \'user\' AND rul_value = \'' . $user->user_login . '\' LIMIT 1');
402
-
403
- if ($rul_user) {
404
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_user, $user);
405
-
406
- return $redirect_to;
407
- }
408
-
409
- // Check for an extended custom redirect rule
410
- $rul_custom_redirect = apply_filters('rul_before_role', false, $redirect_to, $requested_redirect_to, $user);
411
- if ($rul_custom_redirect) {
412
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_custom_redirect, $user);
413
-
414
- return $redirect_to;
415
- }
416
-
417
- // Check for a redirect rule that matches this user's role
418
- $rul_roles = $wpdb->get_results('SELECT rul_value, rul_url FROM ' . $rul_db_addresses .
419
- ' WHERE rul_type = \'role\'', OBJECT);
420
-
421
- if ($rul_roles) {
422
- foreach ($rul_roles as $rul_role) {
423
- if ('' != $rul_role->rul_url && isset($user->{$wpdb->prefix . 'capabilities'}[$rul_role->rul_value])) {
424
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_role->rul_url, $user);
425
-
426
- return $redirect_to;
427
- }
428
- }
429
- }
430
-
431
- // Check for an extended custom redirect rule
432
- $rul_custom_redirect = apply_filters('rul_before_capability', false, $redirect_to, $requested_redirect_to, $user);
433
- if ($rul_custom_redirect) {
434
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_custom_redirect, $user);
435
-
436
- return $redirect_to;
437
- }
438
-
439
- // Check for a redirect rule that matches this user's capability
440
- $rul_levels = $wpdb->get_results('SELECT rul_value, rul_url FROM ' . $rul_db_addresses .
441
- ' WHERE rul_type = \'level\' ORDER BY rul_order, rul_value', OBJECT);
442
-
443
- if ($rul_levels) {
444
- foreach ($rul_levels as $rul_level) {
445
- if ('' != $rul_level->rul_url && rulRedirectFunctionCollection::redirect_current_user_can($rul_level->rul_value, $user)) {
446
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_level->rul_url, $user);
447
-
448
- return $redirect_to;
449
- }
450
- }
451
- }
452
-
453
- // Check for an extended custom redirect rule
454
- $rul_custom_redirect = apply_filters('rul_before_fallback', false, $redirect_to, $requested_redirect_to, $user);
455
- if ($rul_custom_redirect) {
456
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_custom_redirect, $user);
457
-
458
- return $redirect_to;
459
- }
460
-
461
- // If none of the above matched, look for a rule to apply to all users
462
- $rul_all = $wpdb->get_var('SELECT rul_url FROM ' . $rul_db_addresses .
463
- ' WHERE rul_type = \'all\' LIMIT 1');
464
-
465
- if ($rul_all) {
466
- $redirect_to = rulRedirectFunctionCollection::rul_replace_variable($rul_all, $user);
467
-
468
- return $redirect_to;
469
- }
470
-
471
- // No rules matched or existed, so just send them to the WordPress admin panel as usual
472
- return $redirect_to;
473
-
474
- }
475
-
476
- // Typically this function is used in templates, similarly to the wp_register function
477
- // It returns a link to the administration panel or the one that was custom defined
478
- // If no user is logged in, it returns the "Register" link
479
- // You can specify tags to go around the returned link (or wrap it with no tags); by default this is a list item
480
- // You can also specify whether to print out the link or just return it
481
- function rul_register($before = '<li>', $after = '</li>', $give_echo = true)
482
- {
483
- global $current_user;
484
-
485
- if ( ! is_user_logged_in()) {
486
- if (get_option('users_can_register'))
487
- $link = $before . '<a href="' . site_url('wp-login.php?action=register', 'login') . '">' . __('Register', 'peters-login-redirect') . '</a>' . $after;
488
- else
489
- $link = '';
490
- } else {
491
- $link = $before . '<a href="' . redirect_to_front_page('', '', $current_user) . '">' . __('Site Admin', 'peters-login-redirect') . '</a>' . $after;;
492
- }
493
-
494
- if ($give_echo) {
495
- echo $link;
496
- } else {
497
- return $link;
498
- }
499
- }
500
-
501
- if (is_admin()) {
502
-
503
- // Returns all option HTML for all usernames in the system except for those supplied to it
504
- function rul_returnusernames($exclude)
505
- {
506
- global $wpdb;
507
-
508
- $rul_returnusernames = '';
509
-
510
- // Build the "not in" part of the MySQL query
511
- $exclude_users = "'" . implode("','", $exclude) . "'";
512
-
513
- $rul_userresults = $wpdb->get_results('SELECT user_login FROM ' . $wpdb->users . ' WHERE user_login NOT IN (' . $exclude_users . ') ORDER BY user_login', ARRAY_N);
514
-
515
- // Built the option HTML
516
- if ($rul_userresults) {
517
- foreach ($rul_userresults as $rul_userresult) {
518
- $rul_returnusernames .= '<option value="' . $rul_userresult[0] . '">' . $rul_userresult[0] . '</option>';
519
- }
520
- }
521
-
522
- return $rul_returnusernames;
523
- }
524
-
525
- // Returns all roles in the system
526
- function rul_returnrolenames()
527
- {
528
- global $wp_roles;
529
-
530
- $rul_returnrolenames = array();
531
- foreach (array_keys($wp_roles->role_names) as $rul_rolename) {
532
- $rul_returnrolenames[$rul_rolename] = $rul_rolename;
533
- }
534
-
535
- return $rul_returnrolenames;
536
- }
537
-
538
- // Returns option HTML for all roles in the system, except for those supplied to it
539
- function rul_returnroleoptions($exclude)
540
- {
541
-
542
- // Relies on a function that just returns the role names
543
- $rul_rolenames = rul_returnrolenames($exclude);
544
-
545
- $rul_returnroleoptions = '';
546
-
547
- // Build the option HTML
548
- if ($rul_rolenames) {
549
- foreach ($rul_rolenames as $rul_rolename) {
550
- if ( ! isset($exclude[$rul_rolename])) {
551
- $rul_returnroleoptions .= '<option value="' . $rul_rolename . '">' . $rul_rolename . '</option>';
552
- }
553
- }
554
- }
555
-
556
- return $rul_returnroleoptions;
557
-
558
- }
559
-
560
- // Returns all level names in the system
561
- function rul_returnlevelnames()
562
- {
563
- global $wp_roles;
564
-
565
- $rul_returnlevelnames = array();
566
-
567
- // Builds the array of level names by combing through each of the roles and listing their levels
568
- foreach ($wp_roles->roles as $wp_role) {
569
- $rul_returnlevelnames = array_unique((array_merge($rul_returnlevelnames, array_keys($wp_role['capabilities']))));
570
- }
571
-
572
- // Sort the level names in alphabetical order
573
- sort($rul_returnlevelnames);
574
-
575
- return $rul_returnlevelnames;
576
-
577
- }
578
-
579
- // Returns option HTML for all levels in the system, except for those supplied to it
580
- function rul_returnleveloptions($exclude)
581
- {
582
-
583
- // Relies on a function that just returns the level names
584
- $rul_levelnames = rul_returnlevelnames();
585
-
586
- $rul_returnleveloptions = '';
587
-
588
- // Build the option HTML
589
- foreach ($rul_levelnames as $rul_levelname) {
590
- if ( ! isset($exclude[$rul_levelname])) {
591
- $rul_returnleveloptions .= '<option value="' . $rul_levelname . '">' . $rul_levelname . '</option>';
592
- }
593
- }
594
-
595
- return $rul_returnleveloptions;
596
-
597
- }
598
-
599
- // Wraps the return message in an informational div
600
- function rul_format_return($innerMessage)
601
- {
602
- return '<div id="message" class="updated fade">' . $innerMessage . '</div>';
603
- }
604
-
605
- // Validates adds and edits to make sure that the user / role / level
606
- function rul_validate_submission($typeValue, $type)
607
- {
608
- $success = true;
609
- $error_message = '';
610
 
611
- if ($type == 'user') {
612
- if ( ! username_exists($typeValue)) {
613
- $success = false;
614
- $error_message = '<p><strong>****' . __('ERROR: Non-existent username submitted ', 'peters-login-redirect') . '****</strong></p>';
615
- }
616
- } elseif ($type == 'role') {
617
- // Get a list of roles in the system so that we can verify that a valid role was submitted
618
- $rul_existing_rolenames = rul_returnrolenames();
619
- if ( ! isset($rul_existing_rolenames[$typeValue])) {
620
- $success = false;
621
- $error_message = '<p><strong>****' . __('ERROR: Non-existent role submitted ', 'peters-login-redirect') . '****</strong></p>';
622
- }
623
- } elseif ($type == 'level') {
624
- // Get a list of levels in the system so that we can verify that a valid level was submitted
625
- $rul_existing_levelnames = array_flip(rul_returnlevelnames());
626
 
627
- if ( ! isset($rul_existing_levelnames[$typeValue])) {
628
- $success = false;
629
- $error_message = '<p><strong>****' . __('ERROR: Non-existent level submitted ', 'peters-login-redirect') . '****</strong></p>';
630
- }
631
- }
632
-
633
- return array('success' => $success, 'error_message' => $error_message);
634
- }
635
-
636
- // Validates deletions by simply making sure that the entry isn't empty
637
- // Additional validation / escaping should be performed if WordPress ever removes its automatic addslashes calls (see http://www.theblog.ca/wordpress-addslashes-magic-quotes); at that point, use https://codex.wordpress.org/Class_Reference/wpdb#DELETE_Rows
638
- function rul_validate_deletion($typeValue, $type)
639
- {
640
- $success = true;
641
- $error_message = '';
642
-
643
- if (trim($typeValue) == '') {
644
- $success = false;
645
- $error_message = '<p><strong>****' . sprintf(__('ERROR: Empty %s submitted ', 'peters-login-redirect'), $type) . '****</strong></p>';
646
- }
647
-
648
- return array('success' => $success, 'error_message' => $error_message);
649
- }
650
-
651
- // Processes adding a new redirect rule
652
- // $type can be user, role, or level
653
- function rul_submit_rule($typeValue, $address, $address_logout, $order = 0, $type)
654
- {
655
- global $wpdb, $rul_db_addresses;
656
-
657
- // Ensure that the request came from the back-end
658
- check_admin_referer('rul_' . $type . '_submit');
659
-
660
- $rul_process_submit = '';
661
-
662
- if ($typeValue && ($address || $address_logout)) {
663
- // Validation depending on the type
664
- $validation = rul_validate_submission($typeValue, $type);
665
- $rul_submit_success = $validation['success'];
666
- $rul_process_submit = $validation['error_message'];
667
-
668
- if ($rul_submit_success) {
669
-
670
- // Insert a new rule
671
-
672
- $order = abs(intval($order));
673
- if ($order > 99) {
674
- $order = 0;
675
- }
676
-
677
- $rul_update_rule = $wpdb->insert($rul_db_addresses,
678
- array(
679
- 'rul_url' => $address,
680
- 'rul_url_logout' => $address_logout,
681
- 'rul_type' => $type,
682
- 'rul_value' => $typeValue,
683
- 'rul_order' => $order
684
- ),
685
- array('%s', '%s', '%s', '%s', '%d')
686
- );
687
-
688
- if ( ! $rul_update_rule) {
689
- $rul_submit_success = false;
690
- $rul_process_submit = '<p><strong>****' . sprintf(__('ERROR: Unknown error adding %s-specific redirect for %s %s', 'peters-login-redirect'), $type, $type, $typeValue) . '****</strong></p>';
691
- }
692
- }
693
-
694
- if ($rul_submit_success) {
695
- $rul_process_submit = '<p>' . sprintf(__('Successfully added %s-specific redirect rule for %s', 'peters-login-redirect'), $type, $typeValue) . '</p>';
696
- }
697
- }
698
-
699
- return rul_format_return($rul_process_submit);
700
- }
701
-
702
- // Edits a redirect rule
703
- // $type can be user, role, or level
704
- function rul_edit_rule($typeValue, $address, $address_logout, $order = 0, $type)
705
- {
706
- global $wpdb, $rul_db_addresses;
707
-
708
- // Ensure that the request came from the back-end
709
- check_admin_referer('rul_' . $type . '_edit');
710
-
711
- if ($typeValue && ($address || $address_logout)) {
712
- // Validation depending on the type
713
- $validation = rul_validate_submission($typeValue, $type);
714
- $rul_submit_success = $validation['success'];
715
- $rul_process_submit = $validation['error_message'];
716
-
717
- if ($rul_submit_success) {
718
- // Edit the rule
719
-
720
- $order = abs(intval($order));
721
- if ($order > 99) {
722
- $order = 0;
723
- }
724
-
725
- $rul_update_rule = $wpdb->update($rul_db_addresses,
726
- array(
727
- 'rul_url' => $address,
728
- 'rul_url_logout' => $address_logout,
729
- 'rul_order' => $order
730
- ),
731
- array(
732
- 'rul_value' => $typeValue,
733
- 'rul_type' => $type
734
- ),
735
- array('%s', '%s', '%d'),
736
- array('%s', '%s')
737
- );
738
-
739
- if ( ! $rul_update_rule) {
740
- $rul_submit_success = false;
741
- $rul_process_submit = '<p><strong>****' . sprintf(__('ERROR: Unknown error editing %s-specific redirect for %s %s', 'peters-login-redirect'), $type, $type, $typeValue) . '****</strong></p>';
742
- }
743
- }
744
-
745
- if ($rul_submit_success) {
746
- $rul_process_submit = '<p>' . sprintf(__('Successfully edited %s-specific redirect rule for %s', 'peters-login-redirect'), $type, $typeValue) . '</p>';
747
- }
748
- }
749
-
750
- return rul_format_return($rul_process_submit);
751
- }
752
-
753
- // Deletes a redirect rule
754
- // $type can be user, role, or level
755
- function rul_delete_rule($typeValue, $type)
756
- {
757
- global $wpdb, $rul_db_addresses;
758
-
759
- // Ensure that the request came from the back-end
760
- check_admin_referer('rul_' . $type . '_edit');
761
-
762
- if ($typeValue) {
763
- // Validation depending on the type
764
- $validation = rul_validate_deletion($typeValue, $type);
765
- $rul_submit_success = $validation['success'];
766
- $rul_process_submit = $validation['error_message'];
767
-
768
- if ($rul_submit_success) {
769
- // Delete the rule
770
- $rul_update_rule = $wpdb->query("DELETE FROM `$rul_db_addresses` WHERE `rul_value` = '$typeValue' AND `rul_type` = '$type' LIMIT 1");
771
-
772
- if ( ! $rul_update_rule) {
773
- $rul_submit_success = false;
774
- $rul_process_submit = '<p><strong>****' . sprintf(__('ERROR: Unknown error deleting %s-specific redirect for %s %s', 'peters-login-redirect'), $type, $type, $typeValue) . '****</strong></p>';
775
- }
776
- }
777
-
778
- if ($rul_submit_success) {
779
- $rul_process_submit = '<p>' . sprintf(__('Successfully deleted %s-specific redirect rule for %s', 'peters-login-redirect'), $type, $typeValue) . '</p>';
780
- }
781
- }
782
-
783
- return rul_format_return($rul_process_submit);
784
- }
785
-
786
- function rul_submit_all($update_or_delete, $address, $address_logout)
787
- {
788
- global $wpdb, $rul_db_addresses;
789
-
790
- // Ensure that the request came from the back-end
791
- check_admin_referer('rul_allupdatesubmit');
792
-
793
- $address = trim($address);
794
- $address_logout = trim($address_logout);
795
-
796
- // Open the informational div
797
- $rul_process_submit = '<div id="message" class="updated fade">';
798
-
799
- // Code for closing the informational div
800
- $rul_process_close = '</div>';
801
-
802
- // ----------------------------------
803
- // Process the rule changes
804
- // ----------------------------------
805
-
806
- // Since we never actually, remove the "all" entry, here we just make its value empty
807
- if ($update_or_delete == 'delete') {
808
- $update = $wpdb->update(
809
- $rul_db_addresses,
810
- array('rul_url' => '', 'rul_url_logout' => ''),
811
- array('rul_type' => 'all')
812
- );
813
-
814
- if ($update === false) {
815
- $rul_process_submit .= '<p><strong>****' . __('ERROR: Unknown database problem removing URL for &#34;all other users&#34; ', 'peters-login-redirect') . '****</strong></p>';
816
- } else {
817
- $rul_process_submit .= '<p>' . __('Successfully removed URL for &#34;all other users&#34; ', 'peters-login-redirect') . '</p>';
818
- }
819
- } elseif ($update_or_delete == 'update') {
820
- $update = $wpdb->update(
821
- $rul_db_addresses,
822
- array('rul_url' => $address, 'rul_url_logout' => $address_logout),
823
- array('rul_type' => 'all')
824
- );
825
-
826
- if ($update === false) {
827
- $rul_process_submit .= '<p><strong>****' . __('ERROR: Unknown database problem updating URL for &#34;all other users&#34; ', 'peters-login-redirect') . '****</strong></p>';
828
- } else {
829
- $rul_process_submit .= '<p>' . __('Successfully updated URL for &#34;all other users&#34;', 'peters-login-redirect') . '</p>';
830
- }
831
- }
832
-
833
- // Close the informational div
834
- $rul_process_submit .= $rul_process_close;
835
-
836
- // We've made it this far, so success!
837
- return $rul_process_submit;
838
- }
839
-
840
- function rul_submit_register($update_or_delete, $address)
841
- {
842
- global $wpdb, $rul_db_addresses;
843
-
844
- // Ensure that the request came from the back-end
845
- check_admin_referer('rul_registerupdatesubmit');
846
-
847
- $address = trim($address);
848
-
849
- // Open the informational div
850
- $rul_process_submit = '<div id="message" class="updated fade">';
851
-
852
- // Code for closing the informational div
853
- $rul_process_close = '</div>';
854
-
855
- // ----------------------------------
856
- // Process the rule changes
857
- // ----------------------------------
858
-
859
- // Since we never actually remove the "register" entry, here we just make its value empty
860
- if ($update_or_delete == 'delete') {
861
- $update = $wpdb->update(
862
- $rul_db_addresses,
863
- array('rul_url' => ''),
864
- array('rul_type' => 'register')
865
- );
866
-
867
- if ($update === false) {
868
- $rul_process_submit .= '<p><strong>****' . __('ERROR: Unknown database problem removing URL for &#34;post-registration&#34; ', 'peters-login-redirect') . '****</strong></p>';
869
- } else {
870
- $rul_process_submit .= '<p>' . __('Successfully removed URL for &#34;post-registration&#34; ', 'peters-login-redirect') . '</p>';
871
- }
872
- } elseif ($update_or_delete == 'update') {
873
- $update = $wpdb->update(
874
- $rul_db_addresses,
875
- array('rul_url' => $address),
876
- array('rul_type' => 'register')
877
- );
878
-
879
- if ($update === false) {
880
- $rul_process_submit .= '<p><strong>****' . __('ERROR: Unknown database problem updating URL for &#34;post-registration&#34; ', 'peters-login-redirect') . '****</strong></p>';
881
- } else {
882
- $rul_process_submit .= '<p>' . __('Successfully updated URL for &#34;post-registration&#34;', 'peters-login-redirect') . '</p>';
883
- }
884
- }
885
-
886
- // Close the informational div
887
- $rul_process_submit .= $rul_process_close;
888
-
889
- // We've made it this far, so success!
890
- return $rul_process_submit;
891
- }
892
-
893
-
894
- // Process submitted information to update plugin settings
895
- function rul_submit_settings()
896
- {
897
- // Ensure that the request came from the back-end
898
- check_admin_referer('settings');
899
-
900
- $rul_settings = rulRedirectFunctionCollection::get_settings();
901
- foreach ($rul_settings as $setting_name => $setting_value) {
902
- if (isset($_POST[$setting_name])) {
903
- $rul_settings[$setting_name] = $_POST[$setting_name];
904
- }
905
- }
906
- update_option('rul_settings', $rul_settings);
907
- $rul_process_submit = '<div id="message" class="updated fade">';
908
- $rul_process_submit .= '<p>' . __('Successfully updated plugin settings', 'peters-login-redirect') . '</p>';
909
- $rul_process_submit .= '</div>';
910
-
911
- return $rul_process_submit;
912
- }
913
-
914
- // This is the Settings > Login/logout redirects menu
915
- function rul_optionsmenu()
916
- {
917
- global $wpdb, $rul_db_addresses;
918
-
919
- // Upgrade check here because it's the only place we know they will visit
920
- rul_upgrade();
921
-
922
- $rul_process_submit = '';
923
-
924
- // Process submitted information to update redirect rules
925
- if (isset($_POST['rul_username_submit'])) {
926
- $rul_process_submit = rul_submit_rule($_POST['rul_username'], $_POST['rul_username_address'], $_POST['rul_username_logout'], 0, 'user');
927
- } elseif (isset($_POST['rul_username_edit'])) {
928
- $rul_process_submit = rul_edit_rule($_POST['rul_username'], $_POST['rul_username_address'], $_POST['rul_username_logout'], 0, 'user');
929
- } elseif (isset($_POST['rul_username_delete'])) {
930
- $rul_process_submit = rul_delete_rule($_POST['rul_username'], 'user');
931
- } elseif (isset($_POST['rul_role_submit'])) {
932
- $rul_process_submit = rul_submit_rule($_POST['rul_role'], $_POST['rul_role_address'], $_POST['rul_role_logout'], 0, 'role');
933
- } elseif (isset($_POST['rul_role_edit'])) {
934
- $rul_process_submit = rul_edit_rule($_POST['rul_role'], $_POST['rul_role_address'], $_POST['rul_role_logout'], 0, 'role');
935
- } elseif (isset($_POST['rul_role_delete'])) {
936
- $rul_process_submit = rul_delete_rule($_POST['rul_role'], 'role');
937
- } elseif (isset($_POST['rul_level_submit'])) {
938
- $rul_process_submit = rul_submit_rule($_POST['rul_level'], $_POST['rul_level_address'], $_POST['rul_level_logout'], $_POST['rul_level_order'], 'level');
939
- } elseif (isset($_POST['rul_level_edit'])) {
940
- $rul_process_submit = rul_edit_rule($_POST['rul_level'], $_POST['rul_level_address'], $_POST['rul_level_logout'], $_POST['rul_level_order'], 'level');
941
- } elseif (isset($_POST['rul_level_delete'])) {
942
- $rul_process_submit = rul_delete_rule($_POST['rul_level'], 'level');
943
- } elseif (isset($_POST['rul_allupdatesubmit'])) {
944
- $rul_process_submit = rul_submit_all('update', $_POST['rul_all'], $_POST['rul_all_logout']);
945
- } elseif (isset($_POST['rul_alldeletesubmit'])) {
946
- $rul_process_submit = rul_submit_all('delete', $_POST['rul_all'], $_POST['rul_all_logout']);
947
- } elseif (isset($_POST['rul_registerupdatesubmit'])) {
948
- $rul_process_submit = rul_submit_register('update', $_POST['rul_register']);
949
- } elseif (isset($_POST['rul_registerdeletesubmit'])) {
950
- $rul_process_submit = rul_submit_register('delete', $_POST['rul_register']);
951
- } elseif (isset($_POST['rul_settingssubmit'])) {
952
- $rul_process_submit = rul_submit_settings();
953
- }
954
-
955
- // Settings that can be updated
956
- $rul_settings = rulRedirectFunctionCollection::get_settings();
957
-
958
- // -----------------------------------
959
- // Get the existing rules
960
- // -----------------------------------
961
-
962
- $rul_rules = $wpdb->get_results('SELECT rul_type, rul_value, rul_url, rul_url_logout, rul_order FROM ' . $rul_db_addresses . ' ORDER BY rul_type, rul_order, rul_value', ARRAY_N);
963
-
964
- $rul_usernamevalues = '';
965
- $rul_rolevalues = '';
966
- $rul_levelvalues = '';
967
- $rul_usernames_existing = array();
968
- $rul_roles_existing = array();
969
- $rul_levels_existing = array();
970
-
971
- if ($rul_rules) {
972
-
973
- $i = 0;
974
- $i_user = 0;
975
- $i_role = 0;
976
- $i_level = 0;
977
-
978
- while ($i < count($rul_rules)) {
979
-
980
- list($rul_type, $rul_value, $rul_url, $rul_url_logout, $rul_order) = $rul_rules[$i];
981
-
982
- // Specific users
983
- if ($rul_type == 'user') {
984
- $rul_usernamevalues .= '<form name="rul_username_edit_form[' . $i_user . ']" action="?page=' . basename(__FILE__) . '" method="post">';
985
- $rul_usernamevalues .= '<tr>';
986
- $rul_usernamevalues .= '<td><p><input type="hidden" name="rul_username" value="' . htmlspecialchars($rul_value) . '" /> ' . $rul_value . '</p></td>';
987
- $rul_usernamevalues .= '<td>';
988
- $rul_usernamevalues .= '<p>' . __('Login URL', 'peters-login-redirect') . '<br /><input type="text" size="90" maxlength="500" name="rul_username_address" value="' . htmlspecialchars($rul_url) . '" /></p>';
989
- $rul_usernamevalues .= '<p>' . __('Logout URL', 'peters-login-redirect') . '<br /><input type="text" size="60" maxlength="500" name="rul_username_logout" value="' . htmlspecialchars($rul_url_logout) . '" /></p>';
990
- $rul_usernamevalues .= '</td>';
991
- $rul_usernamevalues .= '<td><p>';
992
- $rul_usernamevalues .= '<input class="button button-primary" name="rul_username_edit" type="submit" value="' . __('Edit', 'peters-login-redirect') . '" /> <input type="submit" class="button" name="rul_username_delete" value="' . __('Delete', 'peters-login-redirect') . '" />';
993
- $rul_usernamevalues .= wp_nonce_field('rul_user_edit', '_wpnonce', true, false);
994
- $rul_usernamevalues .= '</p></td>';
995
- $rul_usernamevalues .= '</tr>';
996
- $rul_usernamevalues .= '</form>';
997
-
998
- $rul_usernames_existing[] = $rul_value;
999
-
1000
- ++$i_user;
1001
- } elseif ($rul_type == 'role') {
1002
- $rul_rolevalues .= '<form name="rul_role_edit_form[' . $i_role . ']" action="?page=' . basename(__FILE__) . '" method="post">';
1003
- $rul_rolevalues .= '<tr>';
1004
- $rul_rolevalues .= '<td><p><input type="hidden" name="rul_role" value="' . htmlspecialchars($rul_value) . '" /> ' . $rul_value . '</p></td>';
1005
- $rul_rolevalues .= '<td>';
1006
- $rul_rolevalues .= '<p>' . __('Login URL', 'peters-login-redirect') . '<br /><input type="text" size="90" maxlength="500" name="rul_role_address" value="' . htmlspecialchars($rul_url) . '" /></p>';
1007
- $rul_rolevalues .= '<p>' . __('Logout URL', 'peters-login-redirect') . '<br /><input type="text" size="60" maxlength="500" name="rul_role_logout" value="' . htmlspecialchars($rul_url_logout) . '" /></p>';
1008
- $rul_rolevalues .= '</td>';
1009
- $rul_rolevalues .= '<td><p>';
1010
- $rul_rolevalues .= '<input class="button button-primary" name="rul_role_edit" type="submit" value="' . __('Edit', 'peters-login-redirect') . '" /> <input type="submit" class="button" name="rul_role_delete" value="' . __('Delete', 'peters-login-redirect') . '" />';
1011
- $rul_rolevalues .= wp_nonce_field('rul_role_edit', '_wpnonce', true, false);
1012
- $rul_rolevalues .= '</p></td>';
1013
- $rul_rolevalues .= '</tr>';
1014
- $rul_rolevalues .= '</form>';
1015
-
1016
- $rul_roles_existing[$rul_value] = '';
1017
-
1018
- ++$i_role;
1019
- } elseif ($rul_type == 'level') {
1020
- $rul_levelvalues .= '<form name="rul_level_edit_form[' . $i_level . ']" action="?page=' . basename(__FILE__) . '" method="post">';
1021
- $rul_levelvalues .= '<tr>';
1022
- $rul_levelvalues .= '<td><p><input type="hidden" name="rul_level" value="' . htmlspecialchars($rul_value) . '" /> ' . $rul_value . '</p></td>';
1023
- $rul_levelvalues .= '<td>';
1024
- $rul_levelvalues .= '<p>' . __('Login URL', 'peters-login-redirect') . '<br /><input type="text" size="90" maxlength="500" name="rul_level_address" value="' . htmlspecialchars($rul_url) . '" /></p>';
1025
- $rul_levelvalues .= '<p>' . __('Logout URL', 'peters-login-redirect') . '<br /><input type="text" size="60" maxlength="500" name="rul_level_logout" value="' . htmlspecialchars($rul_url_logout) . '" /></p>';
1026
- $rul_levelvalues .= '</td>';
1027
- $rul_levelvalues .= '<td><p><input name="rul_level_order" type="text" size="2" maxlength="2" value="' . $rul_order . '" /></td>';
1028
- $rul_levelvalues .= '<td><p>';
1029
- $rul_levelvalues .= '<input class="button button-primary" name="rul_level_edit" type="submit" value="' . __('Edit', 'peters-login-redirect') . '" /> <input type="submit" class="button" name="rul_level_delete" value="' . __('Delete', 'peters-login-redirect') . '" />';
1030
- $rul_levelvalues .= wp_nonce_field('rul_level_edit', '_wpnonce', true, false);
1031
- $rul_levelvalues .= '</p></td>';
1032
- $rul_levelvalues .= '</tr>';
1033
- $rul_levelvalues .= '</form>';
1034
-
1035
- $rul_levels_existing[$rul_value] = '';
1036
-
1037
- ++$i_level;
1038
- } elseif ($rul_type == 'all') {
1039
- $rul_allvalue = $rul_url;
1040
- $rul_allvalue_logout = $rul_url_logout;
1041
- } elseif ($rul_type == 'register') {
1042
- $rul_registervalue = $rul_url;
1043
- }
1044
- ++$i;
1045
- }
1046
-
1047
- }
1048
- ?>
1049
- <div class="wrap">
1050
- <h2><?php _e('Manage redirect rules', 'peters-login-redirect'); ?></h2>
1051
- <?php print $rul_process_submit; ?>
1052
- <p><?php _e('Define custom URLs to which different users, users with specific roles, users with specific levels, and all other users will be redirected upon login.', 'peters-login-redirect'); ?></p>
1053
- <p><?php _e('Define a custom URL to which all users will be redirected upon logout', 'peters-login-redirect'); ?></p>
1054
- <p><?php _e('Note that you can use the syntax <strong>[variable]username[/variable]</strong> in your URLs so that the system will build a dynamic URL upon each login, replacing that text with the users username.', 'peters-login-redirect'); ?></p>
1055
-
1056
- <h3><?php _e('Specific users', 'peters-login-redirect'); ?></h3>
1057
- <?php
1058
- if ($rul_usernamevalues) {
1059
- print '<table class="widefat">';
1060
- print $rul_usernamevalues;
1061
- print '</table>';
1062
- }
1063
- ?>
1064
-
1065
- <form name="rul_username_add_form" action="<?php print '?page=' . basename(__FILE__); ?>" method="post">
1066
- <p><?php _e('Add:', 'peters-login-redirect'); ?>
1067
- <select name="rul_username">
1068
- <option value="-1"><?php _e('Select a username', 'peters-login-redirect'); ?></option>
1069
- <?php print rul_returnusernames($rul_usernames_existing); ?>
1070
- </select>
1071
- <br/><?php _e('URL:', 'peters-login-redirect'); ?>
1072
- <input type="text" size="90" maxlength="500" name="rul_username_address"/>
1073
- <br/><?php _e('Logout URL:', 'peters-login-redirect'); ?>
1074
- <input type="text" size="90" maxlength="500" name="rul_username_logout"/>
1075
- </p>
1076
- <p class="submit">
1077
- <input type="submit" class="button button-primary" name="rul_username_submit" value="<?php _e('Add username rule', 'peters-login-redirect'); ?>"/>
1078
- <?php wp_nonce_field('rul_user_submit'); ?>
1079
- </p>
1080
- </form>
1081
-
1082
- <h3><?php _e('Specific roles', 'peters-login-redirect'); ?></h3>
1083
- <?php
1084
- if ($rul_rolevalues) {
1085
- print '<table class="widefat">';
1086
- print $rul_rolevalues;
1087
- print '</table>';
1088
- }
1089
- ?>
1090
-
1091
- <form name="rul_role_add_form" action="<?php print '?page=' . basename(__FILE__); ?>" method="post">
1092
- <p><?php _e('Add:', 'peters-login-redirect'); ?>
1093
- <select name="rul_role">
1094
- <option value="-1"><?php _e('Select a role', 'peters-login-redirect'); ?></option>
1095
- <?php print rul_returnroleoptions($rul_roles_existing); ?>
1096
- </select>
1097
- <br/><?php _e('URL:', 'peters-login-redirect'); ?>
1098
- <input type="text" size="90" maxlength="500" name="rul_role_address"/>
1099
- <br/><?php _e('Logout URL:', 'peters-login-redirect'); ?>
1100
- <input type="text" size="90" maxlength="500" name="rul_role_logout"/>
1101
- </p>
1102
- <p class="submit">
1103
- <input type="submit" class="button button-primary" name="rul_role_submit" value="<?php _e('Add role rule', 'peters-login-redirect'); ?>"/>
1104
- <?php wp_nonce_field('rul_role_submit'); ?>
1105
- </p>
1106
- </form>
1107
-
1108
- <h3><?php _e('Specific levels', 'peters-login-redirect'); ?></h3>
1109
- <?php
1110
- if ($rul_levelvalues) {
1111
- print '<table class="widefat">';
1112
- ?>
1113
- <tr>
1114
- <th></th>
1115
- <th></th>
1116
- <th><?php _e('Order', 'peters-login-redirect'); ?></th>
1117
- <th></th>
1118
- </tr>
1119
- <?php
1120
- print $rul_levelvalues;
1121
- print '</table>';
1122
- }
1123
- ?>
1124
-
1125
- <form name="rul_level_add_form" action="<?php print '?page=' . basename(__FILE__); ?>" method="post">
1126
- <p><?php _e('Add:', 'peters-login-redirect'); ?>
1127
- <select name="rul_level">
1128
- <option value="-1"><?php _e('Select a level', 'peters-login-redirect'); ?></option>
1129
- <?php print rul_returnleveloptions($rul_levels_existing); ?>
1130
- </select>
1131
- <br/><?php _e('Order:', 'peters-login-redirect'); ?>
1132
- <input type="text" size="2" maxlength="2" name="rul_level_order"/>
1133
- <br/><?php _e('URL:', 'peters-login-redirect'); ?>
1134
- <input type="text" size="90" maxlength="500" name="rul_level_address"/>
1135
- <br/><?php _e('Logout URL:', 'peters-login-redirect'); ?>
1136
- <input type="text" size="90" maxlength="500" name="rul_level_logout"/>
1137
- </p>
1138
- <p class="submit">
1139
- <input type="submit" class="button button-primary" name="rul_level_submit" value="<?php _e('Add level rule', 'peters-login-redirect'); ?>"/>
1140
- <?php wp_nonce_field('rul_level_submit'); ?>
1141
- </p>
1142
- </form>
1143
-
1144
- <h3><?php _e('All other users', 'peters-login-redirect'); ?></h3>
1145
- <form name="rul_allform" method="post">
1146
- <p><?php _e('URL:', 'peters-login-redirect') ?>
1147
- <input type="text" size="90" maxlength="500" name="rul_all" value="<?php print htmlspecialchars($rul_allvalue); ?>"/>
1148
- </p>
1149
- <p><?php _e('Logout URL:', 'peters-login-redirect') ?>
1150
- <input type="text" size="90" maxlength="500" name="rul_all_logout" value="<?php print htmlspecialchars($rul_allvalue_logout); ?>"/>
1151
- </p>
1152
- <p class="submit">
1153
- <input type="submit" class="button button-primary" name="rul_allupdatesubmit" value="<?php _e('Update', 'peters-login-redirect'); ?>"/>
1154
- <input type="submit" class="button" name="rul_alldeletesubmit" value="<?php _e('Delete', 'peters-login-redirect'); ?>"/>
1155
- <?php wp_nonce_field('rul_allupdatesubmit'); ?>
1156
- </p>
1157
- </form>
1158
-
1159
- <hr/>
1160
-
1161
- <h3><?php _e('Post-registration', 'peters-login-redirect'); ?></h3>
1162
- <form name="rul_registerform" method="post">
1163
- <p><?php _e('URL:', 'peters-login-redirect') ?>
1164
- <input type="text" size="90" maxlength="500" name="rul_register" value="<?php print htmlspecialchars($rul_registervalue); ?>"/>
1165
- </p>
1166
- <p class="submit">
1167
- <input type="submit" class="button button-primary" name="rul_registerupdatesubmit" value="<?php _e('Update', 'peters-login-redirect'); ?>"/>
1168
- <input type="submit" class="button" name="rul_registerdeletesubmit" value="<?php _e('Delete', 'peters-login-redirect'); ?>"/>
1169
- <?php wp_nonce_field('rul_registerupdatesubmit'); ?>
1170
- </p>
1171
- </form>
1172
-
1173
- <hr/>
1174
-
1175
- <h3><?php _e('Customize plugin settings', 'peters-login-redirect'); ?></h3>
1176
- <form name="rul_settingsform" method="post">
1177
- <table class="widefat">
1178
- <tr>
1179
- <td>
1180
- <p>
1181
- <strong><?php _e('Allow a POST or GET &#34;redirect_to&#34; variable to take redirect precedence', 'peters-login-redirect'); ?></strong>
1182
- </p>
1183
- </td>
1184
- <td>
1185
- <select name="rul_allow_post_redirect_override">
1186
- <option value="1"<?php if ($rul_settings['rul_allow_post_redirect_override']) print ' selected="selected"'; ?>><?php _e('Yes', 'peters-login-redirect'); ?></option>
1187
- <option value="0"<?php if ( ! $rul_settings['rul_allow_post_redirect_override']) print ' selected="selected"'; ?>><?php _e('No', 'peters-login-redirect'); ?></option>
1188
- </select>
1189
- </td>
1190
- </tr>
1191
- <tr>
1192
- <td>
1193
- <p>
1194
- <strong><?php _e('Allow a POST or GET &#34;redirect_to&#34; logout variable to take redirect precedence', 'peters-login-redirect'); ?></strong>
1195
- </p>
1196
- </td>
1197
- <td>
1198
- <select name="rul_allow_post_redirect_override_logout">
1199
- <option value="1"<?php if ($rul_settings['rul_allow_post_redirect_override_logout']) print ' selected="selected"'; ?>><?php _e('Yes', 'peters-login-redirect'); ?></option>
1200
- <option value="0"<?php if ( ! $rul_settings['rul_allow_post_redirect_override_logout']) print ' selected="selected"'; ?>><?php _e('No', 'peters-login-redirect'); ?></option>
1201
- </select>
1202
- </td>
1203
- </tr>
1204
- </table>
1205
- <p class="submit">
1206
- <input class="button button-primary" name="rul_settingssubmit" type="submit" value="<?php _e('Update', 'peters-login-redirect'); ?>"/>
1207
- <?php wp_nonce_field('settings'); ?>
1208
- </p>
1209
- </form>
1210
- </div>
1211
- <?php
1212
- } // close rul_optionsmenu()
1213
-
1214
- /*
1215
- Add and remove database tables when installing and uninstalling
1216
- */
1217
-
1218
- // Perform upgrade functions
1219
- // Some newer operations are duplicated from rul_install() as there's no guarantee that the user will follow a specific upgrade procedure
1220
- function rul_upgrade()
1221
- {
1222
- global $wpdb, $rul_version, $rul_db_addresses;
1223
-
1224
- // Turn version into an integer for comparisons
1225
- $current_version = intval(str_replace('.', '', get_option('rul_version')));
1226
-
1227
- if ($current_version < 220) {
1228
- $wpdb->query("ALTER TABLE `$rul_db_addresses` ADD `rul_url_logout` LONGTEXT NOT NULL default '' AFTER `rul_url`");
1229
- }
1230
-
1231
- if ($current_version < 250) {
1232
- // Insert the "on-register" redirect entry
1233
-
1234
- $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_type` `rul_type` ENUM( 'user', 'role', 'level', 'all', 'register' ) NOT NULL");
1235
- $wpdb->insert($rul_db_addresses,
1236
- array('rul_type' => 'register')
1237
- );
1238
- }
1239
-
1240
- if ($current_version < 253) {
1241
- // Allow NULL values for non-essential fields
1242
- $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_value` `rul_value` varchar(255) NULL default NULL");
1243
- $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_url` `rul_url` LONGTEXT NULL default NULL");
1244
- $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_url_logout` `rul_url_logout` LONGTEXT NULL default NULL");
1245
- }
1246
-
1247
- if ($current_version < 291) {
1248
- // Reduce size of rul_value field to support utf8mb4 character encoding
1249
- $wpdb->query("ALTER TABLE `$rul_db_addresses` CHANGE `rul_value` `rul_value` varchar(191) NULL default NULL");
1250
- }
1251
-
1252
- if ($current_version != intval(str_replace('.', '', $rul_version))) {
1253
- // Add the version number to the database
1254
- delete_option('rul_version');
1255
- add_option('rul_version', $rul_version, '', 'no');
1256
- }
1257
- }
1258
-
1259
- function rul_install()
1260
- {
1261
- global $wpdb, $rul_db_addresses, $rul_version;
1262
-
1263
- // Add the table to hold group information and moderator rules
1264
- if ($rul_db_addresses != $wpdb->get_var("SHOW TABLES LIKE '$rul_db_addresses'")) {
1265
- $sql = "CREATE TABLE $rul_db_addresses (
1266
- `rul_type` enum('user','role','level','all','register') NOT NULL,
1267
- `rul_value` varchar(191) NULL default NULL,
1268
- `rul_url` LONGTEXT NULL default NULL,
1269
- `rul_url_logout` LONGTEXT NULL default NULL,
1270
- `rul_order` int(2) NOT NULL default '0',
1271
- UNIQUE KEY `rul_type` (`rul_type`,`rul_value`)
1272
- )";
1273
-
1274
- $wpdb->query($sql);
1275
-
1276
- // Insert the "all" redirect entry
1277
- $wpdb->insert($rul_db_addresses,
1278
- array('rul_type' => 'all')
1279
- );
1280
-
1281
- // Insert the "on-register" redirect entry
1282
- $wpdb->insert($rul_db_addresses,
1283
- array('rul_type' => 'register')
1284
- );
1285
-
1286
- // Set the version number in the database
1287
- add_option('rul_version', $rul_version, '', 'no');
1288
- }
1289
-
1290
- rul_upgrade();
1291
- }
1292
-
1293
- function rul_uninstall()
1294
- {
1295
- global $wpdb, $rul_db_addresses;
1296
-
1297
- // Remove the table we created
1298
- if ($rul_db_addresses == $wpdb->get_var('SHOW TABLES LIKE \'' . $rul_db_addresses . '\'')) {
1299
- $sql = 'DROP TABLE ' . $rul_db_addresses;
1300
- $wpdb->query($sql);
1301
- }
1302
-
1303
- delete_option('rul_version');
1304
- delete_option('rul_settings');
1305
- }
1306
-
1307
- function rul_addoptionsmenu()
1308
- {
1309
- add_options_page('Login/logout redirects', 'Login/logout redirects', 'manage_categories', 'wplogin_redirect.php', 'rul_optionsmenu');
1310
- }
1311
-
1312
- add_action('admin_menu', 'rul_addoptionsmenu', 1);
1313
- }
1314
-
1315
-
1316
- function rul_activate_plugin($networkwide)
1317
- {
1318
- // Executes when plugin is activated
1319
- global $wpdb, $rul_db_addresses;
1320
-
1321
- if (function_exists('is_multisite') && is_multisite() && $networkwide) {
1322
- $blogs = $wpdb->get_col("SELECT blog_id FROM $wpdb->blogs");
1323
- foreach ($blogs as $blog) {
1324
- switch_to_blog($blog);
1325
- $rul_db_addresses = $wpdb->prefix . 'login_redirects';
1326
- rul_install();
1327
- restore_current_blog();
1328
- }
1329
- } else {
1330
- rul_install();
1331
- }
1332
- }
1333
-
1334
- function rul_uninstall_plugin()
1335
- {
1336
- // Executes when plugin is deleted
1337
- global $wpdb, $rul_db_addresses;
1338
- if (function_exists('is_multisite') && is_multisite()) {
1339
- $blogs = $wpdb->get_col("SELECT blog_id FROM $wpdb->blogs");
1340
- foreach ($blogs as $blog) {
1341
- switch_to_blog($blog);
1342
- $rul_db_addresses = $wpdb->prefix . 'login_redirects';
1343
- rul_uninstall();
1344
- restore_current_blog();
1345
- }
1346
- } else {
1347
- rul_uninstall();
1348
- }
1349
- }
1350
-
1351
- function rul_site_added($blog)
1352
- {
1353
- // Executes when a site’s initialization routine should be executed.
1354
- global $wpdb, $rul_db_addresses;
1355
-
1356
- if ( ! is_int($blog)) {
1357
- $blog = $blog->id;
1358
- }
1359
-
1360
- switch_to_blog($blog);
1361
- $rul_db_addresses = $wpdb->prefix . 'login_redirects';
1362
- rul_install();
1363
- restore_current_blog();
1364
- }
1365
-
1366
- function rul_drop_tables($tables)
1367
- {
1368
- global $wpdb;
1369
- $tables[] = $wpdb->prefix . 'login_redirects';
1370
-
1371
- return $tables;
1372
- }
1373
-
1374
- register_activation_hook(__FILE__, 'rul_activate_plugin');
1375
- register_uninstall_hook(__FILE__, 'rul_uninstall_plugin');
1376
- add_filter('wpmu_drop_tables', 'rul_drop_tables');
1377
- add_action('activate_blog', 'rul_site_added');
1378
-
1379
- // Wpmu_new_blog has been deprecated in 5.1 and replaced by wp_insert_site.
1380
- global $wp_version;
1381
- if (version_compare($wp_version, '5.1', '<')) {
1382
- add_action('wpmu_new_blog', 'rul_site_added');
1383
- } else {
1384
- add_action('wp_initialize_site', 'rul_site_added', 99);
1385
- }
1386
 
1387
- add_filter('login_redirect', 'peters_redirect_wrapper', 999999999, 3);
1388
- add_filter('registration_redirect', array('rulRedirectPostRegistration', 'post_registration_wrapper'), 10, 2);
1389
- // whichever one works. directly below might not work if wp_logout function is redefined before ours kicks in.
1390
- add_action('wp_logout', array('rulLogoutFunctionCollection', 'logout_redirect'), 1);
1391
- add_filter('logout_redirect', array('rulLogoutFunctionCollection', 'logout_redirect_2'), 999999999, 3);
1
  <?php
2
  /*
3
+ Plugin Name: LoginWP (Formerly Peter's Login Redirect)
4
+ Plugin URI: https://loginwp.com
5
+ Description: Redirect users to different URLs based on their role, capability and more.
6
+ Version: 3.0.0.0
7
+ Author: LoginWP Team
8
+ Author URI: https://loginwp.com
9
  Text Domain: peters-login-redirect
10
+ Domain Path: /languages
11
+ License: GPL-2.0+
12
  */
13
 
14
+ use LoginWP\Core\Core;
15
 
16
+ require __DIR__ . '/vendor/autoload.php';
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
17
 
18
+ define('PTR_LOGINWP_SYSTEM_FILE_PATH', __FILE__);
19
+ define('PTR_LOGINWP_VERSION_NUMBER', '3.0.0.0');
 
 
 
 
 
 
 
 
 
 
 
 
 
20
 
21
+ add_action('init', function () {
22
+ load_plugin_textdomain('peters-login-redirect', false, dirname(plugin_basename(__FILE__)) . '/languages');
23
+ });
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
24
 
25
+ Core::get_instance();
 
 
 
 
wplogin_redirect_control.php CHANGED
@@ -1,17 +1,10 @@
1
  <?php
2
- // This assumes that this files sits in "wp-content/plugins/peters-login-redirect/wplogin_redirect_control.php" and that you haven't moved your wp-content folder
3
- if( file_exists( '../../../wp-load.php' ) )
4
- {
5
- include '../../../wp-load.php';
6
- }
7
- else
8
- {
9
- print 'Plugin paths not configured correctly.';
10
- }
11
 
12
- $current_user = wp_get_current_user();
13
- $redirect_to = admin_url();
14
- $redirect_url = peters_redirect_wrapper( $redirect_to, '', $current_user );
15
- wp_redirect( $redirect_url );
16
- die();
17
- ?>
 
1
  <?php
2
+ // This assumes that this files sits in "wp-content/plugins/peters-login-redirect/wplogin_redirect_control.php" and that you haven't moved your wp-content folder
 
 
 
 
 
 
 
 
3
 
4
+ if (file_exists('../../../wp-load.php')) {
5
+ include '../../../wp-load.php';
6
+ } else {
7
+ print 'Plugin paths not configured correctly.';
8
+ }
9
+
10
+ wplogin_redirect_control_function();