Home › Forums › Legacy Support › Support queries › Setup issues › My Courses based on Category (or workaround)
- This topic has 9 replies, 3 voices, and was last updated 5 years, 8 months ago by Anshuman Sahu.
Viewing 10 posts - 1 through 10 (of 10 total)
-
AuthorPosts
-
August 13, 2018 at 6:23 pm #172311SilvioParticipantHi, I wasn´t going to ask about this as I didn't manage to find any related topic, and I thought you may consider it a customization off your scope, but I have found a topic with a proposed solution and I decided to ask you about it as it may be useful for many users. In this post, you proposed a function which should filter the main courses page in order to only display a certain category. https://wplms.io/support/forums/topic/my-courses-based-on-category/ I tried adding that function but it does not seem to work anymore. Could you assist on this?August 14, 2018 at 12:30 pm #172385Mark MorganSpectatorThe code given in the topic mentioned by you is for showing courses for a specific category. For this you need to add shortcode [my_courses] on your page. Also you have to change the category slug "business" with your category slug.August 14, 2018 at 12:51 pm #172390SilvioParticipantHi Mark, I already tried that, but I just get a blank page. Could you try to replicate it? I've tried the code both in my local deploy and the live service but still no results. I tried different slugs. Is that code, maybe, only valid for logged in users or something like that? I can give you access to the site or send you the functions file so you can have a look, but I can assure I just followed your given steps.August 16, 2018 at 7:14 am #172538Mark MorganSpectatorPlease share your admin credentials to check this issue. PS: Mark reply as private while sharing your credentials.August 16, 2018 at 7:54 am #172545SilvioParticipantThis reply has been marked as private.August 17, 2018 at 1:17 pm #172692Mark MorganSpectatorWe need your FTP details to debug this issue. PS: Mark the reply as private while sharing the credentials.August 17, 2018 at 1:37 pm #172694SilvioParticipantThis reply has been marked as private.August 18, 2018 at 7:50 am #172740Anshuman SahuKeymasterA necessary buddypress component "activity streams " was disabled in wp-admin -> settings -> buddypress in your site . This is needed at all places in wplms . I activated it and it worked fine.August 18, 2018 at 10:00 am #172758SilvioParticipantHi Alex, First of all, thanks for your support. I didn´t have any idea about the activity stream being needed. However, I just checked both the shortcode and the main courses page and the filter per category is not working. Before I checked that, I went to WPLMS Dashboard Courses Manager, where I had disabled all courses but the category I wanted from directory listing (when you checked the shortcode all courses which didn´t belong to that category were hidden, the same one I'm applying the function you provided). add_shortcode('my_courses','wplms_my_courses_shortcodes'); .... if(has_term( 'agricultura-ganaderia', 'course-cat', $course )){ If you check the main courses page you will see that the filter is not being applied. Also, if you check the pages where the shortcode is inserted (et al /test-shortcode) you will see that the course shortcode does not even run on that page.August 20, 2018 at 1:43 pm #172907Anshuman SahuKeymasterThis reply has been marked as private.
-
AuthorPosts
Viewing 10 posts - 1 through 10 (of 10 total)
- The topic ‘My Courses based on Category (or workaround)’ is closed to new replies.