Castey:
You should update the module so that only admin see the admin link:
module.zpm
controller.ext.php
You should update the module so that only admin see the admin link:
module.zpm
Code:
<div class="zmodule_content panel" id="zmodule_header_<@ ModuleName @>">
<div class="panel-heading">
<img src="<@ ModuleIcon @>" width="35" height="35" border="0" alt="<@ ModuleName @>">
<div class="zmodule_title">
<@ ModuleName @>
</div>
<div class="zmodule_desc" id="zmodule_desc_<@ ModuleName @>"><@ ModuleDesc @></div>
</div>
<a href="etc/apps/rainloop/" class="btn btn-large btn-primary" target="_blank"><: Launch Rainloop :></a>
<% if Admin %>
<a href="etc/apps/rainloop/?admin" class="btn btn-large btn-primary" target="_blank"><: Launch Rainloop Admin :></a>
<% endif %>
</div>
Code:
<?php
/**
* @copyright 2014-2015 Sentora Project (http://www.sentora.org/)
* Sentora is a GPL fork of the ZPanel Project whose original header follows:
*
* ZPanel - A Cross-Platform Open-Source Web Hosting Control panel.
*
* @package ZPanel
* @version $Id$
* @author Bobby Allen - ballen@bobbyallen.me
* @copyright (c) 2008-2014 ZPanel Group - http://www.zpanelcp.com/
* @license http://opensource.org/licenses/gpl-3.0.html GNU Public License v3
*
* This program (ZPanel) is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
*/
class module_controller extends ctrl_module
{
public static function getAdmin()
{
global $controller;
$currentuser = ctrl_users::GetUserDetail();
if ($currentuser['usergroup'] == "Administrators") {
return true;
} else {
return false;
}
}
}