Home Forums General News & Announcements Dokan – Rename Navigation

This topic contains 5 replies, has 2 voices, and was last updated by  Nayem 3 years, 8 months ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #64309

    Kat Indo
    Member
    Post count: 4

    Hi,

    I need to rename some titles in the nav bar of the dashboard.
    I checked this thread: https://wedevs.com/support/topic/customize-seller-sidebar/
    but the suggested solution involves changing core files, which I don't want to do.

    Is there another way to rename the titles so I don't have to change them every time after updating the plugin?

    #64314

    Kat Indo
    Member
    Post count: 4

    Also, how can I add one more option in the nav bar?
    I tried the following but it doesn't work:
    1. Added a new option in “includes/template-tags.php” (line #301)
    2. Created a new file in “templates”
    3. Added the url in “templates/dashboard.php”

    I see the tab in the frontend but when it's selected it returns a 404 error page.
    What am I missing?

    #64504

    Nayem
    Moderator
    Post count: 6480
    This reply has been marked as private.
    #64518

    Kat Indo
    Member
    Post count: 4

    How about renaming a tab without modifying core files?

    #64540

    Kat Indo
    Member
    Post count: 4

    The code you provided allows to add a tab in “Settings”, but I need to add a main tab. I modified the code but I still have some issues:
    1. The tab should appear second. Changing the position doesn't seem to have any effect.
    2. The URL should be dashboard/redemptions. The code you provided creates the URL dashboard/settings/redemptions. If I modify the code the URL returns 404 error page.

    Here's the updated code:
    `add_filter( ‘dokan_get_dashboard_nav', ‘dokan_add_menu' );

    function dokan_add_menu( $settings_tab ) {
    $settings_tab[‘redemption'] = array(
    ‘title' => __( ‘Redemptions', ‘dokan'),
    ‘icon' => ‘‘,
    ‘url' => dokan_get_navigation_url( ‘redemptions' ),
    ‘pos' => 32
    );

    return $settings_tab;
    }

    add_filter( ‘dokan_dashboard_settings_heading_title', ‘dokan_load_settings_header', 11, 0 );'

    Can you tell me what needs to be done so it works the way I needed to?

    #64644

    Nayem
    Moderator
    Post count: 6480

    Did you add this –

    `add_filter( ‘dokan_dashboard_settings_heading_title', ‘dokan_load_settings_header', 11, 2 );

    function dokan_load_settings_header( $header, $query_vars ) {
    if ( $query_vars == ‘nayem' ) {
    $header = __( ‘Nayem Profiles', ‘dokan' );
    }

    return $header;
    }

    You have to flush the permalinks from settings of your site.

    Thanks.

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

The topic ‘Dokan – Rename Navigation’ is closed to new replies.