Buy B2BKing
$199 $149
You may want to add your own custom page and content to the agent dashboard. To do that, you can add the following PHP code snippet to the site:
add_action('salesking_extend_menu', function($menu){ ?> <li class="nk-menu-item"> <a href="<?php echo esc_attr(trailingslashit(get_page_link(apply_filters( 'wpml_object_id', get_option( 'salesking_agents_page_setting', 'disabled' ), 'post' , true)))).'newpage';?>" class="nk-menu-link"> <span class="nk-menu-icon"><em class="icon ni ni-navigate-fill"></em></span> <span class="nk-menu-text"><?php echo 'New Page!';?></span> </a> </li><!-- .nk-menu-item --> <?php }, 10, 1); add_action('salesking_extend_page', function($page){ if ($page === 'newpage'){ ?> <div class="nk-content salesking_products_page"> <div class="container-fluid"> <div class="nk-content-inner"> <div class="nk-content-body"> <div class="nk-block-head nk-block-head-sm"> <div class="nk-block-between"> <div class="nk-block-head-content"> <h3 class="nk-block-title page-title"><?php esc_html_e('New Page!','salesking'); ?></h3> </div><!-- .nk-block-head-content --> </div> </div> <div> New content here! </div> </div> </div> </div> </div> <?php } });
In the above code, you can directly change the title and content of the page. To change the page icon, you can replace "ni-navigate-fill" with "ni-" followed by the name of your icon (choose icons from this list).
This code can be added to functions.php of the child theme, or by using any code snippets plugin.
The result will be a new page as follows:
Powered by BetterDocs