migration to 3.0 stops php shortcode
-
after migration to 3.0 none of the php shortcodes seem to work, such as :-
if(pmpro_hasMembershipLevel(‘0,7’))
-
Hi there, thank you for reaching out to Paid Memberships Pro.
The pmpro_hasMembershipLevel function requires an int or array value – if you want to check for multiple levels,
pmpro_hasMembershipLevel( array( 0, 8 ) )
will do the trick.Please give this a try and let me know if it helps.
Kind regards,
Jarryd
Support Manager at Paid Memberships Prothis was working fine until the 3.0 upgrade….
also worth noting that the shortcode that was in the widgets no longer work either example : [membership level=”0,7″]
Anyways to downgrade this ?Version 3.0 makes major database changes to your site and as such cannot be rolled back – https://www.paidmembershipspro.com/rolling-back-from-pmpro-v3-0-to-previous-release/
I’m looking into this with our development team and will revert with feedback as soon as possible.
In the meantime, please navigate to Memberships > Settings > Levels and send me a screenshot of your levels?
Kind Regards,
Jarryd
Support Manager at Paid Memberships Pro-
This reply was modified 1 year, 1 month ago by
Jarryd Long.
here
Once logged in, please locate the ‘View As’ dropdown in the WP Admin Bar and set it to ‘View Without Member Access’ and let me know if the issue persists?
Yes the issues persists all my users are members.
this has only just happened with the upgrade, parts of the site that were previously hidden to various levels, rules are being ignored and its being shown to all members , for example :-
big digital download banner for arcadesystems , the custom code originally says :-
[membership level=”0,7″]
<img src=”……..
[/membership]
This was working perfectly before the 3.0 version, now EVERYONE see this image including all other levels of users. Its simply being ignored.Your shortcode attribute allows for level 0 (non members) and level 7 (a specific level) which results in it showing to non members (everyone).
I’m looking into the behaviour of the non-member value with the developers on our team as this would previously be considered a user that is logged in and doesn’t hold a membership level, and not just a visitor.
Kind Regards,
Jarryd
Support Manager at Paid Memberships Pro-
This reply was modified 1 year, 1 month ago by
Jarryd Long.
After further testing we’ve found this shortcode to work as expected. The 0 level applies to a non-member who we assume is logged in but doesn’t hold a membership level.
Kind Regards,
Jarryd
Support Manager at Paid Memberships ProBecause there have not been any recent updates to this topic, we will be changing the status to resolved.
Feel free to start a new topic for further discussion when you are ready.
Kind Regards,
Jarryd
Support Manager at Paid Memberships Pro -
This reply was modified 1 year, 1 month ago by
- The topic ‘migration to 3.0 stops php shortcode’ is closed to new replies.