This topic has 2 replies, 3 voices, and was last updated 8 years by Abe.

  • Author
  • #115547
     water29
    Participant

    I am editing the top menu where the notifications are defaulted at tasks, messages and notifications. I am trying to create my own customized version of tasks, with different categories. I have it all setup but is there a way to customize the title attribute ##my_tasks# or create my own? It is setup to show total tasks but I just want to display it for a certain category. I have it showing the correct category using the shortcodes, but the value for the bubble is total tasks, not the specific category.

    #115915
     Laura
    Moderator

    Hello, will assign the ticket to a higher support level who can help and advise you in your query.
    Thanks! 🙂

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    Laura Solanes - Graphic Designer and Web Designer

    Please be patient as I try to answer each topic as fast as i can.

    If you like the theme or the support you've received please consider leaving us a review on Themeforest!

    Always happy to help you 🙂

    #118552
     Abe
    Keymaster

    Hi there, we used this function to create the my_tasks placeholder. You can create your own by following our initial logic. make sure to rename functions names and add it to your child theme/functions.php

    COPY CODE
    
    
    add_filter('walker_nav_menu_start_el', 'kleo_ctdl_replace_placeholders');
    
    function kleo_ctdl_replace_placeholders( $output ) {
    
        if ( strpos( $output, '##my_tasks##' ) !== false ) {
    
            if ( ! is_user_logged_in() ) {
                return '';
            }
    
            $count = CTDL_Lib::get_todos( get_current_user_id(), 5000, 0)->post_count;
            $output = str_replace('##my_tasks##', "<b class='bubble'>" . $count . "</b>", $output);
    
        }
    
        return $output;
    }
    
    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution

    ---
    @ SeventhQueen we do our best to have super happy customers. Thanks for being our customer.

Viewing 3 posts - 1 through 3 (of 3 total)

The forum ‘Theme options & Demo content’ is closed to new topics and replies.

Log in with your credentials

Forgot your details?