Web Guy

Forum Replies Created

Viewing 25 posts - 151 through 175 (of 208 total)
in reply to: Differentiating Files by Membership Level #115000

Web Guy
Participant

Sorry… I thought that the updated code you had provided was working properly (https://www.wpdownloadmanager.com/support/topic/differentiating-files-by-membership-level/#post-114375), but it still needs an adjustment. I only want the tag displayed when the minimum required membership level needed to access the package is “Premium” or “Premium Plus”. As of now, it is putting the “Premium” label on a product that only requires a minimum level of “Basic” to access it.

It should be like this:
– Basic Membership (no tag displayed when “Basic” is minimum required membership)
– Premium Membership (display “Premium” tag if “Premium” is minimum required membership level)
– Premium Plus Membership (display “Premium Plus” if “Premium Plus” is minimum required membership level)

Hope that makes sense. Please let me know if you have any questions.

Thanks

in reply to: Differentiating Files by Membership Level #114800

Web Guy
Participant

Thanks so much. That worked great. I’m also saving the old code here in case I ever need to revert back to showing it for all member levels:

****************************************************************
function wpdm_package_membership_levels($vars){
global $wp_roles;
$roles = array_reverse($wp_roles->role_names);
$membership_levels = get_post_meta($vars[‘ID’],’__wpdm_access’, true);
$role_orders = array( ‘guest’, ‘subscriber’, ‘basic_subscriber’, ‘premium_subscriber’, ‘premium_plus_subscriber’, ‘editor’, ‘administrator’ );

$package_roles = array();

if( in_array(‘guest’, $membership_levels))
$package_roles[] = “Guests”;

foreach( $role_orders as $role ) {
if( in_array($role, $membership_levels ) )
$package_roles[] = $roles[$role];
}

//$vars[‘membership_levels’] = implode(‘, ‘, $package_roles );
$vars[‘membership_levels’] = $package_roles[0];

return $vars;
}
add_filter( ‘wdm_before_fetch_template’, ‘wpdm_package_membership_levels’, 10, 1 );

****************************************************************

in reply to: Allow paid purchases after download limit reached #114756

Web Guy
Participant

I have 2 questions:

1) Can you please elaborate on what you mean when you say the Download Limit Add-on works with free files only?

2) For the pre paid credits option, it is possible to have the number of pre-paid credits reset each month for members, so that it works similar to how the download limit addon works? For example, paid member is given 20 pre-paid credits to use each month? Each month they are automatically given a fresh batch of 20 pre-paid credits to use? Thanks.

in reply to: Differentiating Files by Membership Level #114736

Web Guy
Participant

Thank you. The CSS worked.

Yes, I only want the tags to be displayed for products that require a Premium or Premium Plus membership level (No tag displayed for Guest level products or Basic level products). Thanks.

in reply to: Differentiating Files by Membership Level #114703

Web Guy
Participant

Thanks so much for your help with this! The updated code is working great.

I have one additional question:

What tweaks would be needed to the above code if we wanted to exclude the tag label from being shown on products that are under our Basic membership level (basic_subscriber), but still show the tag label for products requiring a Premium membership (premium_subscriber) and Premium Plus membership (premium_plus_subscriber) levels?

I have gone ahead and wrapped the code in my template like this: <div class=”wpdm-tag-label”>[membership_levels]</div>

Thanks again.


Web Guy
Participant
This reply has been marked as private.
in reply to: Adjusting Column Width on Default Archive Page #114516

Web Guy
Participant

Thanks. That worked great. However, once I do CSS change, the page no longer acknowledges that my shortcode is configured for the archive to show 3 columns (it is now displaying it as 4 columns instead of 3 columns). Here is the shortcode that I am using:

[wpdm-archive cat_view=”extended” cols=”3″ button_style=”default” link_template=”5d277d746310d” order_by=”post_title” order=”asc” items_per_page=”12″]

Please advise if additional css changes are needed to have a 25% and 75% configuration and still use 3 columns.


Web Guy
Participant

Thanks. Does the button switch from Add to Cart to a Download button ONLY if I am using the WP Download Manager Membership addon?

I am using a third party membership program to assign my membership levels and for access control. I am able to display and hide text based on membership level, so it would be great if there was a way for me to generate an add to cart button with one shortcode and a download button using a different shortcode. I would use the shortcode from my membership program to wrap the download button, such that it would only be displayed to members that are logged in. Please advise.

in reply to: Differentiating Files by Membership Level #114448

Web Guy
Participant

Thanks for the code. It is now displaying the role name as the tag, which is great.

However, it is not displaying the lowest required membership level required to access the file. I assume that I am supposed to list my user roles in hierarchical order, so I have gone ahead and tested it with the following modified code:

$order = array(‘guest’, ‘subscriber’, ‘basic_subscriber’, ‘premium_subscriber’, ‘premium_plus_subscriber’, ‘editor’, ‘administrator’);

I then assigned the following access roles to a test package: premium_subscriber and premium_plus_subscriber

However, the test product is displaying the “Premium Plus” tag, but it should only show the lower level “Premium” tag, since that is the lowest membership level required to access the file.

Please advise.

in reply to: Display Options for Download Limit Plugin #114443

Web Guy
Participant

It is working fine now. I had the shortcode displayed twice on my test page. Apparently that caused an issue. I removed the first instance of it and now it is displaying the colorful version properly. Thanks!


Web Guy
Participant

Hello. I resolved the issue. I had a category selected in the shortcode that did not have any content loaded into it yet. I removed the category from the shortcode and now it is working properly.

in reply to: Adjusting Column Width on Default Archive Page #114407

Web Guy
Participant
This reply has been marked as private.

Web Guy
Participant
This reply has been marked as private.

Web Guy
Participant

Thanks. I understand the part about including a subscription link, but how is the download button generated for those people that already have a subcription and would like to download the file. As of now, the download button changed into a payment button as soon as I associated a price to the package.

Is there a way to use two different shortcodes? For example one shortcode that will display the download button and then have a separate shortcode that can display the payment button? That way members that have access can download from the first shortcode and guests that would like to purchase the download can use the second shortcode?

Please advise.

in reply to: Category Archive Page #114397

Web Guy
Participant

OK. Thank you for the clarification.


Web Guy
Participant

Thanks. That worked good.

One last question. If I change the number of columns on my page from 4 to 3, it seems that the following CSS code no longer works:

.w3eden .wpdm-downloads.row .col-md-3:nth-child(4n)::after {
content: ‘\a\a\a\a\a’;
white-space: pre;
}

Can you please let me know what changes are needed if I display 3 columns instead of 4 columns in my archive?

Thanks


Web Guy
Participant
This reply has been marked as private.
in reply to: Compact View Directory Question #114321

Web Guy
Participant

Thanks. Would it be minor code customization similar to what you outlined in this post (https://www.wpdownloadmanager.com/support/topic/exclude-categories-in-accordion/? If so, can you please tell me the code changes that I would need to make to achieve both of the options that I provided above? Thanks.

in reply to: Category Archive Page #114320

Web Guy
Participant
This reply has been marked as private.
in reply to: Breadcrumbs Not Working Properly #114316

Web Guy
Participant
This reply has been marked as private.
in reply to: Question About Templates #114312

Web Guy
Participant

OK. Thank you.

in reply to: Shortcode to Display Total Number of Packages #114311

Web Guy
Participant

Thank you!

in reply to: Display Options for Download Limit Plugin #114310

Web Guy
Participant
This reply has been marked as private.

Web Guy
Participant
This reply has been marked as private.
in reply to: Styling the Dropdown Menu #114307

Web Guy
Participant

Thanks. That worked great. Is there something similar that can be done for the mobile view as well?

Thanks

Viewing 25 posts - 151 through 175 (of 208 total)