hliljegren
Forum Replies Created
-
Forum: Plugins
In reply to: [Pods - Custom Content Types and Fields] Access right bug?Thank you for the quick response!
Forum: Plugins
In reply to: [Booking Addon for WooCommerce] WordPress/Wordfence flagged this pluginAnd now the plugin is removed from WordPress ??
So this is probably abandoned now. The plugin developer site is also gone! but according to the remaining part of the page it says:“Booking Addon for WooCommerce” is open source software.
So, we are thus free to “update”, fork etc if we want to…
You can either override the templates, e.g. single-lesson.php and put in a check or you can hook into the “sensei_can_user_view_lesson” filter. Something like this in your functions.php:
function my_theme_only_show_content_for_enrolled_user( $can_view_lesson, $lesson_id, $user_id ) { if ( $can_view_lesson ) { $course_id = Sensei()->lesson->get_course_id( $lesson_id ); $can_view_lesson = Sensei()->course->is_user_enrolled( $course_id, $user_id ); } return $can_vew_lesson; } add_filter('sensei_can_user_view_lesson', 'my_theme_only_show_content_for_enrolled_user", 3, 10);
NOTE: I’m just typing out of my head but it can hopefully get you started. I.e. the code is totally untested (but works in theory ?? )
- This reply was modified 3 years, 1 month ago by hliljegren.
Forum: Plugins
In reply to: [Posts to Page] Space between postsThe easiest way IMHO is to use the class_wrap attribute and then style that in your css. E.g. Lets say you want to have a 2 em margin between your posts then you can use: [post_to_page class_wrap=”post-listing” All other settings]
Then you can add in your CSS:
.post-listing {
margin: 2em;
}Forum: Plugins
In reply to: [Posts to Page] display sequence not workingSee my post about the same problem for a fix…