- added localized variable;

This commit is contained in:
nikitasinelnikov
2021-05-10 17:13:17 +03:00
parent 8e92aa8c45
commit 504818412c
3 changed files with 15 additions and 2 deletions
+9 -1
View File
@@ -149,8 +149,16 @@ if ( ! class_exists( 'um\core\Enqueue' ) ) {
* }
* ?>
*/
$max_upload_size = wp_max_upload_size();
if ( ! $max_upload_size ) {
$max_upload_size = 0;
}
$localize_data = apply_filters( 'um_enqueue_localize_data', array(
'nonce' => wp_create_nonce( "um-frontend-nonce" ),
'max_upload_size' => $max_upload_size,
'nonce' => wp_create_nonce( "um-frontend-nonce" ),
) );
wp_localize_script( 'um_scripts', 'um_scripts', $localize_data );
+5
View File
@@ -155,6 +155,11 @@ The plugin works with popular caching plugins by automatically excluding Ultimat
* To learn more about version 2.1 please see this [docs](https://docs.ultimatemember.com/article/1512-upgrade-2-1-0)
* UM2.1+ is a significant update to the Member Directories' code base from 2.0.x. Please make sure you take a full-site backup with restore point before updating the plugin
= 2.1.21: June xx, 2021 =
* Enhancements:
- Added: `um_scripts.max_upload_size` localized variable getting from `wp_max_upload_size()`
= 2.1.20: May 7, 2021 =
* Enhancements:
+1 -1
View File
@@ -3,7 +3,7 @@
Plugin Name: Ultimate Member
Plugin URI: http://ultimatemember.com/
Description: The easiest way to create powerful online communities and beautiful user profiles with WordPress
Version: 2.1.20
Version: 2.1.21-alpha
Author: Ultimate Member
Author URI: http://ultimatemember.com/
Text Domain: ultimate-member