backend_marketing_sidebar

Allows adding of custom content to the sidebar in the “Marketing” section.

Shop-Script

Input (passed by reference)

No specific parameters.
… your plugin code …

Output

{$backend_marketing_sidebar.%plugin_id%.promos_li}

Custom

  • element in the list of promo filters.

  • {$backend_marketing_sidebar.%plugin_id%.tools_li}

    Custom

  • element in the list of promo tools.

  • {$backend_marketing_sidebar.%plugin_id%.settings_li}

    Custom

  • element in the list of settings sections.

  • {$backend_marketing_sidebar.%plugin_id%.bottom_li}

    Custom

  • element at the bottom of the sidebar.

  • {$backend_marketing_sidebar.%plugin_id%.custom_html}

    Extra content at the bottom of the sidebar. E.g., an information block or a JavaScript code snippet.

    Shop-Script

    Plugin code example

    PHP

    public function backendMarketingSidebar()
    {
        return [
            'promos_li'   => '<li><a href=""><i class="icon16 yes"></i><span class="s-name">' . _wp('My plugin’s promos') . '</span><span class="s-counter js-counter"></span></a></li>',
            'tools_li'   => '<li><a href=""><i class="icon16 yes"></i><span class="s-name">' . _wp('My plugin’s tools') . '</span></a></li>',
            'settings_li'   => '<li><a href=""><i class="icon16 yes-bw"></i><span class="s-name">' . _wp('My plugin’s settings') . '</span></a></li>',
            'bottom_li'   => '<li><a href=""><i class="icon16 yes"></i><span class="s-name">' . _wp('My plugin’s link') . '</span></a></li>',
            'custom_html' => '<div class="block double-padded">' . _wp('My plugin’s info') . '</div>',
        ];
    }