Add Certificate

Home Forums Legacy Support Support queries Setup issues Add Certificate

Tagged: 

Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #48642
    Danny
    Spectator
    For some reason I am not able to add certificates anymore in Front End course creation. Using Modern theme and new front end creation. All themes and plugins are up to date, but I also had this issue in previous versions. My settings in wplms - course setting is Course Linkage = On Course Privacy = On I have these codes in the customizer plugin. /Function to remove instructor privacy but keep certificate/ add_filter('wplms_fontend_cpt_query','custom_wplms_fontend_cpt_query',999); function custom_wplms_fontend_cpt_query($args){ if($args['post_type']=='certificate'){ unset($args['author']); } return  $args; } /Hides certificate and badges for other users/ add_action('init','custom_hide_certificate_badge'); function custom_hide_certificate_badge(){ if(is_user_logged_in() && !bp_is_my_profile()){ remove_action('bp_before_profile_content','show_profile_snapshot'); } }
    #48645
    Danny
    Spectator
    Credentials url: www.qampus.se Userid: p511dvi Password: Alicia0810163584
    #48688
    H.K. Latiyan
    Participant
    Thanks for sharing the credentials. I checked your site but I couldn't replicate the issue on your site, it was working fine on your site. Please refer the video in my next private reply.
    #48689
    H.K. Latiyan
    Participant
    #48728
    Danny
    Spectator
    Hi Latiyan, Yes, you are right. It works when you are admin, but not as an instructor. Didn´t try it on the admin before. But if you use these credentials you can see the issue. Username: Qampuss Password: Alicia0810163584
    #48893
    H.K. Latiyan
    Participant
    Ok I again checked your site with instructor credentials and yes instructor cannot add the certificate, the reason is that the certificate is created by the admin and you have enabled force instructor content privacy in wplms -> course manager. If you disable this setting then the instructor can add the certificate because that setting will not allow other instructors to see the content created by another instructors and admin is also an instructor. Therefore to add certificate in course through instructor account either disable the setting or ask your instructors to create their own certificates to add in their course.
    #48999
    Danny
    Spectator
    Yes it works when I disable the instructor privacy, but I can´t have my instructors to have access to other instructors/or admin media files and courses. I have created a ticket about this before and Alex gave me this code. add_filter('wplms_fontend_cpt_query','custom_wplms_fontend_cpt_query',999); function custom_wplms_fontend_cpt_query($args){ if($args['post_type']=='certificate'){ unset($args['author']); } return  $args; } https://wplms.io/support/forums/topic/certificate-front-end/ I think it worked before because I have closed the ticket, but it´s not working anymore. So the thing that I want is Instructors privacy but not for certificates. Can you please look at the code and see if something needs to be changed?
    #49183
    H.K. Latiyan
    Participant
    I checked the code the only problem is the spelling mistake of frontend in the hook, I used this code and it works fine on my test setup. Please use this code: add_filter('wplms_frontend_cpt_query','custom_wplms_frontend_cpt_query',999); function custom_wplms_frontend_cpt_query($args){   if($args['post_type']=='certificate'){     unset($args['author']);   }   return  $args; }
    #52342
    Danny
    Spectator
    Sorry for late reply. It seems to work... MANY thanks.
    #52378
    H.K. Latiyan
    Participant
    Thanks for confirming, so marking the topic as resolved and closing the topic.
Viewing 10 posts - 1 through 10 (of 10 total)
  • The topic ‘Add Certificate’ is closed to new replies.