Skip to content

Commit 61d5976

Browse files
authored
Merge pull request #201 from ResponsiveMenu/dev
Release 4.1.12
2 parents 83c4cc6 + a91f69c commit 61d5976

File tree

5 files changed

+27
-25
lines changed

5 files changed

+27
-25
lines changed

readme.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Contributors: expresstech, responsivemenu, imvarunkmr, surajkumarsingh, infosate
33
Tags: responsive, mega menu, navigation, mobile, hamburger
44
Requires at least: 3.6
55
Tested up to: 6.0
6-
Stable tag: 4.1.11
6+
Stable tag: 4.1.12
77
Requires PHP: 5.6
88
License: GPLv2 or later
99
License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -120,6 +120,10 @@ To view our FAQ, please go to [https://responsive.menu/faq/](https://responsive.
120120

121121
== Changelog ==
122122

123+
= 4.1.12 (1st Aug 2022) =
124+
* Bug: Fixed conflict issues with conflict with Multiple Page Generator Plugin
125+
* Enhancement: Added timestamps as a version to generated CSS/JSS urls
126+
123127
= 4.1.11 (25th May 2022) =
124128
* Bug: Fixed conflict issues with Import Eventbrite Events plugin
125129
* Enhancement: Added rmp_nav_item_class hook to update nav item classes

responsive-menu.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Plugin Name: Responsive Menu
55
Plugin URI: https://expresstech.io
66
Description: Highly Customisable Responsive Menu Plugin for WordPress
7-
Version: 4.1.11
7+
Version: 4.1.12
88
Author: ExpressTech
99
Text Domain: responsive-menu
1010
Author URI: https://responsive.menu
@@ -16,7 +16,7 @@
1616
* Constant as plugin version.
1717
*/
1818
if ( ! defined( 'RMP_PLUGIN_VERSION' ) ) {
19-
define( 'RMP_PLUGIN_VERSION', '4.1.11' );
19+
define( 'RMP_PLUGIN_VERSION', '4.1.12' );
2020
}
2121

2222
define( 'RESPONSIVE_MENU_URL', plugin_dir_url( __FILE__ ) );

v4.0.0/inc/classes/class-style-manager.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ public function get_menus_scss_to_css() {
107107
*/
108108
public function save_style_css_on_file() {
109109
global $wp_filesystem;
110-
110+
update_option('rmp_dynamic_file_version', current_time('H.i.s') );
111111
if ( empty( $wp_filesystem ) ) {
112112
require_once ABSPATH . 'wp-admin/includes/file.php';
113113
}
@@ -152,7 +152,7 @@ public function enqueue_styles_as_file() {
152152
// Ensure we're using the correct protocol.
153153
$file_url = str_replace( array( 'http://', 'https://' ), $protocol, $file_url );
154154

155-
wp_enqueue_style( 'rmp-menu-styles', $file_url, false, substr( md5( filemtime( $file_path ) ), 0, 6 ) );
155+
wp_enqueue_style( 'rmp-menu-styles', $file_url, false, get_option('rmp_dynamic_file_version', wp_rand( 100, 1000 ) ) );
156156
}
157157
}
158158

v4.0.0/inc/helpers/custom-functions.php

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -98,16 +98,14 @@ function get_all_rmp_menu_ids() {
9898
'post_status' => 'publish',
9999
);
100100

101-
$query = new \WP_Query( $args );
101+
$all_menus = get_posts( $args );
102102
$menu_ids = array();
103103

104-
if ( $query->have_posts() ) {
105-
while ( $query->have_posts() ) {
106-
$query->the_post();
107-
$menu_ids[] = get_the_ID();
104+
if ( ! empty( $all_menus ) ) {
105+
foreach ( $all_menus as $menu ) {
106+
setup_postdata( $menu );
107+
$menu_ids[] = $menu->ID;
108108
}
109-
110-
wp_reset_postdata();
111109
}
112110

113111
return $menu_ids;
@@ -126,16 +124,14 @@ function rmp_get_all_menus() {
126124
'post_status' => 'publish',
127125
);
128126

129-
$query = new \WP_Query( $args );
127+
$all_menus = get_posts( $args );
130128
$menus = array();
131129

132-
if ( $query->have_posts() ) {
133-
while ( $query->have_posts() ) {
134-
$query->the_post();
135-
$menus[ get_the_ID() ] = get_the_title();
130+
if ( ! empty( $all_menus ) ) {
131+
foreach ( $all_menus as $menu ) {
132+
setup_postdata( $menu );
133+
$menus[ $menu->ID ] = $menu->post_title;
136134
}
137-
138-
wp_reset_postdata();
139135
}
140136

141137
return $menus;

v4.0.0/templates/rmp-editor.php

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2653,15 +2653,17 @@
26532653
'class' => 'no-updates',
26542654
'name' => 'menu[menu_width]',
26552655
'value' => rmp_get_value( $options, 'menu_width' ),
2656+
'multi_device' => true,
26562657
'group_classes' => 'full-size',
26572658
'placeholder' => esc_html__( 'Enter value', 'responsive-menu' ),
26582659
'has_unit' => array(
2659-
'unit_type' => 'all',
2660-
'id' => 'rmp-menu-container-width-unit',
2661-
'name' => 'menu[menu_width_unit]',
2662-
'default' => '%',
2663-
'classes' => 'is-unit no-updates',
2664-
'value' => rmp_get_value( $options, 'menu_width_unit' ),
2660+
'unit_type' => 'all',
2661+
'id' => 'rmp-menu-container-width-unit',
2662+
'name' => 'menu[menu_width_unit]',
2663+
'default' => '%',
2664+
'classes' => 'is-unit no-updates',
2665+
'value' => rmp_get_value( $options, 'menu_width_unit' ),
2666+
'multi_device' => true,
26652667
),
26662668
)
26672669
);

0 commit comments

Comments
 (0)