• Plugin Author Chad Butler

    (@cbutlerjr)


    There are significant changes in WP-Members 3.5.5 that pertain to where it stores uploaded media when using either the file or image field types in your WP-Members registration form. The update to 3.5.5 includes a utility script you can run to make changes to the paths for any existing uploaded files.

    NOTE: This change does not affect all users of the plugin. If you do not use a file or image field type in your WP-Members registration fields, then this does not apply. Also, although changing the deprectated path is recommended, it is not mandatory and the notice message in the admin can be suppressed if so desired.

    The nature of the change is that uploaded files now will use a random hash for the upload folder name, a random hash for the specific user folder, and a random hash for the file name.

    Because files are uploaded as WordPress attachment post types, there is more involved in “moving” than simply changing directory names in the filesystem. The information in the WP database must also be updated for each file.

    If your install contains any attachment post types that match the deprecated file path, there will be a notice message in the WordPress dashboard indicating such. It will direct you to the WP-Members admin tab for updating the file path. (If you choose to not update the path, or wish to do it at a later time but want to suppress the notice message, there is an option for that in the admin panel as well.)

    There are two possible options for updating the file path: WP-CLI or through the admin panel in the browser.

    The WP-CLI process is recommended, especially if you have a large number of users and/or a large number of files.

    You can review a more detailed explanation of the change and the update here.

    There are instructions for using either of the update utilities at the following links:

    In either instance, the process is two-stage. First, it will copy the files to the new location and update the WP database. This first step does not delete any of the existing files. Once you have completed the first stage, you can run the second stage to delete the old files.

    In either case, it is highly recommended that you back up both your database and your file system in case you need to rollback. The first stage makes changes in the WordPress database as well as creating files in the new path. The second stage deletes the old path and files.

    Once the process has been completed, the utility tab and notice message will no longer appear in the WP admin.

    • This topic was modified 3 months, 3 weeks ago by Chad Butler.

You must be logged in to reply to this topic.