in start.php:
//add submenu options for admin
if (get_context() == "market" && isadminloggedin()) {
// Get page owner
$page_owner = page_owner_entity();
if (($page_owner->guid == $_SESSION['guid'] || page_owner()) && isadminloggedin()) {
and in add.php just replace
gatekeeper(); with admin_gatekeeper();
works fine
Nice one Lenzen, cheers!
Hi, lenzen24
I did get an notification about you writing a comment on my market plugin, but I couldn't find it afterwards.
Anyway, I can see you did find a solution to your problem.
I will consider building this functionality into the next release, and make this behavior controlled in the plugin settings.
Regards
slyhne
Why renaming custom_index, your theme already have new_index.php in mod\elggsocial\views\default\canvas\layouts\. ( It Should!! All my themes have it) If you do rename custom_index plugin, you will need to copy the code from your theme into your new plugin to display Login and Registration boxes, otherwise you will loose them.
if your theme does not already have new_index.php, still it is easier in my experience to just add \canvas\layouts\new_index.php to your theme \views\default\ folder ( so folder stucture will be mod\elggsocial\views\default\canvas\layouts\new_index.php and then hack away. This way when upgrading in the future all hacked code is only in your theme.
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by Raül Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.