This topic has 7 replies, 2 voices, and was last updated 9 years by Laura.

  • Author
  • #35304
     Nicole
    Participant

    Hello! So, i’ve added the following code to functions.php on my child theme to change tabs names and to add the media tab at the end of the tabs. But for some reason the MEDIA tab appears at the beginning of the list, and not at the end. Any ideas?? See attached 🙂

    COPY CODE
    //custom code
    add_action('after_setup_theme','kleo_my_custom_tabs');
    function kleo_my_custom_tabs()
    {
        global $bp_tabs;
     
        $bp_tabs[] = array(
                'type' => 'regular',
                'name' => __('Info di base', 'kleo_framework'),
                'class' => 'regulartab'
        );
    
       $bp_tabs[] = array(
                'type' => 'regular',
                'name' => __('Dettagli impresa', 'kleo_framework'),
                'class' => 'regulartab'
        );
    
     $bp_tabs[] = array(
                'type' => 'regular',
                'name' => __('Convenzioni', 'kleo_framework'),
                'class' => 'regulartab'
        );
      
     /* rtMedia tab - only if plugin installed */
        if (class_exists('RTMedia')) 
        {
            $bp_tabs['rtmedia'] = array(
                    'type' => 'rt_media',
                    'name' => __('Media', 'kleo_framework'),
                    'class' => 'mySlider'
            );
        }
     
        /* Bp-Album tab - only if plugin installed */
        elseif (function_exists('bpa_init')) {
            $bp_tabs['bp-album'] = array(
                    'type' => 'bp_album',
                    'name' => __('Prodotti', 'kleo_framework'),
                    'class' => 'mySlider'
            );
     }
    Attachments:
    You must be logged in to view attached files.
    #35352
     Laura
    Moderator

    Hello, try to replace your code with this and tell me if its working 🙂

    COPY CODE
    
    add_action('after_setup_theme','kleo_my_actions');
    
    function kleo_my_actions() 
    {
        global $bp_tabs;
        $bp_tabs = array();
    
        $bp_tabs['base'] = array(
        'type' => 'regular',
        'name' => apply_filters('kleo_extra_tab2',__('Info di base', 'kleo_framework')),
        'class' => 'regulartab'
        );
    $bp_tabs['impresa'] = array(
        'type' => 'regular',
        'name' => apply_filters('kleo_extra_tab2',__('Dettagli impresa', 'kleo_framework')),
        'class' => 'regulartab'
    	);
    
    $bp_tabs['convenzioni'] = array(
        'type' => 'regular',
        'name' => apply_filters('kleo_extra_tab2',__('Convenzioni', 'kleo_framework')),
        'class' => 'regulartab'
    	);
        /* rtMedia tab - only if plugin installed */
        if (class_exists('RTMedia')) 
        {
            $bp_tabs['rtmedia'] = array(
                'type' => 'rt_media',
                'name' => __('Media', 'kleo_framework'),
                'class' => 'mySlider'
            );
        }
    

    Some Info you may need to know:
    In Name : kleo_extra_tab2 Means small fields. kleo_extra_tab1 Means quote style fields

    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 🙂

    #35416
     Nicole
    Participant

    Worked like charm! Thanks Laura

    #35419
     Nicole
    Participant

    Not sure if I need to open a new ticket.. but:

    Maybe i’m missing something… But doesn’t the rtMedia plugin should have a custom Sweetdate theme? How Can i enable it?? This is what I see if I turn off/deactivate the “Stile di default rtMedia” (see attach).

    As you see there are several errors, plus first screenshot was taken at 80% reso of the screen, because at 100% the image isn’t even visible, see screenshot N2

    Thanks

    Attachments:
    You must be logged in to view attached files.
    #35433
     Laura
    Moderator

    Hello, maybe try to deactivate other plugins but buddypress and rtmedia and see what happens?

    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 🙂

    #40515
     Laura
    Moderator

    Hello, is this resolved?

    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 🙂

    #40551
     Nicole
    Participant

    Hello @Laura
    Actually I’ve deactivated the RTmedia plugin because It couldn’t solve the issue… 🙁

    #40636
     Laura
    Moderator

    Hello.
    Are you using another plugin for that?

    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 🙂

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

You must be logged in to reply to this topic.

Log in with your credentials

Forgot your details?