We are happy to announce that Vesta is back under active development as of 25 February 2024. We are working on v1 candidate and expect to engage more with the community over the coming months. We are committed to open source, and we encourage contributors to help us build the future of Vesta.
Can modules be disabled?
Can modules be disabled?
Can modules that aren't required be disabled in the web interface easily?
Stopping the services is simple enough but I'm looking to remove or diable DNS and MAIL from the interface if i can.
GTF
Stopping the services is simple enough but I'm looking to remove or diable DNS and MAIL from the interface if i can.
GTF
Re: Can modules be disabled?
Answering my own post:
Easy. Code some php around each href in panel.html and they're selectable.
GTF
Easy. Code some php around each href in panel.html and they're selectable.
GTF
Re: Can modules be disabled?
What was your PHP method? I was personally thinking editing the HTML with comments.
Re: Can modules be disabled?
I've already scrubbed the install i was playing with to test someting else but it was something like:
A function allowed_option takes a username and the option to check.
Reads a flatfile with something similar to:
"username","0","1","0","1"...etc
0 returns false, 1 returns true. If true output the HTML.
I was considering using the first part of the if to output a greyed out, non selectable option.
Crude but it worked ok for the test.
Hope that helps.
GTF
A function allowed_option takes a username and the option to check.
Reads a flatfile with something similar to:
"username","0","1","0","1"...etc
0 returns false, 1 returns true. If true output the HTML.
Code: Select all
<?php if (!allowed_option($userName,"/list/web"){
}
else {?>
<a class="nav-lnk" href="/list/web/">
<span class="nav-<?php if($TAB == 'WEB' ) echo 'selected-' ?>block">
<p class="nav-<?php if($TAB == 'WEB' ) echo 'selected-' ?>header">
<?php print __('WEB');?>
</p>
<p class="nav-counters">
<?php print __('domains');?>: <? echo $panel[$user]['U_WEB_DOMAINS']?><br>
<?php print __('aliases');?>: <? echo $panel[$user]['U_WEB_ALIASES']?><br>
<?php print __('spnd');?>: <? echo $panel[$user]['SUSPENDED_WEB']?>
</p>
<p class="marker"></p>
</span>
</a>
<?php}?>
Crude but it worked ok for the test.
Hope that helps.
GTF