Sam Rohn
Forum Replies Created
-
Forum: Plugins
In reply to: [PanoPress] 360 degree video – can someone help me?Forum: Plugins
In reply to: [PanoPress] deactivate plugin on posts where there is no panothanks sam, nice tip ??
we will try to add something like this to panopress in an upcoming version
sam
Forum: Plugins
In reply to: [PanoPress] opt in/ registration before virtual touryou would have to restrict access to any post or page that the tour was embedded on, or use a shortcode to hide content from non-logged in users etc
otherwise, you would have to code it in the tour somehow, using either krpano or kolor panotour or pano2vr etc
sam
Forum: Plugins
In reply to: [PanoPress] 360 degree video – can someone help me?see this post on the panopress forums for info on 360° video & wordpress
https://www.panopress.org/forums/topic/360-degree-video-anyone-can-help/
sam
s2 renewal reminders plugin seems to be working well for me, reminders are being sent as expected, no reports of multiple duplicate reminders etc
one additional feature that would be helpful would be the ability to send reminders to expired (demoted) members who have not renewed after 30 days (or variable time which could be set in plugin), i think the only place demotion status is stored is on s2 notes…
sam
this plugin will allow easily adding additional roles per user, so you could add editor or other role to an existing member’s s2 membership role for a specific user
https://www.ads-software.com/plugins/role-includer/
user role editor will allow the same ability to add multiple roles per user, but also more functions to customize capabilities per role, so you could for example give all s2 level 3 members “edit_posts” capability or any other built in or custom capability etc
https://www.ads-software.com/plugins/user-role-editor/
sam
this plugin might be easier for what you need, allows you to easily add multiple roes per user
https://www.ads-software.com/plugins/role-includer/
sam
hmm, same here, viewing that path on my site will show my own login info
but the same link in a non logged in browser does not show my personal info, but seems to reveal other site info
what is going on ? is this a bug or security issue ?
can someone from S2 comment on this ?
thanks
sam
you can add the “restrict_content” capability to appropriate wp role with user role editor plugin, this will allow that role to access s2 restriction metabox
https://www.ads-software.com/plugins/user-role-editor/
sam
this plugin allows proper EOT format with s2member and amr user lists WP plugin –
https://wpusersplugin.com/downloads/amr-users-plus-s2-member/
also see this for adding EOT to standard WP admin user list
https://www.s2member.com/kb/adding-a-sortable-eot-user-column/
sam
definitely test disabling other plugins and using default WP theme first, but otherwise…
i had some permission issues on a somewhat complex site with custom post types and caps and custom posting permissions for CPT per role etc, and once i got it all working i wanted everything hard coded to help ensure it would not mysteriously break somehow, here is an abbreviated version of my code (without all of my custom caps), paste this into a text file and name it s2member-custom-caps.php (or similar) and drop in mu-plugins or regular plugins folder and it should set all s2 caps properly
you could also add any other desired standard WP or custom caps etc per role in this file
sam
<?php /* Plugin Name:S2Member Custom Capabilities Plugin URI: Description: Hardcoded Custom WordPress Member Role Capbilities for S2Member Version: 1.0 ? Author: Sam Rohn Author URI: https://www.samrohn.com/ */ // *** // ADMIN S2Member capablities // *** function s2_custom_admin_caps (){ global $wp_roles; $role = get_role( 'administrator' ); // s2member caps, in case they break somhow $role->add_cap( 'access_s2member_level4' ); $role->add_cap( 'access_s2member_level3' ); $role->add_cap( 'access_s2member_level2' ); $role->add_cap( 'access_s2member_level1' ); $role->add_cap( 'restrict_content' ); // other caps could be added per-role like this - // $role->add_cap( 'edit_posts' ); } add_action('init', 's2_custom_admin_caps'); // *** // S2member level 4 capablities // *** function s2member_level4_caps (){ global $wp_roles; $role = get_role( 's2member_level4' ); $role->add_cap( 'access_s2member_level4' ); $role->add_cap( 'access_s2member_level3' ); $role->add_cap( 'access_s2member_level2' ); $role->add_cap( 'access_s2member_level1' ); } add_action('init', 's2member_level4_caps'); // *** // S2member level 3 capablities // *** function s2member_level3_caps (){ global $wp_roles; $role = get_role( 's2member_level3' ); $role->add_cap( 'access_s2member_level3' ); $role->add_cap( 'access_s2member_level2' ); $role->add_cap( 'access_s2member_level1' ); } add_action('init', 's2member_level3_caps'); // *** // S2member level 2 capablities // *** function s2member_level2_caps (){ global $wp_roles; $role = get_role( 's2member_level2' ); $role->add_cap( 'access_s2member_level2' ); $role->add_cap( 'access_s2member_level1' ); } add_action('init', 's2member_level2_caps'); // *** // S2member level 1 capablities // *** function s2member_level1_caps (){ global $wp_roles; $role = get_role( 's2member_level1' ); $role->add_cap( 'access_s2member_level1' ); } add_action('init', 's2member_level1_caps'); ?>
how about wp do_shortcode function in a template ?
https://codex.www.ads-software.com/Function_Reference/do_shortcode
you could insert a a var something like this –
<php do_shortcode('[s2Member-PayPal-Button ra ="' . $variable . '"]'); ?>
sam
Forum: Plugins
In reply to: [PanoPress] variable in shortcodeyou could use wordpress do_shortcode function in a template or other php file, and insert your var into the shortcode that way
https://codex.www.ads-software.com/Function_Reference/do_shortcode
you might insert the var something like this –
<php do_shortcode('[pano file="' . $variable . '"]'); ?>
sam
may be broken permissions, try the s2member reset role permissions function, but be aware this may break any custom role capabilities you might have set up
amr users is a great plugin for listing wordpress users, works great with s2member
you could also use code like this in a theme template file, this will grab all current members of a specified level and display the user name, this could be changed to display any other user meta, first name, last name, website, custom meta etc
https://phptechnologytutorials.wordpress.com/2013/08/05/get-users-list-by-role-in-wordpress/
<?php $args2 = array( 'role' => 's2member_level1', 'orderby' => 'user_nicename', 'order' => 'ASC' ); $authors = get_users($args2); echo '<ul>'; foreach ($authors as $user) { echo '<li>' . $user->display_name. '</li>'; } echo '</ul>'; ?>
sam