PDA

View Full Version : Howto disbale SSL or some other setting e.g. Domains


xaver
27th March 2011, 14:47
Hello,

on ISPConfig3 installation i don't want SSL for user, but admin can setup it.


basis is /usr/local/ispconfig/interface/web/sites/
copy in ./templates your normal template to admin version e.g web_domain_edit.html to web_domain_admin_edit.htm
remove the functions in normal template e.g. SSL (complete <div ..>... <div/>)
go into ./form an select your php file and copy the lines for it and set a if-else for admin
change in admin the template
remove lines in else for user

e.g.
if($_SESSION["s"]["user"]["typ"] == 'admin') { //ask for usertype
$form["tabs"]['domain'] = array (
'title' => "Domain",
'width' => 100,
'template' => "templates/web_domain_admin_edit.htm", // new template
'readonly' => $web_domain_edit_readonly,
'fields' => array (
//change nothing -> ADMIN
.........
)
);
} else { // if usertype != admin
$form["tabs"]['domain'] = array (
'title' => "Domain",
'width' => 100,
'template' => "templates/web_domain_edit.htm", // new template
'readonly' => $web_domain_edit_readonly,
'fields' => array (
...........
/* 'ssl' => array (
'datatype' => 'VARCHAR',
'formtype' => 'CHECKBOX',
'default' => 'n',
'value' => array(0 => 'n',1 => 'y')
), */
//remove lines or comment out
..........
)
);
}Regards,
xaver