David Marín Carre?o
Forum Replies Created
-
Forum: Plugins
In reply to: [Random User IDs] Database HelpHi!
The plugin only carries out the user_id substitution in the default WordPress tables wp_users and wp_usermeta, and in the table wp_posts for the post_author meta.
You should check your database, checking for tables including user_id columns, or metadata tables checking for metadata referencing user ids.
Certainly, this is a bit tricky step, but unfortunately I cannot give support to the whole WordPress ecosystem!
Hi!
The thing you are probably seeing is that they are assigned a very high number instead of the probably-expected lower ID.
New users won’t have a random IDs any longer, but sequential ones.
I’m afraid there’s nothing we can do about this: when generating the next user_id, MySQL will take the highest existing user_id and add one to it.
Forum: Themes and Templates
In reply to: [Blocksy] Remove extra deprecations in PHP 8.1Hi!
I confirm the deprecation warnings are now solved with version 1.8.69.
Thanks for your kind support.
Forum: Themes and Templates
In reply to: [Blocksy] Remove extra deprecations in PHP 8.1I just checked again, and only one of the three targeted deprecations had already been solved.
This would be the correct patch for the last version of Blocksy
diff --git a/inc/components/hero-section.php b/inc/components/hero-section.php index 8c8c06b93..3e18067b5 100644 --- a/inc/components/hero-section.php +++ b/inc/components/hero-section.php @@ -38,7 +38,7 @@ if (! function_exists('blocksy_get_page_title_source')) { return $result; } - if (strpos($prefix, 'single') !== false || ( + if (strpos($prefix ?? '', 'single') !== false || ( function_exists('is_shop') && is_shop() ) && ! is_search()) { $post_options = blocksy_get_post_options(); diff --git a/inc/sidebar.php b/inc/sidebar.php index 0f4b1d248..20e411c88 100644 --- a/inc/sidebar.php +++ b/inc/sidebar.php @@ -182,7 +182,7 @@ if (! function_exists('blocksy_sidebar_position_unfiltered')) { ]); if ( - strpos($prefix, '_archive') !== false + strpos($prefix ?? '', '_archive') !== false || $prefix === 'search' || @@ -220,7 +220,7 @@ if (! function_exists('blocksy_sidebar_position_unfiltered')) { && $prefix !== 'product' && - strpos($prefix, '_single') === false + strpos($prefix ?? '', '_single') === false && ( $prefix !== 'courses_archive'
I’m afraid that, at this moment, the plugin doesn’t allow associating more than one role to a given product, or having a role removed after completing a purchase.
I’m totally open to contributions to https://github.com/davefx/dfx-woo-role-changer in order to add these features.
Marking support thread as resolved
Forum: Plugins
In reply to: [Stream] FILTER_SANITIZE_STRING deprecatedYes, please: could you fix this to add full compatibility with PHP 8.1?
Forum: Plugins
In reply to: [Random User IDs] Custom Prefixed User IDWhat you are talking about is related, but totally different to what this plugin does, as this plugin focuses on modifying the actual WordPress UserID for new users. As you say, your required Custom User ID would be different from the User ID that WordPress or WooCommerce creates at Registration.
As you say, this is a totally-different user ID, and your requisites are very specific and related to your project.
I’m afraid I’m not interested in adding this custom-user-ID logic to the plugin.
In order to achieve what you need you, basically, will need to create a new User metadata with your custom User ID whenever a user is created, following your specified criteria, and then use it as needed.
Best regards.
Forum: Plugins
In reply to: [Random User IDs] Plugin no longer supported?The plugin is totally open source, and you already can contribute Pull Requests for it at https://github.com/davefx/dfx-random-user-id
Best regards.
Forum: Plugins
In reply to: [Random User IDs] Custom Prefixed User IDSorry, this would be a totally different feature to the one offered by this plugin. I’m afraid I don’t know of any other plugin that offers what you need.
Best regards.
Forum: Plugins
In reply to: [Random User IDs] Plugin no longer supported?Hi. The plugin keeps being supported, and is updated periodically.
Maybe not with the frequency WordPress wants, though!
The code keeps working with the last versions.No, I’m sorry.
This plugin just associates the purchase of a given product with a role.Thanks a lot!
Forum: Plugins
In reply to: [Random User IDs] How to Undo What This Plugin Just ChangedTo undo the actions taken by the plugin:
1. Determine the new ID for the first admin user:
SELECT option_value FROM wp_options WHERE option_name='dfx_randomuserid_first_user_moved_to';
2. Then, use the following queries to undo the changes, replacing
<NEW_ID>
with the value obtained in the previous step:UPDATE wp_posts SET post_author=1 WHERE post_author=<NEW_ID>; UPDATE wp_users SET ID = 1 WHERE ID = <NEW_ID>; UPDATE wp_usermeta SET user_id = 1 WHERE user_id = <NEW_ID>;
After this, you’ll be able to keep the plugin installed. The ID for new users will still be randomized.
- This reply was modified 3 years, 1 month ago by David Marín Carre?o.
- This reply was modified 3 years, 1 month ago by David Marín Carre?o.
- This reply was modified 3 years, 1 month ago by David Marín Carre?o.
Forum: Plugins
In reply to: [Random User IDs] exponential User ID numberI’m a bit concerned about the problem you’ve found.
Have you changed anything else in the last months? (database engine, PHP version…)You can always limit the max user number ID generated by the plugin by using the filter dfx_random_user_id_max_id as noted in the documentation:
function set_dfx_max_user_id( $default_max_id ) { return 999999; } add_filter( 'dfx_random_user_id_max_id', 'set_dfx_max_user_id' );