Changeset 2845744
- Timestamp:
- 01/09/2023 11:34:55 PM (3 years ago)
- Location:
- juvo-ws-form-login
- Files:
-
- 18 edited
- 1 copied
-
tags/1.0.3 (copied) (copied from juvo-ws-form-login/trunk)
-
tags/1.0.3/README.txt (modified) (2 diffs)
-
tags/1.0.3/src/Integrations/Members/Unblock.php (modified) (2 diffs)
-
tags/1.0.3/src/Options_Page.php (modified) (1 diff)
-
tags/1.0.3/src/Redirect.php (modified) (4 diffs)
-
tags/1.0.3/src/WSForm_Login.php (modified) (2 diffs)
-
tags/1.0.3/vendor/autoload.php (modified) (1 diff)
-
tags/1.0.3/vendor/composer/autoload_real.php (modified) (3 diffs)
-
tags/1.0.3/vendor/composer/autoload_static.php (modified) (2 diffs)
-
tags/1.0.3/vendor/composer/installed.php (modified) (2 diffs)
-
trunk/README.txt (modified) (2 diffs)
-
trunk/src/Integrations/Members/Unblock.php (modified) (2 diffs)
-
trunk/src/Options_Page.php (modified) (1 diff)
-
trunk/src/Redirect.php (modified) (4 diffs)
-
trunk/src/WSForm_Login.php (modified) (2 diffs)
-
trunk/vendor/autoload.php (modified) (1 diff)
-
trunk/vendor/composer/autoload_real.php (modified) (3 diffs)
-
trunk/vendor/composer/autoload_static.php (modified) (2 diffs)
-
trunk/vendor/composer/installed.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
juvo-ws-form-login/tags/1.0.3/README.txt
r2845555 r2845744 5 5 Requires at least: 5.6 6 6 Tested up to: 6.1 7 Stable tag: 1.0. 27 Stable tag: 1.0.3 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 26 26 27 27 == Changelog == 28 = 1.0.3 = 29 - Whitelist wsform rest calls within the members plugin 30 - Add registration page support 31 28 32 = 1.0.2 = 29 33 Fix wsform install check -
juvo-ws-form-login/tags/1.0.3/src/Integrations/Members/Unblock.php
r2838165 r2845744 16 16 cmb2_get_option( 'wsform_login', 'login', null ), 17 17 cmb2_get_option( 'wsform_login', 'forgot_password', null ), 18 cmb2_get_option( 'wsform_login', 'reset_password', null ) 18 cmb2_get_option( 'wsform_login', 'reset_password', null ), 19 cmb2_get_option( 'wsform_login', 'registration', null ) 19 20 ]; 20 21 … … 27 28 } 28 29 30 public function unblock_rest_api(bool $is_private) { 31 32 // Allow ws form rest api requests 33 if (strpos($_SERVER['REQUEST_URI'], 'wp-json/ws-form') !== false) { 34 return false; 35 } 36 37 return $is_private; 38 39 } 40 29 41 } -
juvo-ws-form-login/tags/1.0.3/src/Options_Page.php
r2838165 r2845744 44 44 $main_options->add_field(array( 45 45 'name' => __('Reset Password Page', 'wsform-login'), 46 'desc' => __('Type the title of the page that contains reset password', 'wsform-login'),46 'desc' => __('Type the title of the page that contains the reset password form', 'wsform-login'), 47 47 'id' => 'reset_password', 48 'type' => 'post_ajax_search', 49 'query_args' => array( 50 'post_type' => array('post', 'page'), 51 'posts_per_page' => -1 52 ) 53 )); 54 55 $main_options->add_field(array( 56 'name' => __('Registration Page', 'wsform-login'), 57 'desc' => __('Type the title of the page that contains the registration form', 'wsform-login'), 58 'id' => 'registration', 48 59 'type' => 'post_ajax_search', 49 60 'query_args' => array( -
juvo-ws-form-login/tags/1.0.3/src/Redirect.php
r2838165 r2845744 6 6 7 7 /** 8 * Filters the login URL 8 * Filters the login URL and sets it to the page selected on the options page 9 9 * 10 10 * @param string $url The login URL. Not HTML-encoded. … … 41 41 42 42 /** 43 * Filters the password reset url 43 * Filters the password reset url and sets it to the page selected on the options page 44 44 * 45 45 * @param $url … … 47 47 * @return string 48 48 */ 49 public function lostpassword_url( $url, $redirect ) {49 public function lostpassword_url( $url, $redirect ) { 50 50 51 51 $post_id = (int) cmb2_get_option( 'wsform_login', 'forgot_password' ); … … 61 61 62 62 /** 63 * Filters the registration url and sets it to the page selected on the options page 64 * 65 * @param string $url 66 * @return string 67 */ 68 public function registration_url( string $url ): string { 69 $post_id = (int) cmb2_get_option( 'wsform_login', 'registration' ); 70 if (empty($post_id)) { 71 return $url; 72 } 73 return get_permalink($post_id); 74 } 75 76 /** 77 * Filter the string to maybe add a redirect parameter 78 * 63 79 * @param string $url 64 80 * @param string|null $redirect -
juvo-ws-form-login/tags/1.0.3/src/WSForm_Login.php
r2845555 r2845744 112 112 $this->loader->add_filter('login_url', $redirect, 'login_url', 10, 3); 113 113 $this->loader->add_filter('lostpassword_url', $redirect, 'lostpassword_url', 11, 2); 114 $this->loader->add_filter('register_url', $redirect, 'registration_url', 11); 114 115 115 116 // Integrations - Members 116 117 $this->loader->add_filter('members_is_private_page', new Integrations\Members\Unblock(), 'unblock'); 117 118 $this->loader->add_filter('members_is_private_rest_api', new Integrations\Members\Unblock(), 'unblock_rest_api'); 118 119 } 119 120 … … 155 156 } 156 157 158 // Run loader to add all filters/actions 157 159 $this->loader->run(); 158 160 159 161 }, 20); 160 162 163 // Also run loader before plugins_loaded e.g. for api 164 $this->loader->run(); 161 165 162 166 } -
juvo-ws-form-login/tags/1.0.3/vendor/autoload.php
r2845555 r2845744 23 23 require_once __DIR__ . '/composer/autoload_real.php'; 24 24 25 return ComposerAutoloaderInit 589a3896b06159f9af328ce6101f7686::getLoader();25 return ComposerAutoloaderInitef3deff15cd20be450783ba9d63b7e3c::getLoader(); -
juvo-ws-form-login/tags/1.0.3/vendor/composer/autoload_real.php
r2845555 r2845744 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit 589a3896b06159f9af328ce6101f76865 class ComposerAutoloaderInitef3deff15cd20be450783ba9d63b7e3c 6 6 { 7 7 private static $loader; … … 23 23 } 24 24 25 spl_autoload_register(array('ComposerAutoloaderInit 589a3896b06159f9af328ce6101f7686', 'loadClassLoader'), true, true);25 spl_autoload_register(array('ComposerAutoloaderInitef3deff15cd20be450783ba9d63b7e3c', 'loadClassLoader'), true, true); 26 26 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); 27 spl_autoload_unregister(array('ComposerAutoloaderInit 589a3896b06159f9af328ce6101f7686', 'loadClassLoader'));27 spl_autoload_unregister(array('ComposerAutoloaderInitef3deff15cd20be450783ba9d63b7e3c', 'loadClassLoader')); 28 28 29 29 require __DIR__ . '/autoload_static.php'; 30 call_user_func(\Composer\Autoload\ComposerStaticInit 589a3896b06159f9af328ce6101f7686::getInitializer($loader));30 call_user_func(\Composer\Autoload\ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::getInitializer($loader)); 31 31 32 32 $loader->register(true); 33 33 34 $includeFiles = \Composer\Autoload\ComposerStaticInit 589a3896b06159f9af328ce6101f7686::$files;34 $includeFiles = \Composer\Autoload\ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::$files; 35 35 foreach ($includeFiles as $fileIdentifier => $file) { 36 composerRequire 589a3896b06159f9af328ce6101f7686($fileIdentifier, $file);36 composerRequireef3deff15cd20be450783ba9d63b7e3c($fileIdentifier, $file); 37 37 } 38 38 … … 46 46 * @return void 47 47 */ 48 function composerRequire 589a3896b06159f9af328ce6101f7686($fileIdentifier, $file)48 function composerRequireef3deff15cd20be450783ba9d63b7e3c($fileIdentifier, $file) 49 49 { 50 50 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { -
juvo-ws-form-login/tags/1.0.3/vendor/composer/autoload_static.php
r2845555 r2845744 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit 589a3896b06159f9af328ce6101f76867 class ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c 8 8 { 9 9 public static $files = array ( … … 43 43 { 44 44 return \Closure::bind(function () use ($loader) { 45 $loader->prefixLengthsPsr4 = ComposerStaticInit 589a3896b06159f9af328ce6101f7686::$prefixLengthsPsr4;46 $loader->prefixDirsPsr4 = ComposerStaticInit 589a3896b06159f9af328ce6101f7686::$prefixDirsPsr4;47 $loader->classMap = ComposerStaticInit 589a3896b06159f9af328ce6101f7686::$classMap;45 $loader->prefixLengthsPsr4 = ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::$prefixLengthsPsr4; 46 $loader->prefixDirsPsr4 = ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::$prefixDirsPsr4; 47 $loader->classMap = ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::$classMap; 48 48 49 49 }, null, ClassLoader::class); -
juvo-ws-form-login/tags/1.0.3/vendor/composer/installed.php
r2845555 r2845744 2 2 'root' => array( 3 3 'name' => 'juvo/demo-plugin', 4 'pretty_version' => '1.0. 2',5 'version' => '1.0. 2.0',6 'reference' => ' 2153771e26f20272e8a0269a3842e8028f594db6',4 'pretty_version' => '1.0.3', 5 'version' => '1.0.3.0', 6 'reference' => '425ca33c4536b6444477458f1abd8da985defe22', 7 7 'type' => 'library', 8 8 'install_path' => __DIR__ . '/../../', … … 21 21 ), 22 22 'juvo/demo-plugin' => array( 23 'pretty_version' => '1.0. 2',24 'version' => '1.0. 2.0',25 'reference' => ' 2153771e26f20272e8a0269a3842e8028f594db6',23 'pretty_version' => '1.0.3', 24 'version' => '1.0.3.0', 25 'reference' => '425ca33c4536b6444477458f1abd8da985defe22', 26 26 'type' => 'library', 27 27 'install_path' => __DIR__ . '/../../', -
juvo-ws-form-login/trunk/README.txt
r2845555 r2845744 5 5 Requires at least: 5.6 6 6 Tested up to: 6.1 7 Stable tag: 1.0. 27 Stable tag: 1.0.3 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 26 26 27 27 == Changelog == 28 = 1.0.3 = 29 - Whitelist wsform rest calls within the members plugin 30 - Add registration page support 31 28 32 = 1.0.2 = 29 33 Fix wsform install check -
juvo-ws-form-login/trunk/src/Integrations/Members/Unblock.php
r2838165 r2845744 16 16 cmb2_get_option( 'wsform_login', 'login', null ), 17 17 cmb2_get_option( 'wsform_login', 'forgot_password', null ), 18 cmb2_get_option( 'wsform_login', 'reset_password', null ) 18 cmb2_get_option( 'wsform_login', 'reset_password', null ), 19 cmb2_get_option( 'wsform_login', 'registration', null ) 19 20 ]; 20 21 … … 27 28 } 28 29 30 public function unblock_rest_api(bool $is_private) { 31 32 // Allow ws form rest api requests 33 if (strpos($_SERVER['REQUEST_URI'], 'wp-json/ws-form') !== false) { 34 return false; 35 } 36 37 return $is_private; 38 39 } 40 29 41 } -
juvo-ws-form-login/trunk/src/Options_Page.php
r2838165 r2845744 44 44 $main_options->add_field(array( 45 45 'name' => __('Reset Password Page', 'wsform-login'), 46 'desc' => __('Type the title of the page that contains reset password', 'wsform-login'),46 'desc' => __('Type the title of the page that contains the reset password form', 'wsform-login'), 47 47 'id' => 'reset_password', 48 'type' => 'post_ajax_search', 49 'query_args' => array( 50 'post_type' => array('post', 'page'), 51 'posts_per_page' => -1 52 ) 53 )); 54 55 $main_options->add_field(array( 56 'name' => __('Registration Page', 'wsform-login'), 57 'desc' => __('Type the title of the page that contains the registration form', 'wsform-login'), 58 'id' => 'registration', 48 59 'type' => 'post_ajax_search', 49 60 'query_args' => array( -
juvo-ws-form-login/trunk/src/Redirect.php
r2838165 r2845744 6 6 7 7 /** 8 * Filters the login URL 8 * Filters the login URL and sets it to the page selected on the options page 9 9 * 10 10 * @param string $url The login URL. Not HTML-encoded. … … 41 41 42 42 /** 43 * Filters the password reset url 43 * Filters the password reset url and sets it to the page selected on the options page 44 44 * 45 45 * @param $url … … 47 47 * @return string 48 48 */ 49 public function lostpassword_url( $url, $redirect ) {49 public function lostpassword_url( $url, $redirect ) { 50 50 51 51 $post_id = (int) cmb2_get_option( 'wsform_login', 'forgot_password' ); … … 61 61 62 62 /** 63 * Filters the registration url and sets it to the page selected on the options page 64 * 65 * @param string $url 66 * @return string 67 */ 68 public function registration_url( string $url ): string { 69 $post_id = (int) cmb2_get_option( 'wsform_login', 'registration' ); 70 if (empty($post_id)) { 71 return $url; 72 } 73 return get_permalink($post_id); 74 } 75 76 /** 77 * Filter the string to maybe add a redirect parameter 78 * 63 79 * @param string $url 64 80 * @param string|null $redirect -
juvo-ws-form-login/trunk/src/WSForm_Login.php
r2845555 r2845744 112 112 $this->loader->add_filter('login_url', $redirect, 'login_url', 10, 3); 113 113 $this->loader->add_filter('lostpassword_url', $redirect, 'lostpassword_url', 11, 2); 114 $this->loader->add_filter('register_url', $redirect, 'registration_url', 11); 114 115 115 116 // Integrations - Members 116 117 $this->loader->add_filter('members_is_private_page', new Integrations\Members\Unblock(), 'unblock'); 117 118 $this->loader->add_filter('members_is_private_rest_api', new Integrations\Members\Unblock(), 'unblock_rest_api'); 118 119 } 119 120 … … 155 156 } 156 157 158 // Run loader to add all filters/actions 157 159 $this->loader->run(); 158 160 159 161 }, 20); 160 162 163 // Also run loader before plugins_loaded e.g. for api 164 $this->loader->run(); 161 165 162 166 } -
juvo-ws-form-login/trunk/vendor/autoload.php
r2845555 r2845744 23 23 require_once __DIR__ . '/composer/autoload_real.php'; 24 24 25 return ComposerAutoloaderInit 589a3896b06159f9af328ce6101f7686::getLoader();25 return ComposerAutoloaderInitef3deff15cd20be450783ba9d63b7e3c::getLoader(); -
juvo-ws-form-login/trunk/vendor/composer/autoload_real.php
r2845555 r2845744 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit 589a3896b06159f9af328ce6101f76865 class ComposerAutoloaderInitef3deff15cd20be450783ba9d63b7e3c 6 6 { 7 7 private static $loader; … … 23 23 } 24 24 25 spl_autoload_register(array('ComposerAutoloaderInit 589a3896b06159f9af328ce6101f7686', 'loadClassLoader'), true, true);25 spl_autoload_register(array('ComposerAutoloaderInitef3deff15cd20be450783ba9d63b7e3c', 'loadClassLoader'), true, true); 26 26 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__)); 27 spl_autoload_unregister(array('ComposerAutoloaderInit 589a3896b06159f9af328ce6101f7686', 'loadClassLoader'));27 spl_autoload_unregister(array('ComposerAutoloaderInitef3deff15cd20be450783ba9d63b7e3c', 'loadClassLoader')); 28 28 29 29 require __DIR__ . '/autoload_static.php'; 30 call_user_func(\Composer\Autoload\ComposerStaticInit 589a3896b06159f9af328ce6101f7686::getInitializer($loader));30 call_user_func(\Composer\Autoload\ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::getInitializer($loader)); 31 31 32 32 $loader->register(true); 33 33 34 $includeFiles = \Composer\Autoload\ComposerStaticInit 589a3896b06159f9af328ce6101f7686::$files;34 $includeFiles = \Composer\Autoload\ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::$files; 35 35 foreach ($includeFiles as $fileIdentifier => $file) { 36 composerRequire 589a3896b06159f9af328ce6101f7686($fileIdentifier, $file);36 composerRequireef3deff15cd20be450783ba9d63b7e3c($fileIdentifier, $file); 37 37 } 38 38 … … 46 46 * @return void 47 47 */ 48 function composerRequire 589a3896b06159f9af328ce6101f7686($fileIdentifier, $file)48 function composerRequireef3deff15cd20be450783ba9d63b7e3c($fileIdentifier, $file) 49 49 { 50 50 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { -
juvo-ws-form-login/trunk/vendor/composer/autoload_static.php
r2845555 r2845744 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit 589a3896b06159f9af328ce6101f76867 class ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c 8 8 { 9 9 public static $files = array ( … … 43 43 { 44 44 return \Closure::bind(function () use ($loader) { 45 $loader->prefixLengthsPsr4 = ComposerStaticInit 589a3896b06159f9af328ce6101f7686::$prefixLengthsPsr4;46 $loader->prefixDirsPsr4 = ComposerStaticInit 589a3896b06159f9af328ce6101f7686::$prefixDirsPsr4;47 $loader->classMap = ComposerStaticInit 589a3896b06159f9af328ce6101f7686::$classMap;45 $loader->prefixLengthsPsr4 = ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::$prefixLengthsPsr4; 46 $loader->prefixDirsPsr4 = ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::$prefixDirsPsr4; 47 $loader->classMap = ComposerStaticInitef3deff15cd20be450783ba9d63b7e3c::$classMap; 48 48 49 49 }, null, ClassLoader::class); -
juvo-ws-form-login/trunk/vendor/composer/installed.php
r2845555 r2845744 2 2 'root' => array( 3 3 'name' => 'juvo/demo-plugin', 4 'pretty_version' => '1.0. 2',5 'version' => '1.0. 2.0',6 'reference' => ' 2153771e26f20272e8a0269a3842e8028f594db6',4 'pretty_version' => '1.0.3', 5 'version' => '1.0.3.0', 6 'reference' => '425ca33c4536b6444477458f1abd8da985defe22', 7 7 'type' => 'library', 8 8 'install_path' => __DIR__ . '/../../', … … 21 21 ), 22 22 'juvo/demo-plugin' => array( 23 'pretty_version' => '1.0. 2',24 'version' => '1.0. 2.0',25 'reference' => ' 2153771e26f20272e8a0269a3842e8028f594db6',23 'pretty_version' => '1.0.3', 24 'version' => '1.0.3.0', 25 'reference' => '425ca33c4536b6444477458f1abd8da985defe22', 26 26 'type' => 'library', 27 27 'install_path' => __DIR__ . '/../../',
Note: See TracChangeset
for help on using the changeset viewer.