How I can remove Profile Icon and Link From Side Menu?

How I can remove Profile Icon, Display Name and Link From Side Menu?

elgg_unregister_plugin_hook_handler('prepare', 'menu:site', 'elgg_site_menu_setup');

  • I'm not sure if I understand your question correctly. My guess is that you mean the profile icon showing up in the so called "owner block". I don't think it makes much sense in removing the profile icon from there (as the owner block is mainly aiming at other users who watch your content and the profile icon is a visible indication to whom the content belongs) but if you want to get rid of it there you need to override the view

    views/default/page/elements/owner_block.php

    This means you have to create a plugin where you copy this view to mod/my_plugin/views/default/page/elements/owner_block.php (or you can add this view to another suitable customization plugin or your theme). In the copy of the view you should replace the line

    $header = elgg_view_entity($owner, array('full_view' => false));

    with

    $header = '';

    and then the profile icon should be no longer visible in the sidebar.

  • Side menu? As in sidebar?

    You could override the sidebar and remove it.

  • How about trying the solution I've already described above? It descibes how to hide the profile icon and name from the owner block (that's what this part of the sidebar is called). Only if you have tried what I have suggested and it doesn't work it makes any sense to ask for additional advice.

Beginning Developers

Beginning Developers

This space is for newcomers, who wish to build a new plugin or to customize an existing one to their liking