This is an example of adding a very simple invitation code to your registration process. In this example, we will add an invitation code field to the form and set up a function to validate that code. To keep it simple, the invitation code will be static (there will be only one code). Later I will be publishing a more advanced example where you can read user specific codes from a database table, validate, and also mark the code as claimed. Continue Reading →
tips
Email users when a new post is published
This tip is a request from a user. I like user requests – that makes it easier to deliver the kind of tutorials users are looking for instead of things I just come up with on my own.
This particular tip will address how you can automatically send an email to all users when a post is published or updated. Continue Reading →
Create different styles for “success” and “error” messages
This is an idea that has been floated by a few users, which means there is probably a need for it. As is usually the case, I don’t like to make wholesale changes to the codebase that effects users in a way that requires them to make a change to accommodate an update. So I wouldn’t want to change the plugin to put in different classes, since users with a custom stylesheet would need to be paying attention when they update to accommodate the new classes in their stylesheet. But this is something that we can certainly do on the fly using the wpmem_msg_dialog filter. This article will show you how to do just that. Continue Reading →
Create a wp-members-pluggable.php file so that it is editable in the plugin editor
WP-Members looks for a wp-members-pluggable.php file when it loads. This is where you can store your plugged versions of the WP-Members pluggable functions. To create the pluggable file, you need do nothing more than create a file named wp-members-pluggable.php and save it to your WordPress plugins folder.
But what if you would like to be able to edit this file within the WordPress admin panel using the plugin editor? This is a way for you to accomplish that. Continue Reading →
Create a sidebar login status and logout link
In some layouts, you may wish to not use the WP-Members sidebar widget for logging users in, but you may still want to display a user’s login status (when logged in) and provide a logout link. Here is how you can do that with a plain text widget. Continue Reading →