Certificate problem

Home Forums Legacy Support Support queries Other issues Certificate problem

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #319735
    IBSP
    Spectator
    Hello Vibethemes,
    1. I have created 3 certificates and now I want to attach a specific certificate to all courses at once, Like I have 500+ courses, I want the 1st certificate to attach automatically to all courses, And as in our previous chat on Facebook you said "Possible only by a direct query". So provide me the query and a little bit of information how to use this query.

    2. I want to add a link text after the search bar and before the cart icon here https://prnt.sc/v3jyjv

    NOTE: I renewed my support to urgently fix this problem, So kindly please make sure to complete my request in your first reply. I'll be very thankful to you. Thanks

    #320206
    MrVibe
    Keymaster
    get the certificate post ID, from WP admin - LMS - Certificate Tempaltes, lets say it is "XX"
    
    add_Action('init',function(){
       global $wpdb;
    $results = $wpdb->get_results("SELECT ID from {$wpdb->posts} WHERE post_type = 'course');
    if(!empty($results)){
    foreach($results as $result){
       update_post_meta($result->ID,'vibe_certificate_template',xx);
    }
    }
    });
    
    run this once and remove this code.
    #320207
    MrVibe
    Keymaster
    add_Action('wplms_header_top_login',function(){
    ?>
    <li><a>Add whatever you want</a></li>
    <?php
    });
    #320429
    IBSP
    Spectator
    The above solution for certificate didn't work https://prnt.sc/v5fkq6 When I add this code in wplms-customizer.php, the site goes down and through an error of https://prnt.sc/v5fm7l , i also changed 'xx' with certificate id And after deleting this code i checked the course again and no certificate was assigned. https://prnt.sc/v5fn7j OR i'm doing something wrong? Please let me know, Thanks
    #320591
    Anshuman Sahu
    Keymaster
    Sorry here is the correct code. :
    add_Action('init',function(){
       global $wpdb;
    $results = $wpdb->get_results("SELECT ID from {$wpdb->posts} WHERE post_type = 'course'");
    if(!empty($results)){
    foreach($results as $result){
       update_post_meta($result->ID,'vibe_certificate_template',229);
    }
    }
    });
Viewing 5 posts - 1 through 5 (of 5 total)
  • The topic ‘Certificate problem’ is closed to new replies.