The Advanced Access Manager extension allows you to create advanced download limitations per download and on a global level.
- Unzip and upload the plugin’s folder to your /wp-content/plugins/ directory
- Activate the extension through the ‘Plugins’ menu in WordPress
For more information on installing and managing plugins see here.
After installing the extension, you can set up access rules per download or on a global level. The rules used per download and in global are the same, so they are only documented once.
Managing Access Rules
Every download will have a new meta box under the content field titled ‘Advanced Access Rules’. You can create, edit, order, and delete the download-specific access rules in this box. Rules will be loaded in order of display, top first, and will try to be matched to the requester per rule. Once a rule completely matches the requests (including restrictions), the rule will apply, and the rules check will stop (break). Global rules will always be checked after download’s specific rules.
Access groups are the first and main identifier of an access rule. Based on the group, the extension can determine if the rules apply to the person trying to download your file. The extension comes with the following four access groups:
- Anyone – Literally everyone
- Role – An user role
- User – An username
- IP – An IP address
You can set an additional restriction per rule for even more advanced access control. You can set a date period restriction or a download count restriction. The date period restriction enables you to limit access to a download between dates X and Y. The download count restriction enables you to only allow someone to download a file X times; this is based on IP address (logs must be enabled for this restriction to work).
Global Access Rules
Global access rules can be accessed via your WordPress backend’s submenu item of Downloads. Global rules have the same format as the download-specific rules with one difference – they apply to all downloads. It’s important to remember that global rules will always be applied after the download’s specific rules. In other words, a global rule can only be applied if none of the download-specific rules are matched.
Using advanced access rules will not change the experience for your users. They will still request the downloads the same way they used to. The access checks will be done upon download request.
Does is matter what order the access rules are in?
It does! Rules will be loaded in order of display, top first, and will try to be matched to the requester per rule. Once a rule completely matches the requests (including restrictions), the rule will apply, and the rules check will stop (break).
Please see the following screenshots to demonstrate how important the order of rules is:
Example of rules in the WRONG order
Example of rules in the RIGHT order
Can I use download specific rules and global rules at the same time?
You can. Please note that download-specific rules will always be applied prior to global rules.
How can I change the order of the rules?
You can simply drag and drop the rules to change their order! Don’t forget to ‘update’ your download afterward!
Is the extension Multiste/Network compatible?
The Advanced Access Manager extension is 100% Multisite/Network compatible! The extension will work like it should while being network activated or activated only for certain websites within your network.