Add New LINKS signbar left, editing News Feed, Delete Friends end Photo from the bar on the left

Iosif Deak Posted in General Discussion 5 years ago

I need help, can anyone help me
1: Can I add another menu like LINKS? I want to have 2 but with other subdomains
2: How to edit News Feed? I want to change with HOME
3: How do I delete friends and photos from the bar on the left?

enter image description here

Replies
Interlingue Kay --B-- Replied 4 years ago

Much appreciated. With the priority set, that did the trick.

Thanks.

Indonesian Arsalan Shah Replied 4 years ago

Kay,

function remove_friends_others(){
    ossn_unregister_menu_item('friends','links','newsfeed');
}
ossn_register_callback('ossn', 'init', 'remove_friends_others', 1000);
Interlingue Kay --B-- Replied 4 years ago

Hi,

Has anyone managed to achieve what the OP requested ?

I understand how to add additional menu items as suggested, but cannot find a simple way to remove the 'friends' and 'photos' items from the newsfeed menu.

Adding a callback into the ossn_themes gives me the ability to remove the newsfeed item by calling:

ossn_unregister_menu_item('newsfeed','links','newsfeed'),

but not the firends/ photos links when calling:

ossn_unregister_menu_item('friends','links','newsfeed').

It looks as though the other menu items are not yet in the $Ossn->menu array when this callback is invoked.

Is there another hook that can be used before the sidebar gets generated in order to manipulate the menu ?

Thanks

Romanian Iosif Deak Replied 5 years ago

How to delete it Friends from the left bar? I want to remove it

Indonesian Arsalan Shah Replied 5 years ago

See https://www.opensource-socialnetwork.org/wiki/view/737/how-to-write-a-simple-component-for-ossn you need to add these within your ossn_com.php init function

Romanian Iosif Deak Replied 5 years ago

.

    ossn_register_sections_menu('newsfeed', array(
            'text' => 'Google',
            'url' => 'http://google.com',
            'section' => 'searchengines',
            'icon' => true,
    ));
     ossn_register_sections_menu('newsfeed', array(
             'text' => 'Yahoo',
             'url' => 'http://yahoo.com',
             'section' => 'searchengines',
            'icon' => true,
    ));

Where do I add this code? In what file?

https://www.opensource-socialnetwork.org/discussion/view/1468/hi-i-would-like-to-add-a-menu-with-a-collapse-bar-in-the-sidebar-menu-how-can-i-do-that

Romanian Iosif Deak Replied 5 years ago

Arsalan Shah I've added this already, I want to add how it is already added Links and Groups