For the past 9 months, I have been working diligently on the biggest update WP-Members has seen in quite some time. Version 3.2.0 will implement some new features that will expand the flexibility of the plugin and bring in new features that I’ve been wanting to incorporate for awhile.
Here is a run-down of some of the updates you can expect to see.
“Hide” as an option for blocking posts (or other content)
This is in addition of the current “block” and “unblock” with “hide” giving the added step of removing the post completely from existence if the user is not logged in. Note that currently this is only a setting for individual posts/pages/content; it is not yet available as a default option.
“Membership Products” custom post type for creating membership products.
Products can be different membership products you may wish to offer. This can be used for levels, access groups, single content, files, etc. Product access can expire or be indefinite.
Currently, this is a very “open” item. I expect this feature will likely be used mostly with WooCommerce, but could be adapted to other concepts. At present, and likely continuing into release, it is a “manual” process unless you specifically hook an update to the registration or purchase of a product. I’ll be writing more about that in the documentation. I did not want to build it into something that couldn’t be extended/expanded later since I know that the plugin’s users will likely come up with questions and ideas that drive its ultimate development. So for now, I’m “introducing” it as a feature with the intention that it’s ultimate direction will be user driven (hope that makes sense).
View forms when logged into the Customizer
The WordPress Customizer is a great tool for customizing your WP install. Since WP 4.7, the Customizer allows you to apply custom CSS directly while working in the Customizer. This is great for being able to work on integrating plugin output to blend seamlessly with your theme. Even though WP-Members has allowed you to apply a custom stylesheet since early 2.x, the Customizer makes it even easier to get that seamless look.
One small problem with this has been that the Customizer requires you to be logged in, and that basically precludes viewing the login and registration form. Sure, the core forms are also used for forgot password and user profile update, but there are some elements that are uniquely part of the login form that you may want to work on.
So in 3.2, you’ll have the option of viewing the forms for working with the Customizer. The Customizer will include a “WP-Members” menu item that will have a switch to display the forms as it would to a logged out user. Initially, this is for the login, registration, and widget forms; but I plan to work on adding the others later.
Logged in menus
The Logged In Menus premium extension will no longer be supported and its functionality will be incorporated into the main plugin in 3.2.0. This will start with there being a cloned menu area for each menu area your theme creates so that you can created a logged in menu and another for non-logged in users.
Username now in the Fields array
The username field is now part of the fields array. Previously, the field was added to the registration form automatically, so it was always at the beginning of the form. Adding it to the fields array allows for you to move it in the form order by drag-and-drop just like any other field, rather than having to use a filter to move it.
One important note if you are testing 3.2.0 prior to production (or even after) and you need to roll back to 3.1.x – after you roll back versions, you will need to go to the Fields tab to delete the username field from the fields array. Otherwise you’ll end up with it in the form twice.
Login/Logout menu link
- Changed default address meta fields to match WooCommerce billing meta fields. Now the default install will utilize the same field metas as WooCommerce. Of course, as always, you can delete the default fields and install your own. Also, this only affects new installs. As has always been the case, the plugin’s upgrade process does not interfere with existing fields, and you can customize fields as needed.
- Speaking of customizing fields, you can now customize field labels for native WP fields used in the form.
- Rebuild of user export function; now uses PHP’s fputcsv. This will lead to a more flexible process and I hope to introduce custom exports in future versions.
- Code improvement for enqueueing styles.
- Updated the WP-Members widget, added widget_title filter before wpmem_widget_title, documented wpmem_widget_id filter, and added instance and id_base parameters.
- Deprecated a number of outdated functions and functions that have been replaced.
- Updated to maintain the user login state when a user updates their password (i.e. keeps them logged in).
- Updated the login form redirect_to parameter to account for query string variables.
- Fixed issue with login status if logout url is encoded.
- Removed outdated stylesheets from selection (although the stylesheets remain in the plugin in case any users are using them).
- Added new API functions:
- Some others are pending and may still make it into the final 3.2.0 release.
- Added new filter/action hooks:
- HTML5 updates:
- form anchor tags changed from “name” to “id”.
- form id tags set default value (can still be filtered).
- removed “align” attribute (in captcha and link-text).
The functions that run the Users > All Users screen received a sizeable update. I accounted for any untranslated strings, reworked the various queries to make the process more efficient than it was, and added a new screen to show only “deactivated” users (if moderated registration is enabled).
There were some additional improvements to various admin side processing as well, including the ability to filter the HTML markup for custom fields that are displayed in the admin/dashboard user profile. Also on the admin side, I improved the process for adding/editing custom fields so that required information has HTML5 markup to make it required before submission. This will hopefully eliminate users thinking they added a field when it was not actually added due to missing a required setting (such as setting a checked value for a checkbox – the most common issue).
There are currently over 135 committed changes in this update, with likely some more to come as I finish up some remaining feature updates and continue to debug.
With the exception of the new Products custom post type not yet fully complete, the update is pretty much ready for testing, so I encourage you to try it out. One thing I want to point out is that this is still considered beta software and is NOT considered production ready (although I am using it live on the rocketgeek.com site). Please test it out on a test site prior to updating a production site. Also consider that there may still be some changes that are not included in beta version.
If you do test and run across any issues, please let me know. Regardless of whether you are a support subscriber or not, use the contact form to submit any issues you discover with 3.2.0 beta. Indicate in the subject line that this is specific to the 3.2.0 beta.
Get the most recent builds here: